Hello! I’m pretty new to scripting and just discovered BodyVelocity. The problem is, the direction of Velocity is constant according to Position and not CFrame (which includes player rotations). Now, how would I move a part always infront of the player? I hope someone could give simple answers.
Anyways, this is the script that I used
local BVelocity = Instance.new("BodyVelocity")
if player.Character.HumanoidRootPart:FindFirstChild("Megalith") then
BVelocity.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
BVelocity.Velocity = player.Character.HumanoidRootPart.CFrame*CFrame.new(Vector3.new(0,0,100))
BVelocity.Parent = player.Character.HumanoidRootPart.Megalith
“Megalith” is the part that I want to move infront of the player. The script above returns me an error, “expected Vector3, got CFrame”. I would appreciate any help, thanks.