M_RobotNameCFG.h 735 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #pragma once
  2. #include <map>
  3. struct M_RobotNameCFGData
  4. {
  5. //索引
  6. int mindex;
  7. //昵称
  8. std::string mNickName;
  9. //用户ID(10099001~10099500)
  10. int mPlayerId;
  11. //VIP等级
  12. int mVip;
  13. //头像
  14. int mHead;
  15. //头像框
  16. int mHeadFrame;
  17. //初始金币
  18. int mGold;
  19. //炮台ID
  20. int mTurretID;
  21. //翅膀ID
  22. int mWingID;
  23. //初始道具(id+数量)
  24. std::vector<int> mItems;
  25. };
  26. class M_RobotNameCFG
  27. {
  28. public:
  29. private:
  30. static std::auto_ptr<M_RobotNameCFG> msSingleton;
  31. public:
  32. int GetCount();
  33. const M_RobotNameCFGData* GetData(int index);
  34. const std::map<int, M_RobotNameCFGData>& GetMapData();
  35. void Load();
  36. void LoadLua();
  37. void Reload();
  38. static M_RobotNameCFG* GetSingleton();
  39. static void Release();
  40. private:
  41. std::map<int, M_RobotNameCFGData> mMapData;
  42. };