#pragma once #include #include struct Fish_OddsCFGData { //key int mID; //鱼名字 std::string mFishName; //基本命中几率(1/1000000) std::vector mHitRate; //新手buff命中(1/1000000) std::vector mHitRateHeaven; //充值buff命中(1/1000000) std::vector mHitRateHeavenBuff; //大水池buff命中(1/1000000) std::vector mHitRateBuff; //大水池dbuff命中(1/1000000) std::vector mHitRateDBuff; //个人buff命中(1/1000000) std::vector mHitRatePersonalBuff; //新手dbuff命中(1/1000000) std::vector mHitRateHell; //充值dbuff命中(1/1000000) std::vector mHitRateHellBuff; //首次击杀命中(1/1000000) std::vector mFirstHitBuff; //星星掉落率(万分比) int mStarRate; //掉落物品(只能配置捕鱼道具) std::vector mDropItems; //额外掉落(鱼掉落概率*(当前炮倍/最大炮倍) std::vector mExtraDrop; //大水池(大水池1 其他池0) int mBigPool; //玩法池(玩法池1 其他池0) int mPlayPool; //新手buff(普通buff 1 特殊鱼2) int mNoviceBuff; //充值buff(普通buff 1 特殊鱼2) int mRechargeBuff; //首杀加成 std::vector mFirstBuff; //分组 std::vector mGroup; //掉落对应的活动ID int mActivityId; //活动掉落--道具,概率 std::vector mActivityDropItems; //积分倍率(中级场) std::vector mrate; //龙鳞分数 int mSquama; }; class Fish_OddsCFG { public: private: static std::auto_ptr msSingleton; public: int GetCount(); const Fish_OddsCFGData* GetData(int ID); boost::unordered_map& GetMapData(); void Reload(); void Load(const std::string& path); void Load(); static Fish_OddsCFG* GetSingleton(); private: boost::unordered_map mMapData; };