115 lines
3.5 KiB
C++
115 lines
3.5 KiB
C++
|
|
/// 2010.12.17 - prodongi
|
|
|
|
#include "SPlayerInfoMgr.h"
|
|
|
|
/// 2010.12.03 SUISkillWnd.h에서 분리
|
|
#ifndef _SUISkillTreeFundWnd_h_
|
|
#define _SUISkillTreeFundWnd_h_
|
|
|
|
//#include "SUIWnd.h"
|
|
|
|
/// 2011.02.24 아마 c_nOldJopCnt는 서버의 설정 값이고 c_nJopCnt는 마스터 까지 고려된 클라이언트 값인거 같다
|
|
/*
|
|
const int c_nOldJopCnt = 3;
|
|
const int c_nJopCnt = c_nOldJopCnt+1;
|
|
*/
|
|
const int c_nOldJopCnt = SPlayerInfo::JOB_INDEX_MAX;
|
|
const int c_nJopCnt = c_nOldJopCnt+1;
|
|
|
|
/// sonador #2.1.2.4.3 팻 조작 UI 연동
|
|
struct _SkillSlotInfo
|
|
{
|
|
_SkillSlotInfo(): nID(0), nX(0), nY(0), nCrrLv(0), nEnoughJLv(0), nNeedSkillID(0), nNeedSkillLv(0), nLearnNextMaxLv(0)
|
|
{
|
|
lv = 0; /// 2011.04.04 - prodongi
|
|
for( int i(0); i<c_nJopCnt; ++i )
|
|
nMaxLv[i] = 0;
|
|
}
|
|
|
|
int nID;
|
|
int nX;
|
|
int nY;
|
|
int nCrrLv;
|
|
int nMaxLv[c_nJopCnt];
|
|
int nEnoughJLv;
|
|
int nNeedSkillID;
|
|
int nNeedSkillLv;
|
|
int nLearnNextMaxLv;
|
|
short lv; /// 2011.04.04 캐릭터 레벨 - prodongi
|
|
};
|
|
|
|
class SUISkillTreeFundWnd : public SUIWnd
|
|
{
|
|
public:
|
|
struct ClickIconData
|
|
{
|
|
ClickIconData(): nSkillID(0), nX(0), nY(0) {}
|
|
|
|
std::string strCtrName;
|
|
int nSkillID;
|
|
int nX;
|
|
int nY;
|
|
};
|
|
|
|
SUISkillTreeFundWnd( SGameManager* pGameManager, SUIDisplayInfo* pDisplayInfo );
|
|
virtual ~SUISkillTreeFundWnd();
|
|
|
|
virtual void PumpUpMessage( LPCSTR lpszControlID, DWORD nMessage, DWORD lparam, DWORD wparam );
|
|
virtual void OnNotifyUIWindowOpen( bool bOpen, bool bLimitWnd = true );
|
|
virtual bool InitControls( KPoint kPos );
|
|
virtual bool InitData( bool bReload = false );
|
|
virtual void ProcMsgAtStatic( SGameMessage* pMsg );
|
|
virtual void* Perform( KID id, KArg& msg );
|
|
|
|
private:
|
|
void ClearSkillTreeList();
|
|
void initTreeImageList(); /// 2011.02.24 - prodongi
|
|
|
|
void CreateSkillTreeLists();
|
|
void UpdateTab( int nCnt );
|
|
void Create_N_Init_AllData(); /// 2011.05.30 내부에서 호출하는 InitPlayerJopInfo()에서 m_nTypeTab이 바뀔 수 있음 - prodongi
|
|
void CreateControls();
|
|
void SelectTab( int TabIndex );
|
|
|
|
void InitPlayerJopInfo();
|
|
void CreateSkillTreeList( int nJopIndex );
|
|
void GetSkillDisplayPos( const std::vector<struct SkillTreeDisplay*>& rSkillTree, int nSkillID, int& rX, int& rY );
|
|
bool CheckSkillTreeListData( int nJopIndex, const SkillTreeEx* pTree );
|
|
|
|
SUISkillTreeFundWnd::_SkillSlotInfo* GetSkillTreeInfo( int nSkillID );
|
|
void RefreshSkillData( int nJopIndex );
|
|
void SetSkillData( int nX, int nY, int nJopIndex, int nSkillID, _SkillSlotInfo* pInfo );
|
|
int GetSkillData( int nJopIndex, int nX, int nY );
|
|
void SetSkillSlotTooltip( class KUIControlIconStatic* pIcon, struct SkillBaseEx* s_data, _SkillSlotInfo* pInfo, int nJopIndex );
|
|
|
|
void RefreshMasterBoxImage( int nJobIndex );
|
|
void RefreshJopTreeImage( int nJopIndex );
|
|
const char* GetJopTreeImage( int nJopID );
|
|
|
|
void SetClickIcon( const char* lpCtrName );
|
|
void SetClickIconData( int nJopIndex, const char* lpCtrName );
|
|
void GetIndex_X_Y( int nJopIndex, const char* lpCtrName, int& nX, int& nY );
|
|
int GetSkillID( int nJopIndex, int nX, int nY );
|
|
void InitClickIconData();
|
|
void refreshTP(); /// 2011.03.28 - prodongi
|
|
|
|
void SkillUP( int nJopIndex, const char* lpCtrName );
|
|
|
|
SUIDisplayInfo* m_pDisplayInfo;
|
|
|
|
bool m_bCreateInfo;
|
|
int m_nTabType;
|
|
int m_nJopID[c_nJopCnt];
|
|
int m_nJopLv[c_nJopCnt];
|
|
__int64 m_nJopPoint; /// 2011.04.29 int->__int64 - prodongi
|
|
|
|
ClickIconData m_sClickData;
|
|
|
|
std::vector<struct SkillTreeDisplay*> m_SkillTreeDisplay[c_nJopCnt];
|
|
std::vector<_SkillSlotInfo*> m_SkillTreeList;
|
|
std::map<int, char const*> m_treeImageList; /// 2011.02.24 - prodongi
|
|
};
|
|
|
|
|
|
#endif |