Exemple #1
0
 public void GameInit() {
   if (!isInitialized) {
     LevelInit();
     try {
       game.setNrofghosts(6);
     } catch (Exception e) {
       e.printStackTrace();
     }
     currentspeed = 3;
   }
 }
Exemple #2
0
 public void finished() {
   int numberPlayer = game.getNumberPlayer();
   numberFinished += 1;
   if (numberFinished == numberPlayer) {
     // Ghosts update
     int nrOfGhosts = game.getNrofghosts();
     if (nrOfGhosts < maxghosts) {
       game.setNrofghosts(nrOfGhosts++);
     }
     if (currentspeed < maxspeed) {
       currentspeed++;
     }
     LevelInit();
   }
 }