- Home /
Control individual wheels of a top down 2d vehicle
I started making a 2d top down game where you can build custom vehicles by putting different parts in a grid. I store this grid in a 2d array that looks something like this:
{(2, 1, 2),
(0, 1, 0),
(2, 1, 2)}
0 is a free space, 1 is the body and 2 is a wheel. And what I want to do is to control this vehicle by powering its wheels. So if I use the grid I showed as an example I want to move the vehicle like this: But the vehicle can be different and have wheels in different places. I tried using rigidbody addforce and many other things but I am not able to figure it out. I know this is quite broad but I would really love to know how to do it.
Any help would be appreciated.
Your answer
Follow this Question
Related Questions
Rotating a Top-Down vehicle To Face a Direction 0 Answers
Problem entering vehicle on top down 2d game 2 Answers
How do I make my enemy have animations for directions during movemvent 1 Answer
2D TopDown RPG need help making RigidBody2D AI move at a same speed 0 Answers
(2D Movement) How do I make my sprite move up, down, left, and right, without moving diagonal? 1 Answer