Vehicle Bounce Issues

Hi, I’ve been working on a scooter for a project of mine that I’m doing at the moment and it’s my first time working in depth with vehicles and anything of that sort. I managed to get it to work (in my opinion) decently well, but I’ve run into a problem that I can’t figure out how to fix.

Whenever I hit just about anything or drive into anything with it, the vehicle tends to bounce high up into the air. I know that it’s because it’s bending in a way (see picture below) and causing it to fling itself upwards, but I’m not sure how to get around fixing it.

image
https://gyazo.com/671372a7a8c063a764688907caa687c1.gif

I’m currently just using a DriverSeat and a script that looks at it’s throttle and then uses BodyVelocity and BodyGyro to handle its movement and turning. I’ve tried increasing the scooter and player’s density, but nothing I’ve tried has worked so far.
I hope that someone can help me out, thanks!

Well, from what I do know or assume of the current engine of Roblox is that simply a lot of the time any objects that aren’t anchored like the Player, Brick, Etc always had weird collisions and always clip into the brick. Back to the scooter its most likely that the scooter clips into the block itself instead of stopping like it should which the game tries to push it back out because it isn’t normal. Most of it is interpretation and what I believe how the system works, I could be wrong. Still some solutions can be seen on the modern day vehicle systems on Roblox such as suspension on vehicles, because the tires are independent they just don’t fling as the whole scooter model is clipping into it (assuming its one big model linked together. Still I would recommend to try is adding custom collisions to either the brick or scooter that round out the clipping as its easier on a smooth surface. Sorry if this was a bit long but I think explaining it in some way should help you find a solution. Good luck

3 Likes

What are the properties used in your BodyVelocity?

1 Like

image
The script simply makes it’s velocity the DriverSeat’s lookVector times an adjusting value to get the speed.

Try setting the scooter parts to massless. I think it helps with part bounces.

I gave it a go and as far as I could tell it didn’t seem to make much of a difference, appreciate the help though!

MaxForce is inf? I’ve seen before that to prevent flinging people would avoid math.huge and inf numbers and instead try numbers like 100000

1 Like

Tried that as well, to no effect though.

It seems like it might’ve helped a tad bit, at least from some quick messing with it. Still ends up flying it into the air though, just not as much.

I once had this problem with a motorcycle I developed for a group, it would jump while going over the curb. I remember that it was something in the code I changed that fixed this, but I don’t exactly recall what. It may possibly have to do with setting the PlatformStand property of the Humanoid to true. Otherwise, it would be helpful to see some of your code if you are willing.

What are your BodyGyro limits? You probably have the BodyGyro Torque limits at infinite. Instead of allowing your BodyMovers to have infinite force, how about you set it to a sane and physically realistic value.

Decrease it lower than 10000. Start at 10 and work up in smaller increments. Furthermore, set realistic density/mass for your vehicle parts.

Sorry for the ridiculously late reply, this took a backseat for awhile.
Anyways, I did decrease it a lot and got the actual bounce effect to go away, so thanks for that.

However, it’s created a new problem that I’m not sure how to fix either. When it hits something like the part I used in the original post, it will now glitch and sorta jolt itself on it. You said to set realistic density/mass for the parts, which I’ve had them at the default settings so I’m not sure if that’s what you are referring to or not.

Here’s what I mean:
https://gyazo.com/b010914fec18fa3428b64724b6850f48.gif

Any ideas?

I’m fairly sure it doesn’t have anything to do w/ PlatformStand since there’s nothing that would trigger that. Thanks for your help anyways though!

You might want to see what collisions you have on the scooter. Using the studio setting:
Settings -> Physics Tab -> See Decomposition Geometry (True)
Will let you see the hitboxes of the scooter after you restart.

Other than hitboxes it might be the use of deprecated bodymovers. You could try switching over to the modern Vector/Line Force. Could help? But I’ve never used them, Ironically.

Instead of Vector3.new(math.huge,0,math.huge) try Vector3.new(scootermass^2,0,scootermass^2)