Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice

Car Tutorial didn't work in Unity 5.0.1

Discussion in 'Scripting' started by bawenang, May 26, 2015.

  1. bawenang

    bawenang

    Joined:
    Aug 18, 2012
    Posts:
    119
    Hi,

    I've actually made a simple race game using Car Tutorial on Unity 3.5.7 before. I know that it's not that good but it is good enough at the time. And now there is another similar project of mine, which also includes a basic car physics, and I plan to use it again. However, when I tried it on Unity 5.0.1, it doesn't work properly. The car goes bouncing around even when I did nothing. It's probably the WheelFrictionCurve settings that is the culprit. Because I tried the same settings on a new project with the Wheel Collider tutorial from here: http://docs.unity3d.com/Manual/WheelColliderTutorial.html, and it also behave the same way. It bounces around endlessly. That is weird though, because it worked fine in 3.5.7 (and 4.6 if I recall). So, anybody know a working Car Tutorial project for Unity 5.0.1 that I can look for? And also what is the best settings for WheelFrictionCurve? BTW, I know "vaguely" (by vaguely, I mean almost nothing) about how the friction works in Unity. I know the basic physics principal of friction though, but still don't understand much about WheelFrictionCurve to set it to its proper values.

    Thanks in advance.
     
  2. bawenang

    bawenang

    Joined:
    Aug 18, 2012
    Posts:
    119
    So I've tried setting the friction curve again and it now can stay on the ground but when I move it forward, it will turn and slip by itself after it drove a few steps. This is my settings (for both forwardFriction and sidewaysFriction):

    Anyway, I decided to use a faux car physics using a box collider, rigid body, and the usual physics. So basically the car is walking right now. It would look weird I reckon, since it won't drift when it turns. But it's better than cannot move at all. If someone can help me with the friction curve, please do help me with this if you can. I still want to use a proper car physics if I can.

    Thanks a lot in advance.
     
    Last edited: May 27, 2015