I think he means these positions: 1st place, 2nd place, and so on.

Depending on how open your track is, you could have check points (they don't have to be visible to the player) at each corner and turn, and based on which checkpoints they've passed and how close they are to the next one, cars can figure out their place.

For a more complex race with tons of different paths you could resort to A* pathfinding, if you can set it up so that paths can't go back over the finish line (if it's a lap race).

Whoever has the shortest path is leading. You'd only need to re-calculate the paths every few frames or so.

Jibb


Formerly known as JulzMighty.
I made KarBOOM!