Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 9, 2013, 2:53:57 PM (10 years ago)
Author:
zifloria
Message:

finito! (apart from explosions)

Location:
code/branches/invaders/src/modules/invader
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/invaders/src/modules/invader/InvaderHUDinfo.cc

    r9874 r9884  
    7474                {
    7575                    setPosition(Vector2(0.1, 0.65));
    76                     this->setCaption("Game ends in 30 seconds.\nPress (e)xit / (q)uit to go to the main menu.\nTo restart press space.");
     76                    this->setCaption("Game ends in 30 seconds.\nPress (e)xit / (q)uit to go to the main menu.\nTo restart fly out of the screen!");
    7777                    setTextSize(0.05);
    7878                    this->InvaderGame->bEndGame = true;
  • code/branches/invaders/src/modules/invader/InvaderShip.cc

    r9874 r9884  
    7171                posforeward += dist_y;
    7272            else
     73            {
    7374                velocity.y = 0;
     75                // restart if game ended
     76                if (getGame())
     77                    if (getGame()->bEndGame)
     78                    {
     79                        getGame()->start();
     80                        return;
     81                    }
     82            }
    7483            if (pos.z + dist_x > 42*2.5 || pos.z + dist_x < -42*3)
    7584                velocity.x = 0;
     
    129138    {
    130139        isFireing = bBoost;
    131         // restart if game ended
    132         if (getGame())
    133             if (getGame()->bEndGame)
    134                 getGame()->start();
    135140    }
    136141    inline bool InvaderShip::collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
Note: See TracChangeset for help on using the changeset viewer.