quick and dirty editor works for now
This commit is contained in:
@@ -23,6 +23,7 @@ class Model : public Engine::ModelBase {
|
||||
/* Level loading etc. */
|
||||
int DoLoadLevel (const char* filename);
|
||||
int DoSaveLevel (const char* filename);
|
||||
void ResetLevel ();
|
||||
|
||||
void ReloadLevel();
|
||||
void ProceedToNextLevel ();
|
||||
@@ -34,6 +35,12 @@ class Model : public Engine::ModelBase {
|
||||
mPlayerName = name;
|
||||
};
|
||||
|
||||
std::string GetLevelName() { return mLevelName; };
|
||||
void SetLevelName(const std::string &name) {
|
||||
Engine::LogMessage("new level name: %s", name.c_str());
|
||||
mLevelName = name;
|
||||
}
|
||||
|
||||
/* Highscore */
|
||||
struct HighscoreEntry {
|
||||
HighscoreEntry(): name ("unknown"), points (0) { };
|
||||
@@ -74,12 +81,15 @@ class Model : public Engine::ModelBase {
|
||||
int mPlayerLives;
|
||||
unsigned int mPoints;
|
||||
unsigned int mCurrentLevelIndex;
|
||||
|
||||
std::string mPlayerName;
|
||||
std::vector<std::string> mLevelList;
|
||||
std::string mLevelName;
|
||||
|
||||
virtual bool OnReceiveEvent (const Engine::EventBasePtr &event);
|
||||
|
||||
friend class View;
|
||||
friend class Controller;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user