Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class CarMovement : MonoBehaviour
- {
- void Update()
- {
- Vector3 position;
- Quaternion rotation;
- // Get the Wheel collider's world pose values and
- // use them to set the wheel model's position and rotation
- _wheelCollider.GetWorldPose(out position, out rotation);
- _wheelModel.transform.position = position;
- _wheelModel.transform.rotation = rotation;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement