I'm making a penalty shootout game. I have three sprites for the goalkeeper (One which is upright; the other is tilted to the left; and the other is tilted to the right). I have made a 1 player game. So that the player of the game is the kicker and the goalkeeper moves in a random direction (left, right, centre). I have basically made it so that the goalkeeper picks a random "direction" (my variable). If direction=1 it stays in the centre). If direction=2 it switches to the tilted costume and glides left likewise with direction=3.
The problem is how do I make it so that when a certain key is pressed and the goalkeeper moves in a particular direction, it changes the score accordingly.
Offline