Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why won't Character move properly while using velocity?

Asked by 4 years ago

I have a local script that sends a message to the serverscript, and send the information Mouse.Hit over to it.

local y = Instance.new("BodyVelocity", Character.HumanoidRootPart)
y.maxForce = Vector3.new(math.huge, math.huge, math.huge)
y.velocity = (Character.HumanoidRootPart.Position - mouse.p).unit 

It doesn't send them in the direction of players mouse, any ideas?

0
The second argument of Instance was deprecated, as is no longer considered a good practice. For further project, set the parent manually: local Part = Instance.new("Part"); Part.Parent = workspace Ziffixture 6913 — 4y
0
Okay, but it still doesn't send them in the direction of the mouse. klean10 4 — 4y
0
If you have external code, that should be provided. We need to know what information got sent, and how it was given. If mouse wasn’t passed as .Hit, then simply writing mouse.p wouldn’t work Ziffixture 6913 — 4y
0
I legit said above "send the information Mouse.Hit over to it." klean10 4 — 4y

Answer this question