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

How do I change Body Velocity?

Asked by
NecoBoss 194
10 years ago

I've been trying to change the body velocity and I thought I may have find the solution but this, unfortunately, doesn't work.

function onTouched(part)
Touch.Parent.BodyVelocity.velocity(0,10,0)
wait(2)
end

script.Parent.Touched:connect(onTouched)

Please help me.

1 answer

Log in to vote
2
Answered by 10 years ago

You need to set the value with Vector3.

function onTouched(part)
Touch.Parent.BodyVelocity.velocity = Vector3.new(0,10,0)
wait(2)
end

script.Parent.Touched:connect(onTouched)
Ad

Answer this question