How to rejoin after died
As my game is space invaders, when the alines get all the way up to the ship, the player loses a life, but how do i restart the level, do i call run() again
using LWJGL by the way
cheers
Restart the level would restart the aliens too. So, just recreate the ship at where it got destroyed.
What's LWJGL?
What's LWJGL?
Lightweight Java Game Library (LWJGL)?! Are you in the right forum buddy? You might want to make a 'reset' function that does everything for you. So in your main loop:
That way you won't have to change anything really, the game loop just keeps ojn going until you are out of lives.
Main Loop Update Enemy Update Player ... if( die) reset() ...
That way you won't have to change anything really, the game loop just keeps ojn going until you are out of lives.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement