RigidBody2D velocity wont exceed 5000 ms

Trying to make a rocket sim game, kind of like a poor man’s kerbal space program, I make the rocket accelerate by applying force to it while its engines are active, this works fine until it gets to 5,000 metres per second, where the speed caps and will no longer increase…

Anybody have any idea what could be causing this? I haven’t got access to my code right now, but the only relevant line I can think of is the “rb2d.AddForce”

Any suggestions would be greatly appreciated,

Thanks.
Fred T.A

The last test I ran actually got my velocity up to 5007, and then it capped there…baffled

Mach 15 isn’t a speed that’s going to give you a great numerical simulation nevertheless, look at Physics2D.maxTranslationSpeed to control this. The default is 100 which is a speed limit per fixed-update which occurs (by default) at 0.02 (1 / 0.02 = 50Hz) so the default maximum speed per second is 100 * 50 = 5000 m/s (mach 15!!).

Feel free to change this to whatever you like but be aware that the default is already a massive increase above the Box2D default of 2 which would be 2 * 50 = 100 m/s (assuming 50Hz).

1 Like

Thanks for the info, didn’t know you could adjust the speed constraint

And yeah, the current situation isn’t working on another way of doing it, but haven’t been able to make it work yet