Help with mouse CFrame

I’m trying to use MouseButton1 input to change a BodyVelocity value to a constant velocity in the direction of the mouse. What I currently have kinda works, except the speed is relative to the distance between the cursor and the character and it’s not consistent in the direction and I’m not sure why.

This is what I have now -
character.HumanoidRootPart.BodyVelocity.Velocity = Vector3.new(mouse.Hit.p.x, mouse.Hit.p.y, mouse.Hit.p.z)

Thank you for the help!

I think that BodyPosition may work better for what you’re trying to do. Also, the code snippet that you’ve posted is exactly the same as doing character.HumanoidRootPart.BodyVelocity.Velocity = mouse.Hit.p.

2 Likes