Beispiel #1
0
 /*
 public void makeSmokeFireball()
 {
     if (delay > 100)
     {
         int randomNumber = Greenfoot.getRandomNumber(1000);
         if (randomNumber < 50)
         {
             SmokeFireball smokeFireball = new SmokeFireball();
             addObject(smokeFireball, 500, 475);
             delay = 0;
         }
         if (randomNumber >= 50 && randomNumber < 100)
         {
             SmokeFireball smokeFireball = new SmokeFireball();
             addObject(smokeFireball, 95, 661);
             delay = 0;
         }
         if (randomNumber >= 100 && randomNumber < 150)
         {
             SmokeFireball smokeFireball = new SmokeFireball();
             addObject(smokeFireball, 160, 493);
             delay = 0;
         }
         if (randomNumber >= 150 && randomNumber < 200)
         {
             SmokeFireball smokeFireball = new SmokeFireball();
             addObject(smokeFireball, 637, 423);
             delay = 0;
         }
         if (randomNumber >= 200 && randomNumber < 250)
         {
             SmokeFireball smokeFireball = new SmokeFireball();
             addObject(smokeFireball, 422, 285);
             delay = 0;
         }
     }
 }
 */
 public void checkDoor() // sean
     {
   if (ninja.checkInfernoDoor() == true) {
     burningSteppes.stop();
     Greenfoot.setWorld(new Inferno2(ninja));
   }
 }
Beispiel #2
0
 public void gameover() { // Hayden
   ninja.setHP(ninja.getArmor());
   burningSteppes.stop();
   Greenfoot.setWorld(new Inferno1(ninja));
 }