CSCommon: MSkillDesc.h 소스 파일

MAIET

MSkillDesc.h

00001 #ifndef MSKILLDESC_H
00002 #define MSKILLDESC_H
00003 
00004 
00005 #include "MSkillTypes.h"
00006 #include "MObjectTypes.h"
00007 
00008 
00009 #include <map>
00010 using namespace std;
00011 
00012 #define FILENAME_SKILL_DESC     "skill.xml"
00013 
00014 
00017 class MSkillDesc{
00018 public:
00019     // 식별
00020     int             nID;
00021     char            Name[32];
00022 
00023     // 분류
00024     MSkillType          SkillType;
00025     MSkillFomulaType    SkillFomulaType;
00026     MPrimaSkill         PrimaSkill;
00027 
00028     // Stack
00029     unsigned int    StackFlag1;
00030     unsigned int    StackFlag2;
00031     unsigned int    OverwriteFlag1;
00032     unsigned int    OverwriteFlag2;
00033 
00034     // 비용
00035     short int       nHP;
00036     short int       nEN;
00037 
00038     // 시간
00039     short int       nActivationTime;
00040     short int       nReactivationTime;
00041     short int       nDuration;
00042 
00043     // 대상
00044     MTargetType     TargetType;
00045     MSpecies        Species;
00046 
00047     // 거리
00048     unsigned char   nRangeMin;
00049     unsigned char   nRangeMax;
00050     unsigned char   nRadius;
00051 
00052     // 조건
00053     MCharacterClass Class;
00054     unsigned char   nLevel;
00055     MWeaponType     WeaponType;
00056     unsigned char   nDifficulty;
00057     unsigned short  PrerequisiteType;
00058     int             nPrerequisiteID;
00059 
00060     // 적대감
00061     int             nHateValue;
00062 
00063     unsigned int    MODFlags;
00064 
00065     // 건강 수정치
00066     unsigned short  MOD_HP;
00067     unsigned short  MOD_EN;
00068 
00069     // 특성치 수정
00070     unsigned short  MOD_STR;
00071     unsigned short  MOD_CON;
00072     unsigned short  MOD_DEX;
00073     unsigned short  MOD_AGI;
00074     unsigned short  MOD_INT;
00075     unsigned short  MOD_CHA;
00076 
00077     // 저항력 수정치
00078     unsigned short  MOD_MR;
00079     unsigned short  MOD_FR;
00080     unsigned short  MOD_CR;
00081     unsigned short  MOD_PR;
00082     unsigned short  MOD_LR;
00083     unsigned char   nResist;
00084     unsigned char   nResistAdjust;
00085 
00086     // 방어력 수정치
00087     unsigned short  MOD_AC;
00088     unsigned short  MOD_ABS;
00089     unsigned short  MOD_MFlee;
00090     unsigned short  MOD_RFlee;
00091     unsigned short  MOD_SFlee;
00092     unsigned short  MOD_HPRegen;
00093     unsigned short  MOD_ENRegen;
00094 
00095     // 공격력 수정치
00096     unsigned short  MOD_PriATK;
00097     unsigned short  MOD_SecATK;
00098     unsigned short  MOD_Aspd;
00099     unsigned short  MOD_MCritical;
00100     unsigned short  MOD_RCritical;
00101     unsigned short  MOD_SCritical;
00102     unsigned short  MOD_MAccu;
00103     unsigned short  MOD_RAccu;
00104     float           MOD_DamageAmp;
00105 
00106     // 일반 수정치
00107     unsigned short  MOD_DSight;
00108     unsigned short  MOD_NSight;
00109     unsigned short  MOD_Spd;
00110 
00111     // 상태 수정치
00112     unsigned short  MOD_Mode;
00113     unsigned short  MOD_State;
00114     unsigned short  MOD_Ability;
00115 
00116     // 열쇠 수정치
00117     unsigned short  MOD_KeyFlag;
00118     unsigned short  MOD_KeySkill;
00119 
00120     // 프리마 스킬 수정치
00121     unsigned short  MOD_OCS;
00122     unsigned short  MOD_DCS;
00123     unsigned short  MOD_RCS;
00124     unsigned short  MOD_ECS;
00125     unsigned short  MOD_OMS;
00126     unsigned short  MOD_DMS;
00127     unsigned short  MOD_EMS;
00128     unsigned short  MOD_MCS;
00129     unsigned short  MOD_SCS;
00130 
00131     // 비쥬얼
00132     unsigned short  nIcon;
00133     unsigned short  nActivationAni;
00134     unsigned short  nUseAni;
00135     unsigned short  nHitAni;
00136     unsigned short  nSound;
00137 
00138 public:
00139     MSkillDesc(int id, char* name);
00140 
00141     bool ExamMODFlag(unsigned int nFlag)    { return (MODFlags & nFlag)? true:false; }
00142     void SetMODFlag(unsigned int nFlag)     { MODFlags |= nFlag; }
00143     void ResetMODFlag() { MODFlags = 0; }
00144 };
00145 
00146 
00147 class MSkillDescManager : public map<int, MSkillDesc*>
00148 {
00149 private:
00150 protected:
00151 
00152 public:
00153     MSkillDescManager();
00154     virtual ~MSkillDescManager();
00155     bool Read(const char* szFileName);
00156     void Clear();
00157     MSkillDesc* Find(int nDescID);
00158 };
00159 
00160 extern MSkillDescManager    g_SkillDescManager;
00161 
00162 
00163 #endif


MAIET entertainment