184 lines
5.8 KiB
C++
184 lines
5.8 KiB
C++
#pragma once
|
|
|
|
#include "SGamePlayer.h"
|
|
|
|
#define PENDINGSIZE 8
|
|
|
|
class KSeqAvatar;
|
|
|
|
class SGameLocalPlayer : public SGamePlayer
|
|
{
|
|
public:
|
|
SGameLocalPlayer();
|
|
virtual ~SGameLocalPlayer();
|
|
|
|
//Local 계열만
|
|
virtual void OnInput( class SGameInput * pInput );
|
|
|
|
virtual bool Process( DWORD dwTime, unsigned long uProcessBitVector=0 );
|
|
|
|
virtual bool Render( unsigned long uRenderBitVector, KViewportObject** ppViewportList, int nViewportCount );
|
|
|
|
virtual void NPlayAnimation( int nType , int nAniType = SEQTYPE_NORMAL, float fPlayRate = 4.8f );
|
|
|
|
virtual void SetAttackMode();
|
|
|
|
virtual void CheckPrevState();
|
|
|
|
virtual void ReqTakeItem( AR_HANDLE handle );
|
|
virtual void ReqMove( AR_HANDLE handle, const ArPosition & target, bool bSpeedSync = true, bool bChase = false );
|
|
virtual void reqKMove(AR_HANDLE handle, const K3DVector & target, bool bSpeedSync = true, bool bChase = false );
|
|
virtual void setCameraRoll(float angle);
|
|
virtual void addKMoveTargetList(K3DVector const& targetPos);
|
|
virtual bool isKMoveTargetList(std::vector<ArPosition> const& targetPosList) const;
|
|
virtual void eraseKMoveTargetList(std::vector<ArPosition> const& targetPosList);
|
|
virtual void clearMoveTargetList();
|
|
/// target == 0 공격 중지 요청
|
|
virtual void ReqAttack( AR_HANDLE target );
|
|
virtual void ReqCast( AR_HANDLE target, int nSkillID, int nSkillLv, K3DVector const& targetPos ); /// 2010.10.14 - prodongi
|
|
virtual void ReqCancelAction();
|
|
virtual void ReqThrow( AR_HANDLE target, AR_HANDLE itemhandle );
|
|
virtual void ReqSit();
|
|
virtual void ReqStandUp();
|
|
virtual void ReqNormal();
|
|
virtual void ReqBattle();
|
|
virtual void ReqMount();
|
|
virtual void ReqUnMount();
|
|
virtual void ReqEmotion();
|
|
virtual void ReqUseItem( AR_HANDLE hTargetHandle, AR_HANDLE hItemHandle, int nSkillID, AR_HANDLE hItemUseTargetHandle, const char* lpText );
|
|
|
|
void SetWayPointList( K3DVector* pWayPointList, int nWayPointSize );
|
|
void CheckWayPoint();
|
|
void ClearWayPointList();
|
|
|
|
virtual bool IsRotation() { return m_bUseRot; }
|
|
|
|
void ResetDeadDialog() { m_bDeadDialog = false; }
|
|
|
|
void ReqGameObjectMove( AR_HANDLE handle, const ArPosition & target, const ArPosition * poslist, int count, bool bSpeedSync );
|
|
|
|
/// sonador 3.10.2 PC 방 혜택 관련 라크 획득 시스템 메시지 변경
|
|
void SetLakSize( int nLak, int nBonusLak, int nBonusLakPercentage, char nBonusLakType )
|
|
{
|
|
m_nTotalLak += nLak;
|
|
m_nTotalBonusLak += nBonusLak;
|
|
m_nAbsorbLak += nLak;
|
|
m_nBonusLakType = nBonusLakType;
|
|
m_nBonusLakPercentage = nBonusLakPercentage;
|
|
}
|
|
|
|
/// sonador 3.10.2 PC 방 혜택 관련 라크 획득 시스템 메시지 변경
|
|
bool AbsorbLak( int nLak, int & nTotalLak, int & nBonusLak, int & nBonusLakPercentage, char & nBonusLakType )
|
|
{
|
|
m_nAbsorbLak -= nLak;
|
|
if( m_nAbsorbLak <= 0 )
|
|
{
|
|
nTotalLak = m_nTotalLak;
|
|
nBonusLak = m_nTotalBonusLak;
|
|
nBonusLakType = m_nBonusLakType;
|
|
nBonusLakPercentage = m_nBonusLakPercentage;
|
|
|
|
m_nTotalLak = 0;
|
|
m_nTotalBonusLak = 0;
|
|
m_nAbsorbLak = 0;
|
|
m_nBonusLakType = 0;
|
|
m_nBonusLakPercentage = 0;
|
|
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
|
|
enum PK_MODE_STATE
|
|
{
|
|
PK_MODE_ON_COUNT_DOWN = 0,
|
|
PK_MODE_OFF_COUNT_DOWN,
|
|
PK_MODE_ON,
|
|
PK_MODE_OFF,
|
|
};
|
|
|
|
/// 2012.05.17 로컬 플레이어의 인스턴스 던전/아레나 상태 - prodongi
|
|
enum INSTANCE_ARENA_STATUS
|
|
{
|
|
IAS_NORMAL,
|
|
IAS_ARENA_MENU,
|
|
IAS_INSTANCE_MENU,
|
|
IAS_ARENA_WAITING, /// 참여 대기 or 참여 카운트
|
|
IAS_ARENA_PRACTICE_WAITING,
|
|
IAS_ARENA_PRACTICE,
|
|
IAS_ARENA_GAME,
|
|
IAS_DEATHMATCH,
|
|
IAS_BEARLOAD,
|
|
IAS_BEARLOADLOBBY,
|
|
IAS_MAX,
|
|
};
|
|
|
|
void SetPKModeState( PK_MODE_STATE nPKModeState ) { m_nPKModeState = nPKModeState; }
|
|
PK_MODE_STATE GetPKModeState() { return m_nPKModeState; }
|
|
|
|
virtual void SetStatus( unsigned status );
|
|
|
|
/// 2012.05.17 - prodongi
|
|
void setInstanceArenaStatus(int status) { m_instanceArenaStatus = status; }
|
|
int getInstanceArenaStatus() const { return m_instanceArenaStatus; }
|
|
void resetPending_poslist ();
|
|
void ResetActivateSkillTime(){ m_dwActivateSkillTime = timeGetTime();}
|
|
protected:
|
|
void stopKMove();
|
|
|
|
private:
|
|
void checkValidArenaJoinSituationAtDead(); /// 2012.05.21 죽었을 때 호출이 되며, 아레나 대기중 상황 체크 - prodongi
|
|
/// 2012.08.08 - prodongi
|
|
bool checkCreatureMountCooltime();
|
|
public:
|
|
DWORD m_dwUpdateTime; ///< 서버 업데이트 시간
|
|
protected:
|
|
|
|
int m_nPrevHP;
|
|
bool m_bDeadDialog;
|
|
DWORD m_dwDeadDialogTime;
|
|
bool m_bDeadMsgInDeathMatch;
|
|
bool m_bSendResurrecMsgInDeathMatch;
|
|
DWORD m_bDeadMsgInDeathMatchTime;
|
|
DWORD m_bDeadMsgInDeathMatchTime2;
|
|
|
|
|
|
K3DVector* m_pWayPointList;
|
|
int m_nWayPointSize;
|
|
int m_nCurrentWayPoint;
|
|
std::string m_strTempAniKey;
|
|
|
|
int m_nTotalLak;
|
|
int m_nTotalBonusLak;
|
|
int m_nAbsorbLak;
|
|
char m_nBonusLakType; ///< sonador 3.10.2 PC 방 혜택 관련 라크 획득 시스템 메시지 변경
|
|
int m_nBonusLakPercentage; //
|
|
|
|
PK_MODE_STATE m_nPKModeState;
|
|
|
|
struct sKMoveTargetList
|
|
{
|
|
~sKMoveTargetList() { clear(); }
|
|
void add(K3DVector const& pos);
|
|
bool is(K3DVector const& pos) const;
|
|
bool erase(K3DVector const& pos);
|
|
void clear() { m_list.clear(); }
|
|
|
|
enum { MAX_LIST_NUM = 30 };
|
|
std::vector<K3DVector> m_list;
|
|
};
|
|
sKMoveTargetList m_kmoveTargetList;
|
|
|
|
int m_instanceArenaStatus; /// 2012.05.17 로컬 플레이어의 인던과 아레나 상태 - prodongi
|
|
|
|
/// 유저가 크리처를 타기/내리기 했을 때의 시간,
|
|
/// 이 스킬은 패시브이기 때문에 쿨 타임이 없다, 그래서 연속으로 쓸 경우 부하가 생겨서, 연속으로 못 쓰게 하기 위해
|
|
/// 자체 쿨타입을 줌 - prodongi
|
|
AR_TIME m_creatureMountedTime;
|
|
static AR_TIME CREATURE_MOUNT_COOLTIME;
|
|
|
|
ArPosition *m_pPending_poslist;
|
|
int m_nPending_handle;
|
|
DWORD m_dwActivateSkillTime;
|
|
};
|