Train tilting on curves at low speed

I am trying to make a train system using gliders.

The train keeps tilting on curves at low speeds. This happens less at higher speeds though.

I have tried looking for solutions on the DevForum, but they don’t work with my train/system.

2 Likes

Why dont you make the glider on the bottom narrow enough to fit inside the tracks instead of lay on them?

Forgot to mention, the block is not the glider and is non-cancollide. The gliders are inside and under the block, like this:

1 Like

And how do you have the gliders welded or hinged to the block?

I used WeldConstraints to weld them to the block, then used a hinge to attach the bogie to the base.

And which body mover are you using… u might have to fix it to one axis.

I used bodyvelocity to move the train.

Have you tried to give the train more density to keep it weighted on the track… if so, you will need to raise the velocity obviously.

1 Like

It kind of works, but the train still tilts. I tested it at 20 density, would I need more?

Keep increasing density until it stays on track i would guess.

Alright let me try that.

1 Like

The train shakes a lot at higher densities, and can sometimes go through the switch rails.

I see… ok im not too familiar with trains but maybe try to look at this post here, maybe it will help you:

This post talks about using a node system to move the trains, but I want to use physics so the trains can derail (like Rails Unlimited). Sorry if I’m being a bit picky here lol.

1 Like

I can’t directly give you a solution because I don’t have much experience with BodyVelocity, however I do have experience with physical train parts. If you increase the density of the “train” you must also increase the density of the wheels/gliders. The wheels/gliders should have more density than the train that sits on them. Otherwise, physics and collision issues can occur, such as the gliders getting stuck in the rails or the entire train shaking.

3 Likes

Increasing the density appears to mostly fix the problem, so I’ll mark it as solved.

The real issue here is too much force being used here, and as a result, the BodyVelocity is more “stubborn” and will try harder to keep the train moving in a straight line, eventually making it derail.

Possible solutions you can try:

  • Reducing MaxForce (ideal solution, in order for that to be possible you also might have to decrease the friction of the gliders)
  • Increasing density (already mentioned in this thread)
  • Lowering the position where BodyVelocity is applied (on Y axis) so that instead of the whole train rotating, the force will be absorbed by the rails

Just watch the tutorial that makes a train basically with nodes:
How to make a basic train

And now, thanks :wink: .