Quantcast
Channel: Unity Forum
Viewing all articles
Browse latest Browse all 1466670

How to prevent the Car from tilting/flipping or constrain it to x-z axes?

$
0
0
Hi.

I have some problems with the Car game I am creating.

I have a simple car (rigidbody) consisting of a car body (a cube with box collider) and 4 wheels (wheel colliders). I am using this simple script for the car movement. It's simple, but problematic.

The thing is that I want to create a game in which the car movement is constrained to X-Z axes. Even more, the car's wheels should never even detach from the ground. But that is the problem...

How to prevent the Car from tilting/flipping or constrain it to x-z axes?

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>