Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 9, 2016, 1:37:46 PM (8 years ago)
Author:
kappenh
Message:

Finished Project, Maybe switch enumeration of highscores in table

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/Highscore_HS16/src/modules/invader/Invader.cc

    r11083 r11326  
    3333
    3434#include "Invader.h"
    35 
     35#include "Highscore.h"
    3636#include "core/CoreIncludes.h"
    3737#include "core/EventIncludes.h"
     
    189189        // It will misteriously crash the game!
    190190        // Instead startMainMenu, this won't crash.
     191        if (Highscore::exists()){
     192                    int score = this->getPoints();
     193                    if(score > Highscore::getInstance().getHighestScoreOfGame("Orxonox Arcade"))
     194                        Highscore::getInstance().storeHighscore("Player","Orxonox Arcade",score);
     195
     196          }
    191197        GSLevel::startMainMenu();
    192198    }
Note: See TracChangeset for help on using the changeset viewer.