Magic.h
上传用户:cydong117
上传日期:2009-11-10
资源大小:638k
文件大小:5k
- /******************************************************************************************************************
-
- 葛碘疙:
-
- 累己磊:
- 累己老:
-
- [老磊][荐沥磊] : 荐沥 郴侩
-
- *******************************************************************************************************************/
- #ifndef _CMAGIC_H
- #define _CMAGIC_H
- /******************************************************************************************************************
- CMagic Class
-
- *******************************************************************************************************************/
- class CMagic
- {
- private:
- protected:
- public:
- BYTE m_bActiveState; // 付过 劝己拳咯何.(付过家戈矫俊 荤侩等促.)
- BOOL m_bRepeat; // 局聪皋捞记狼 馆汗咯何.
- BOOL m_bFixed; // 付过狼 捞悼咯何.
- BYTE m_bMagicNum; // 付过锅龋.
- CActor* m_pxOwner; // 付过惯荤林眉.
- CActor* m_pxTarget; // 付过惯荤按眉.
- CMapHandler* m_pxMap; // 甘曼炼器牢磐.
- // 谅钎沥焊.
- SHORT m_shScrnX, m_shScrnY; // 付过胶农赴谅钎.
- FLOAT m_fFloatScrnX, m_fFloatScrnY; // 付过胶农赴谅钎.
- SHORT m_shTileX, m_shTileY; // 付过鸥老谅钎.
- SHORT m_shFireScrnX, m_shFireScrnY; // 付过积己胶农赴谅钎.
- SHORT m_shFireTileX, m_shFireTileY; // 付过积己鸥老谅钎.
- SHORT m_shTargetScrnX, m_shTargetScrnY; // 格钎痢狼 胶农赴谅钎.
- SHORT m_shTargetTileX, m_shTargetTileY; // 格钎痢狼 鸥老谅钎.(函拳瞪荐乐促.)
- // 坊歹傅沥焊.
- WORD m_wCurrDelay; // 瘤楷矫埃历厘蔼.
- WORD m_wCurrLightDelay;
- WORD m_wFrmDelay; // 橇饭烙阑 逞扁扁 困茄 瘤楷矫埃蔼.
- WORD m_wMagicLife; // 付过捞 角青登绊 乐绰 矫埃.(ms窜困)
- BYTE m_bLightRadius[2]; // 堡盔 呈厚.
- BYTE m_bLightColor[2][3]; // 堡盔 祸.
- BYTE m_bMagicColor[3]; // 祸.
- DWORD m_dwFstFrame; // 泅犁 付过狼 矫累橇饭烙.
- DWORD m_dwEndFrame; // 泅犁 付过狼 付瘤阜橇饭烙.
- DWORD m_dwCurrFrame; // 橇饭烙历厘蔼.
- BYTE m_bBlendType; // 付过阑 绢恫屈怕肺 弊副巴牢啊甫 搬沥.
- BYTE m_bOpacity; // 0 - 255窜拌. 0篮 肯傈 捧疙(扼捞飘屈怕), 255绰 阂捧疙.
- BYTE m_bSwingCnt; // 付过狼 如甸覆 炼扒阑 霖促.
- FLOAT m_fGradient;
- INT m_nShiftX;
- INT m_nShiftY;
- INT m_nDistanceX;
- INT m_nDistanceY;
- INT m_nPrevDistanceX;
- INT m_nPrevDistanceY;
- BYTE m_bDir16;
- BYTE m_bCurrSwing;
- BOOL m_bShowLight;
- D3DVERTEX m_avMagic[4];
- CWHWilImageData* m_pxMagicImg;
- INT m_nDuplicateNum;
- LPDIRECTDRAWSURFACE7 m_lpddsMagicTextr[60];
- public:
- CMagic();
- ~CMagic();
- virtual BOOL CreateMagic(BYTE bMagicNum, SHORT shFireTileX, SHORT shFireTileY,
- SHORT shTargetTileX, SHORT shTargetTileY, CActor* pxOwner = NULL, INT nTarget = 0);
- virtual VOID DestoryMagic();
- virtual BOOL UpdateMagic(INT nLoopTime);
- virtual BOOL DrawMagic();
- virtual BOOL DrawLight(CLightFog* xLightFog, INT nLoopTime);
- };
- // _SKILL_FIRE, _SKILL_SHOOTLIGHTEN 傈侩.
- class CMagicStream : public CMagic
- {
- private:
- WORD m_wMagicStart;
- POINT m_ptTileGap;
- public:
- BOOL CreateMagic(BYTE bMagicNum, SHORT shFireTileX, SHORT shFireTileY,
- SHORT shTargetTileX, SHORT shTargetTileY, CActor* pxOwner, INT nTarget, WORD wStartMagicTime, POINT ptTileGap);
- BOOL UpdateMagic(INT nLoopTime);
- BOOL DrawMagic();
- };
- class CElecMagic : public CMagic
- {
- private:
- SHORT m_shEPosX, m_shEPosY;
- BOOL m_bArrived;
- CElec m_xElec;
- public:
- virtual BOOL CreateMagic(BYTE bMagicNum, SHORT shFireTileX, SHORT shFireTileY,
- SHORT shTargetTileX, SHORT shTargetTileY, CActor* pxOwner = NULL, INT nTarget = 0);
- virtual BOOL UpdateMagic(INT nLoopTime);
- virtual BOOL DrawMagic();
- };
- // _SKILL_HOLYSHIELD, _SKILL_EARTHFIRE 傈侩.
- class CRepeatMagic : public CMagic
- {
- private:
- public:
- DWORD m_dwMagiLifeTotal;
- INT m_nEventID; // 捞亥飘肺包府等促.
- _inline CRepeatMagic()
- {
- m_nEventID = 0;
- m_dwMagiLifeTotal = 0;
- }
- BOOL CreateMagic(INT nEventID, BYTE bMagicNum, SHORT shFireTileX, SHORT shFireTileY,
- SHORT shTargetTileX, SHORT shTargetTileY, DWORD dwMagicLifeTotal, CActor* pxOwner = NULL, INT nTarget = 0);
- BOOL UpdateMagic(INT nLoopTime);
- BOOL DrawMagic();
- };
- #endif // _CMAGIC_H