M_ActivityDBFLuckDrawCFG.h 788 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #pragma once
  2. #include <map>
  3. struct M_ActivityDBFLuckDrawCFGData
  4. {
  5. //编号
  6. int mID;
  7. //生肖抽奖消耗
  8. int mRaffleConsumption1;
  9. //幸运抽奖消耗
  10. int mRaffleConsumption2;
  11. //触发1档需要次数
  12. int mTriggerBottom;
  13. //保底1挡次数
  14. int mBottomGuard1;
  15. //保底2挡次数
  16. int mBottomGuard2;
  17. //保底3挡次数
  18. int mBottomGuard3;
  19. //消耗ID
  20. int mConsumeID;
  21. };
  22. class M_ActivityDBFLuckDrawCFG
  23. {
  24. public:
  25. private:
  26. static std::auto_ptr<M_ActivityDBFLuckDrawCFG> msSingleton;
  27. public:
  28. int GetCount();
  29. const M_ActivityDBFLuckDrawCFGData* GetData(int ID);
  30. const std::map<int, M_ActivityDBFLuckDrawCFGData>& GetMapData();
  31. void Load();
  32. void LoadLua();
  33. void Reload();
  34. static M_ActivityDBFLuckDrawCFG* GetSingleton();
  35. static void Release();
  36. private:
  37. std::map<int, M_ActivityDBFLuckDrawCFGData> mMapData;
  38. };