Advanced Vehicle Script

Hello mates,
I’m working with alternative vehicle script from tutorial.
I’m optimized few things but cant solve two things…

1-I’m using one mesh for wheels. when i start game, left wheels are turning back to 180 degrees. If i turn empty objects (WheelPin_FL in screenshot here http://i38.tinypic.com/25k7v5z.png) the force for drivetrain also turns and car acts weird.
2-If you play demo, you’ll see vehicle have some grip problem. The code is far away from basic wheel collider so slip velocity doesn’t work. :cry:

I don’t know if the developer here so i cant ask this to him. So if anyone played and can optimized this script can help me with correction please? :roll:

You can check the webdemo here:
http://www.unitstudios.com/unity3d/carrig.html

Thanks!

As for 1. that should be simple to fix. Just create a child gameObject of the wheel for the wheel mesh, which you can then rotate by 180 degrees.

For 2. it’s hard to tell what’s going on without looking into this in detail. Check out the sample cars in the alternate vehicle model folder, and compare those to your car. Then gradually apply changes to see which settings are causing your problems. When tweaking vehicle physics, it is always advisable to change settings on by one and test a lot in between, instead of changing many settings at once - because that way, you always know which change has what effect.

Thanks for reply Jonas,
i’ll take your advice on #1.

But about #2,
Same problem exists on original project too…
Lamborghini also have same behavior. :frowning:

Jonas,
If you remember your code, is there any way to improve grip of the wheels from code?