Files
2026-06-01 12:46:52 +02:00

95 lines
3.0 KiB
C++

#pragma once
//#include "SUIWnd.h"
class SUIDisplayInfo;
typedef unsigned int AR_HANDLE;
const int c_nJewelCnt = 4;
class SUIJewelEquipWnd : public SUIWnd
{
public:
SUIJewelEquipWnd( SGameManager* pGameManager, SUIDisplayInfo* pDisplayInfo ) : SUIWnd( pGameManager ), m_pDisplayInfo(pDisplayInfo)
{};
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 bool InitData( bool bReload = false );
virtual void* Perform( KID id, KArg& msg );
bool AddItemFromInventory(AR_HANDLE hItem, int nCtrIndex); /// 아이템의 속성을 검사하고 추가한다 //servantes 2010.10.25
void RemoveJewelEquipSubItems(const char* lpCtrName);
protected:
bool IsTwoHandWeapon( class SInventorySlot* pSlot );
int AbleAddSlot( class SInventorySlot* pSlot );
bool AbleEquipJewel( AR_HANDLE hItem, int nCtrIndex );
bool IsEqualJewel( const struct ItemBaseEx_info* pItemInfo1, const ItemBaseEx_info* pItemInfo2 );
void RemoveAllSlot();
void RemoveJewelEquipItems();
void RemoveJewelEquipItem( AR_HANDLE hItem );
void AddJewelEquipItem( AR_HANDLE hItem, int nIndex );
void SetItemIconStatic( class KUIControlMultiIcon* pIconStatic, SInventorySlot* pSlot );
void SetJewelItemIconStatic( KUIControlMultiIcon* pIconStatic, int nItemCode );
void RegistItem( AR_HANDLE hItem );
const char* GetJewelCnt( int nIndex );
int GetJewelIndex( const char* szControlID );
void ReqJewelEquipMsg();
void RefreshPrice();
void RefreshAllSlot();
int GetCtrIndex( const char* lpCtrName );
const char* GetItemSlot(AR_HANDLE hItem);
void ClearItemSlots();
private:
SUIDisplayInfo* m_pDisplayInfo;
int m_nTotalPrice;
AR_HANDLE m_hMainItem;
AR_HANDLE m_hJewelItem[c_nJewelCnt];
AR_HANDLE m_hItemsList[6];
};
class SUISoulChargeWnd : public SUIWnd
{
public:
SUISoulChargeWnd( SGameManager* pGameManager, SUIDisplayInfo* pDisplayInfo ) : SUIWnd( pGameManager ), m_pDisplayInfo(pDisplayInfo), m_fRepairValue(0.0f)
{};
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 void* Perform( KID id, KArg& msg );
protected:
void AddRepairItem( SInventorySlot* pSlot );
void SetItemIconStatic( const char* lpCtrName, SInventorySlot* pSlot );
void RefreshRepairPrice();
float GetRepairValue( AR_HANDLE handle );
void ClearIconSlots();
void ClearData();
void RefreshRepairSlot();
void ClearSlot( const char* lpCtrName );
AR_HANDLE GetRepairItemHandle( const char* szControlID );
void AllEquipItemRepair();
bool IsAddRepairItem();
void ReqRepairMsg();
private:
SUIDisplayInfo* m_pDisplayInfo;
float m_fRepairValue;
AR_HANDLE m_hShield;
AR_HANDLE m_hGlove;
AR_HANDLE m_hBoots;
AR_HANDLE m_hWeapon;
AR_HANDLE m_hHelm;
AR_HANDLE m_hArmor;
};