1234567891011121314151617181920212223242526272829 |
- #pragma once
- #include <boost/unordered_map.hpp>
- #include <vector>
- struct M_HealthGameData
- {
- //ID
- int mID;
- //ÀàÐÍ
- std::string mType;
- //ÃèÊö
- std::string mDescribe;
- };
- class M_HealthGame
- {
- public:
- private:
- static std::auto_ptr<M_HealthGame> msSingleton;
- public:
- int GetCount();
- const M_HealthGameData* GetData(int ID);
- boost::unordered_map<int, M_HealthGameData>& GetMapData();
- void Reload();
- void Load(const std::string& path);
- void Load();
- static M_HealthGame* GetSingleton();
- private:
- boost::unordered_map<int, M_HealthGameData> mMapData;
- };
|