How would you convert your current rollercoaster into CFrame?

Hey there! Currently I have made a working rollercoaster that runs in the current ROBLOX physics engine. However it is glitchy and derails often. I have heard that if you CFrame your rollercoaster it is much smoother and derails very occasionally. The problem is don’t know how you would go about it.

I have seen a few other posts regarding this issue but haven’t understood totally. I am not the best at scripting and need help on how to do this.

Thanks please contact me here on the devforum or on discord. My discoed is Stealthyx#9999

I’d reccomend looking into producing a Bézier curve, using a bunch of points along your rollercoaster, to smoothly interpolate it between them. Here’s a really good YouTube video called Bezier Curves Explained that I think is a must watch to understand how it works.

I understand the mathematics might be a bit daunting - don’t worry though! In true programmer fashion, since someone else has already done the hard work for us, we don’t have to do it ourselves :stuck_out_tongue:

There is a really good DevHub Article teaching you about it (which from the level of detail I’d guess was written by @EgoMoose - perhaps they can help you more with the understanding part :slight_smile: )

Crazyman32 also has a great module for interacting with them which you can find here on his profile. If you’d like to do away with the conceptual part and just deal with the implementing bit, just put a bunch of points into it and use the output to lerp between them!

3 Likes

Alright, thanks for your reply! Will definitely read and watch the links.

1 Like