diff --git a/Source/Client/Session.cpp b/Source/Client/Session.cpp index 4f4381b8..a4a24528 100644 --- a/Source/Client/Session.cpp +++ b/Source/Client/Session.cpp @@ -58,6 +58,14 @@ std::string g_guildName; // GLOBAL: gl_25140 static std::string s_messageEndTag = ""; +namespace EquipmentProperties { +class CEquipmentPropertiesMgr { +public: + static CEquipmentPropertiesMgr* GetInstance(); + void RefreshWearable(const int& key); +}; +} + // OFFSET: 0x00DDE860 // FUNCTION: fn_23401 int CSession::MercSkillLevel(int skillId) const { @@ -1561,6 +1569,15 @@ void CSession::UpdateFriendName(std::uint32_t characterId, const char* name) { } } +// OFFSET: 0x00DFF830 +// FUNCTION: fn_23621 +void CSession::SetEquipItem2B50(unsigned int index, const ITEM_INFO& item) { + if (index < 10) { + this->unknown_2B50[index] = item; + EquipmentProperties::CEquipmentPropertiesMgr::GetInstance()->RefreshWearable(reinterpret_cast(item.unknown_0000[3])); + } +} + // OFFSET: 0x00DFF870 // FUNCTION: fn_23622 void CSession::SetNavigationPlayerMap(const char* name) { @@ -1610,6 +1627,15 @@ void CSession::SetUnknown16EC(std::uint32_t value) { } } +// OFFSET: 0x00DFF9C0 +// FUNCTION: fn_23625 +void CSession::SetEquipItem17F0(unsigned int index, const ITEM_INFO& item) { + if (index < 10) { + this->unknown_17F0[index] = item; + EquipmentProperties::CEquipmentPropertiesMgr::GetInstance()->RefreshWearable(reinterpret_cast(item.unknown_0000[3])); + } +} + // OFFSET: 0x00DFFA00 // FUNCTION: fn_23626 int CSession::SetFriendOffline(std::uint32_t accountId, std::uint32_t characterId, unsigned char offline) { diff --git a/Source/Client/Session.h b/Source/Client/Session.h index a195e63b..e0bb3833 100644 --- a/Source/Client/Session.h +++ b/Source/Client/Session.h @@ -603,6 +603,8 @@ public: bool LoadMapPosTable(); bool ScaleMapPositions(); bool LoadFogParameters(); + void SetEquipItem2B50(unsigned int index, const ITEM_INFO& item); + void SetEquipItem17F0(unsigned int index, const ITEM_INFO& item); void ClearHomunStatus(); std::pair* InsertPair(int key, int value); int SetPairValue(int value, int slot);