Tell me how to make such a condition.
I need to get every pixel passed by the player. That is, if a player has move 100 pixels, I want to add 100 pixels to the variable.
that is, I need to get the distance traveled by the player. How can I do that?
In fact, I need to take away a strip of fuel when the car goes.