I am trying to make motorcycle game and I want to have suspension of the wheels. In 3D there is wheels collider, but how to get wheels collider on RigidBody2D.
I have tried combining joints to achieve this but with no result.
I will be glad if someone give me some suggestions how to make suspension with the 2D rigidbody and tools.
Try the new Wheel Joint 2D for objects in Unity 4.5.
If you know of a good tutorial on this as well I would appreciate information on it since I am trying to understand this topic myself.
Hi, like the first answer posted I recomend use the new WheelJoint2D of Unity 4.5. I did a 2D Vehicle Control for the asset store, in my script the WheelJoint2D are created automatic, but some tips for setup your vehicle with this new component are:
-
Make your wheels child of the
carbody. -
The carbody and the wheels need a
rigidbody2d. -
In your carbody add 2 WheelJoint2D.
-
In the WheelJoint2D drag and drop you
wheel to connected rigidbody option. -
Adjust the anchor option of the
WheelJoint2D.
Your wheel object dont need WheelJoint2D, just your carbody.