Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/src/orxonox/Highscore.h @ 11479

Last change on this file since 11479 was 11356, checked in by patricwi, 8 years ago

merged space race with trunk

File size: 1.1 KB
RevLine 
[11313]1#include <string>
2#include "core/config/Configurable.h"
3#include "OrxonoxPrereqs.h"
4#include "util/Singleton.h"
5// tolua_begin
6namespace orxonox
7{
8class _OrxonoxExport Highscore
9// tolua_end
10 : public Singleton<Highscore>, public Configurable
11{ //tolua_export
12    friend class Singleton<Highscore>;
13    public:
14        Highscore();              // Constructor
15        void setConfigValues(); // Inherited function
[11333]16        void storeHighscore(std::string level, int points);
[11315]17
18        int getHighestScoreOfGame(std::string game);
[11313]19        // tolua_begin
20        inline unsigned int getNumberOfHighscores()
[11315]21                { return this->highscores_.size(); }
[11313]22            inline const std::string& getHighscore(unsigned int index)
[11315]23                { return this->highscores_[index]; }
[11313]24
25        static Highscore& getInstance()
26                { return Singleton<Highscore>::getInstance(); }
27
28        // tolua_end
29
30
31    private:
[11315]32        std::vector<std::string> highscores_;
[11313]33        float version_;
[11333]34        std::string playerName_;
[11313]35        static Highscore* singletonPtr_s;
36}; //tolua_export
37
38
39} //tolua_export
Note: See TracBrowser for help on using the repository browser.