You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
1.3 KiB
43 lines
1.3 KiB
package base;
|
|
import java.io.IOException;
|
|
import org.apache.logging.log4j.LogManager;
|
|
import org.apache.logging.log4j.Logger;
|
|
import playground.*;
|
|
|
|
|
|
/**
|
|
* main class to start a game with only one level.
|
|
*
|
|
*/
|
|
public class BreakoutGame extends GameLoop {
|
|
|
|
private static Logger logger = LogManager.getLogger(BreakoutGame.class);
|
|
|
|
/**
|
|
* adds only one level to play ({@link playground.LevelBreakout1}).
|
|
*/
|
|
@Override
|
|
public void defineLevels() {
|
|
this.resetLevels(); // removes Level1 added by superclass constructor
|
|
<<<<<<< HEAD
|
|
//this.addLevel(new BreakoutLevel1()); // FIXME add this as soon as your level exists
|
|
this.addLevel(new BreakoutLevel2());
|
|
=======
|
|
this.addLevel(new BreakoutLevel3()); // sorry for the git conflict this may cause!
|
|
>>>>>>> aa2436e4a45e3ac1bb4b8beb537007ae3887598e
|
|
}
|
|
|
|
/**
|
|
* starts this game.
|
|
*
|
|
* @param args command line parameters (forwarded to {@link GameLoop#runGame(String[])}).
|
|
* @throws IOException if highscore.txt file cannot be written or accessed, the exception is
|
|
* thrown (and game ends).
|
|
*/
|
|
public static void main(String[] args) throws IOException {
|
|
GameLoop myGame = new BreakoutGame();
|
|
logger.info("BreakoutGame program started.");
|
|
myGame.runGame(args);
|
|
}
|
|
|
|
}
|