static void destroyActive();
static void setActive(int i);
static void add(const std::string& name);
- static Account* get(int i);
+ static Account& get(int i);
static void loadFile(std::string filename);
static void saveFile(std::string filename);
static int getNbAccounts();
static bool hasActive();
static Account& active();
+ Account(const std::string& name = "");
+ Account(FILE* tfile);
+
void endGame();
void winCampaignLevel(int choice, float score, float time);
void winLevel(int level, float score, float time);
private:
//statics
- static std::vector<Account*> accounts;
+ static std::vector<Account> accounts;
static int i_active;
- Account(const std::string& name = "");
+ void save(FILE* tfile);
+
int difficulty;
int progress; // progress in challenge levels
float points;