X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FAccount.h;h=b9d24832b1f8e0579490026804d74a5695ce11e9;hb=cc92cb7b7f9b87cb791c504bf930d622d74db368;hp=53d3c945cdcff93f76eff527b773ac1a85235a5f;hpb=cd043e3f9e26c2b3406b40a354c2840941e9db7f;p=lugaru.git diff --git a/Source/Account.h b/Source/Account.h index 53d3c94..b9d2483 100644 --- a/Source/Account.h +++ b/Source/Account.h @@ -1,6 +1,6 @@ /* Copyright (C) 2003, 2010 - Wolfire Games -Copyright (C) 2010 - Côme BERNIGAUD +Copyright (C) 2010-2016 - Lugaru contributors (see AUTHORS file) This file is part of Lugaru. @@ -45,7 +45,7 @@ class Account public: static void destroy(int i); static Account* destroy(Account* a); - static Account* add(std::string name); + static Account* add(const std::string& name); static Account* get(int i); static Account* loadFile(std::string filename); static void saveFile(std::string filename, Account* accountactive); @@ -103,13 +103,13 @@ public: std::string getCurrentCampaign() { return currentCampaign; }; - void setCurrentCampaign(std::string name); + void setCurrentCampaign(const std::string& name); static int getNbAccounts() { return accounts.size(); }; private: - Account(std::string n = ""); + Account(const std::string& name = ""); int difficulty; int progress; // progress in challenge levels float points;