1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- #pragma once
- #include <map>
- struct Fish_ArmatureCFGData
- {
- //模型ID
- int mID;
- //名字
- std::string mName;
- //资源类型
- int mResType;
- //资源名字
- std::string mResName;
- //资源路径
- std::string mResPath;
- //移动动作
- std::string mMoveAction;
- //死亡动作
- std::string mDieAction;
- //颜色
- int mColor;
- //缩放
- float mScale;
- //固定方向
- bool mEnableFlipped;
- //碰撞数据
- std::vector<float> mCollider;
- //附加动画
- std::vector<int> mAttachArmatures;
- //标记
- std::string mFixFlag;
- //光圈
- std::vector<std::string> mCircles;
- //附加粒子
- std::vector<std::string> mAttachParticles;
- };
- class Fish_ArmatureCFG
- {
- public:
- private:
- static std::auto_ptr<Fish_ArmatureCFG> msSingleton;
- public:
- int GetCount();
- const Fish_ArmatureCFGData* GetData(int ID);
- const std::map<int, Fish_ArmatureCFGData>& GetMapData();
- void Load();
- void LoadLua();
- void Reload();
- static Fish_ArmatureCFG* GetSingleton();
- static void Release();
- private:
- std::map<int, Fish_ArmatureCFGData> mMapData;
- };
|