Vehicle Mechanics w/ Body Movers

I have been toying with vehicle physics for a while and I am not having much luck with the basic setup I have made. The main problem is simply the method I am using. Body Velocity works great for moving forwards and backward but when combined with physics based turning it does not play well.

Physics based turning? What I mean by that is simply that the tires (when rotated with a motor) doesn’t want to turn when the body velocity has a high Max Force (which it needs in order to make it over slopes.

I have search through the forum to find different methods using body movers and wasn’t to exited to find that none of them answered my question as elaborately as I would like.

2 Likes

This is because the BodyVelocity still wants to keep going in the same direction. It is absolute, not relative to the vehicle, making this effect even more noticable.

How we achieve this with trains is by taking the LookVector from the motor’s centre part

LookVector can be fetched using the following code:

local look = Part.CFrame.LookVector

We can then multiply that by the velocity you want to achieve

local speed = 10
BodyVelocity.Velocity = speed * look --you may need to make Look negative, this can be done simply by putting a '-' infront of it (-look)
1 Like