#pragma once #include "SGameAvatarEx.h" class SSkilPropData { private: class KSeqModel* m_pSkillProp; K3DVector m_vStartPos; K3DVector m_vEndPos; bool m_bUse; DWORD m_dwTime; K3DMatrix m_matMatrix; struct _MOTION_FX_SET* m_pThrowFxSet; struct _MOTION_FX_SET* m_pHitFxSet; int m_nSoundId; std::string m_strSoundName; bool m_bDelay; public: enum PLAY_STEP { STEP_00 = 0, STEP_01, STEP_02, STEP_03, STEP_04, STEP_05, STEP_MAX, }; PLAY_STEP m_nStep; public: void SetAnimationData( struct _SKILL_FX* pSkillFx, int nEffectType ); void SetStep( PLAY_STEP nStep ) { m_nStep = nStep; } void SetUse( bool bUse ) { m_bUse = bUse; } void SetTime( DWORD dwTime ) { m_dwTime = dwTime; } void SetDelay( bool bDelay ) { m_bDelay = bDelay; } public: class KSeqModel* GetSkillProp() { return m_pSkillProp; } PLAY_STEP GetStep() { return m_nStep; } K3DVector* GetStartPosition() { return &m_vStartPos; } K3DVector* GetEndPosition() { return &m_vEndPos; } K3DMatrix* GetMatrix() { return &m_matMatrix; } bool GetUse() { return m_bUse; } DWORD GetTime() { return m_dwTime; } bool GetDelay() { return m_bDelay; } struct _MOTION_FX_SET* GetHitFxSet() { return m_pHitFxSet; } struct _MOTION_FX_SET* GetThrowFxSet() { return m_pThrowFxSet; } public: void PlaySoundFx( struct _MOTION_FX_SET* pFxSet, int nPlayStep, K3DVector* vPosition, SGameObject* pGameObject, AR_HANDLE hCaster ); public: SSkilPropData(); ~SSkilPropData(); }; class SGameSkilProp : public SGameAvatarEx { private: enum SKILLPROP_TYPE { TYPE_01 = 0, TYPE_02, }; public: SGameSkilProp( int nSkillID ); virtual ~SGameSkilProp(void); virtual bool Initialize( class K3DRenderDeviceDX *pDevice ); virtual void Destroy(); virtual bool Activate(); virtual bool Deactivate(); virtual bool Render( unsigned long uRenderBitVector, class KViewportObject** ppViewportList, int nViewportCount ); virtual bool Process( DWORD time, unsigned long uProcessBitVector=0 ); virtual bool IsLoadComplete() { return m_bIsInit; } void ProcessType01( DWORD dwTime ); void ProcessType02( DWORD dwTime ); float RandomNumber(float fMin, float fMax); void SetHideProp(); void SetCasterHandle( AR_HANDLE handle ); protected: //Property Set virtual const char* getClassName() { return "SGameSkilProp"; } void SetDelete( bool bDelete ); int m_nSkillID; std::string m_strView; std::string m_strExplosion; class SSkilPropData* m_pSkillPropData; bool m_bEnd; bool m_bDelete; SKILLPROP_TYPE m_nSkillPropType; unsigned short m_nVisualFxCount; DWORD m_dwOldTime; DWORD m_dwDelayTime; DWORD m_dwEndTime; float m_fSpeed; float m_fAcc; bool m_bHide; bool m_bIsHideSkillProp; AR_HANDLE m_hCaster; };