Space Invaders. Both shoot and move at once?
I am making a game of Space Invaders.
The ship moves left and right at the bottom of the screen, and shoots upwards, towards the targets.
I have managed to have my ship moving left and right and when the mouse button is pressed, shoot.
But I have a problem.
Currently I'm using an infinite loop to test for moveLeft, moveRight and Fire function calls, but I want to have the code "split" into two separate procedures once the user presses fire, so that the bullet will move at a different rate to the ship etc.
Like I mention, right now all of this is controlled with a single infinite loop, which isn't giving the effect I am seeking.
Many thanks for any advice, much appreciated.