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

How to have players held on to by moving platforms?

Asked by 5 years ago

I recently made a moving platform and I'd like to know if there is a specific script or object that can hold the player to the platform itself when it moves (not keep them there just have the character move with the platform as long as they are touching it). Thanks!

1 answer

Log in to vote
0
Answered by 5 years ago

There is a property on a part called "Velocity" (Read more about it here: https://developer.roblox.com/en-us/api-reference/property/BasePart/Velocity ) You need to match the velocity to the speed at which the platform is moving at. Velocity moves the player when the player is touching the part, like a treadmill so if you set the velocity the opposite way the platform is moving it should do something like this:

With Velocity = https://gyazo.com/2147237f7d6385491899da190eb2f665 No Velocity = https://gyazo.com/4ab3eb37788c706914e7d5067736de36

Ad

Answer this question