167 lines
7.1 KiB
C++
167 lines
7.1 KiB
C++
#pragma once
|
|
|
|
//#include "SUIWnd.h"
|
|
#include "SUIPartyTypes.h"
|
|
|
|
class SMessengerMgr;
|
|
class SUIDisplayInfo;
|
|
class SGameAvatarEx;
|
|
class SUIPartyDualWnd;
|
|
|
|
struct PartyCreatureInfo
|
|
{
|
|
PartyCreatureInfo::PartyCreatureInfo() { /*bRender = bRenderUI = false;*/ hCreature1st = hCreature2nd = hMaster = 0; }
|
|
PartyCreatureInfo::PartyCreatureInfo(AR_HANDLE _handle, AR_HANDLE _hMaster)
|
|
:hCreature1st(_handle), hCreature2nd(0), hMaster(_hMaster)/*, bRender(true), bRenderUI(true)*/ {}; // 2010.08.30 - prodongi
|
|
PartyCreatureInfo::PartyCreatureInfo(AR_HANDLE _handle1, AR_HANDLE _handle2, AR_HANDLE _hMaster)
|
|
:hCreature1st(_handle1), hCreature2nd(_handle2), hMaster(_hMaster)/*, bRender(true), bRenderUI(true)*/ {}; // 2010.08.30 - prodongi
|
|
|
|
//bool bRender;
|
|
//bool bRenderUI; // 2010.08.30 - prodongi
|
|
AR_HANDLE hCreature1st; // 2011.10.12 : servantes : 크리처 핸들 변수명 교체
|
|
AR_HANDLE hCreature2nd; // 2011.10.12 : servantes : 크리처 핸들 변수명 교체
|
|
AR_HANDLE hMaster;
|
|
};
|
|
|
|
|
|
/// 파티원 지속효과
|
|
class SUIPartyStateWnd : public SUIWnd
|
|
{
|
|
public:
|
|
SUIPartyStateWnd( SGameManager* pGameManager, SUIDisplayInfo* pDisplayInfo );
|
|
~SUIPartyStateWnd() { ClearCtr(); }
|
|
|
|
virtual bool InitControls( KPoint kPos );
|
|
virtual bool InitData( bool bReload = false );
|
|
virtual void PumpUpMessage( LPCSTR lpszControlID, DWORD nMessage, DWORD lparam, DWORD wparam );
|
|
virtual void ProcMsgAtStatic( SGameMessage* pMsg );
|
|
virtual void OnNotifyUIWindowOpen( bool bOpen, bool bLimitWnd = true );
|
|
virtual DWORD OnMouseMessage(DWORD dwMessage, int x, int y);
|
|
|
|
void ClearCtr();
|
|
|
|
void ChangeSize(int nCount);
|
|
void MoveStateWindow( int nIndex, int nY, bool Creature );
|
|
void SetSlotData_N_Enable( int nIndex, class SPlayerSlot* pSlot, bool bCreature );
|
|
void SetSlotData_N_Enable( int nIndex, AR_HANDLE handle, bool bCreature );
|
|
void DisableAllSlots();
|
|
void RefreshEnableSlots();
|
|
void RefreshEnableSlot(int id);
|
|
void RefreshSlots();
|
|
void RefreshSlot(int id);
|
|
void _RefreshSlots();
|
|
void RefreshCreatureSlots();
|
|
void RefreshCreatureSlot(int id);
|
|
class SUIPartyStateSetWnd* GetChildWnd( AR_HANDLE handle );
|
|
|
|
bool ChangeCreature( AR_HANDLE handle );
|
|
bool ChangeMasterCreature( AR_HANDLE hMaster );
|
|
int AddCreature( AR_HANDLE handle );
|
|
//void AddCreature( int nIndex ); // 2010.08.30 - prodongi
|
|
void LeaveMaster( AR_HANDLE hMaster );
|
|
int LeaveCreature( AR_HANDLE handle );
|
|
int RemoveCreature( AR_HANDLE handle );
|
|
//void RemoveCreature( int nIndex ); // 2010.08.30 - prodongi
|
|
//void setRenderCreatureUI(int index, bool render); // 2010.08.30 - prodongi
|
|
void SetCreatureMaster( int nPos, AR_HANDLE hMaster );
|
|
bool IsAddCreature( AR_HANDLE handle, bool bMaster/*=false*/ );
|
|
SGameAvatarEx* GetPlayerPtr( int nIndex );
|
|
|
|
void ClearCreatureList();
|
|
AR_HANDLE GetMaster( AR_HANDLE handle );
|
|
SGameAvatarEx* GetMasterPtr( AR_HANDLE handle );
|
|
SGameAvatarEx* GetObject( AR_HANDLE handle );
|
|
void Move( int nX, int nY );
|
|
bool IsRenderStateLeft(int nRight=-1);
|
|
void setCreatureListHandle(int index, AR_HANDLE masterHandle, AR_HANDLE firstCreatureHandle);
|
|
|
|
void ChangeSizeStateWnd(bool bBig); // 2011.11.14 - servantes : 버프 크기 변환
|
|
|
|
void SetPartyName(const char* pName) { m_strPartyName = pName; }
|
|
std::string* GetPartyName() { return &m_strPartyName; }
|
|
|
|
void SetLinkPartyUIPtr(SUIPartyDualWnd* pLinkPartyUI) { m_pLinkPartyUI = pLinkPartyUI; } // 2011.11.14 - servantes : 연결된 파티창 포인터
|
|
SUIPartyDualWnd* GetLinkPartyUIPtr() { return m_pLinkPartyUI; } // 2011.11.14 - servantes : 연결된 파티창 포인터
|
|
|
|
bool GetBuffSizeBigFalg() { return m_bSizeBig; } // 2011.11.14 - servantes : 버프 크기 변환플래그
|
|
void SetBuffSizeBigFalg(bool b) { m_bSizeBig = b; } // 2011.11.14 - servantes : 버프 크기 변환플래그
|
|
|
|
//bool GetCharacterBuffFlag(int id) { return m_MemberStateRender[id]; } // 2011.11.14 - servantes : 버프 크기 변환플래그
|
|
//bool GetCreatureBuffFlag(int id) { return m_CreatureStateRender[id]; } // 2011.11.14 - servantes : 버프 크기 변환플래그
|
|
void InitBuffFlag();
|
|
|
|
protected:
|
|
/// 2011.12.21 플레이어와 멤버의 렌더 상태를 설정해준다 - prodongi
|
|
//void setRenderAllState(bool render);
|
|
/// 2011.12.21 플레이어와 멤버의 렌더 상태를 설정해준다
|
|
//void setRenderState(bool render, int objType, int index);
|
|
void setShowParent(bool show);
|
|
AR_HANDLE getMainCreature(AR_HANDLE hMaster);
|
|
AR_HANDLE getMainCreature(SGameAvatarEx* master);
|
|
|
|
private:
|
|
std::string m_strPartyName;
|
|
bool m_bStateRender;
|
|
//bool m_MemberStateRender[SLOT_MAXLINE];
|
|
//bool m_CreatureStateRender[SLOT_MAXLINE];
|
|
|
|
SUIDisplayInfo* m_pDisplayInfo;
|
|
bool m_bLeftRender;
|
|
PartyCreatureInfo m_vecCreatureList[SLOT_MAXLINE];
|
|
|
|
bool m_bSizeBig; // 2011.11.14 - servantes : 버프 크기 변환플래그
|
|
|
|
SUIPartyDualWnd* m_pLinkPartyUI; // 2011.11.14 - servantes : 연결된 파티창 포인터
|
|
|
|
// bool* m_MemberStateRender; //[SLOT_MAXLINE];
|
|
// bool* m_CreatureStateRender; //[SLOT_MAXLINE];
|
|
//
|
|
// SUIDisplayInfo* m_pDisplayInfo;
|
|
// bool m_bLeftRender;
|
|
// PartyCreatureInfo* m_vecCreatureList[SLOT_MAXLINE];
|
|
};
|
|
|
|
|
|
//==================================================================================================================================================
|
|
class SUIPartyStateWndMgr : public SUIWnd
|
|
{
|
|
public:
|
|
SUIPartyStateWndMgr( SGameManager* pGameManager, SUIDisplayInfo* pDisplayInfo );
|
|
virtual ~SUIPartyStateWndMgr();
|
|
|
|
virtual SUIWnd* CreateWnd( const char* szFile, KUIWndManager* pWndManager, KPoint kPos, int nWindowID );
|
|
virtual bool InitControls( KPoint kPos );
|
|
virtual void PumpUpMessage( LPCSTR lpszControlID, DWORD nMessage, DWORD lparam, DWORD wparam );
|
|
virtual void ProcMsgAtStatic( SGameMessage* pMsg );
|
|
virtual void OnNotifyUIWindowOpen( bool bOpen, bool bLimitWnd = true );
|
|
virtual DWORD OnMouseMessage(DWORD dwMessage, int x, int y);
|
|
|
|
int AddCreature( SGameMessage* pMsg );
|
|
int RemoveCreature( SGameMessage* pMsg );
|
|
void RemoveMaster(SGameMessage* pMsg);
|
|
|
|
void InitWnd();
|
|
SUIWnd* CreateParty(int nPartyType, const char* strPartName, int nWindowID, int nSizeType);
|
|
void RemoveParty(const char* strPartName);
|
|
void AddWnd(SUIPartyStateWnd* pWnd);
|
|
SUIPartyStateWnd* FindWnd(int id);
|
|
SUIPartyStateWnd* FindWnd(const char* strPartName);
|
|
void HideAndClearWnd(char const* partyName);
|
|
void ClearWnd();
|
|
|
|
void ChangeSizeStateWnd(const char* pPartyName, bool bBig); // 2011.11.14 - servantes : 버프 크기 변환
|
|
|
|
//int GetBuffVisible(const char* strPartName, bool bChar, int id_slot, bool& bShow);
|
|
void InitStateWndBuffFlag(std::string* pPartyName);
|
|
void SetShowStateWndFlag(std::string* pPartyName, bool bShow);
|
|
void RefreshStateWnd();
|
|
|
|
protected:
|
|
void setMemberCreatureInfo(std::vector<std::string> const& textList);
|
|
void setMemberCreatureInfo(AR_HANDLE hMaster, AR_HANDLE hMainCreature, char const* partyName);
|
|
|
|
private:
|
|
SUIDisplayInfo* m_pDisplayInfo; // display
|
|
std::map<std::string, SUIPartyStateWnd*> m_mapWnd; // buff ui
|
|
};
|