diff --git a/Source/Contents/Items/ItemInfo.cpp b/Source/Contents/Items/ItemInfo.cpp index b18050e..0dced91 100644 --- a/Source/Contents/Items/ItemInfo.cpp +++ b/Source/Contents/Items/ItemInfo.cpp @@ -159,3 +159,40 @@ ItemInfo LookupClientItemByIdentity(const std::list& values, std::uint return ItemInfo(0); } + +// OFFSET: 0x006D5450 + +// OFFSET: 0x006D54C0 +// FUNCTION: fn_06571 +bool ItemInfo::operator<(const ItemInfo& other) const { + return this->unknown_0044 < other.unknown_0044; +} + +// OFFSET: 0x006D8B60 + +// OFFSET: 0x006D8E60 + +// OFFSET: 0x006D8FE0 +// FUNCTION: fn_06609 +bool ItemInfo::SetName(const char* name) { + this->unknown_0044 = name; + return this->unknown_0044.empty(); +} + +// OFFSET: 0x006D9010 +// FUNCTION: fn_06610 +void ItemInfo::SetItemId(int value) { + char buffer[16]; + _itoa(value, buffer, 10); + this->itemId = buffer; +} + +// OFFSET: 0x00DFB9D0 + +// OFFSET: 0x00DFBD90 + +// OFFSET: 0x00DFBDE0 + +// OFFSET: 0x00DFBE40 + +// OFFSET: 0x00DFBF70 diff --git a/Source/Contents/Items/ItemInfo.h b/Source/Contents/Items/ItemInfo.h index adb88fc..29db9c5 100644 --- a/Source/Contents/Items/ItemInfo.h +++ b/Source/Contents/Items/ItemInfo.h @@ -42,7 +42,10 @@ struct alignas(8) ItemInfo { ItemInfo& operator=(const ItemInfo& other); void Reset(); std::uint32_t Assign(const RawItemData& item); - + ItemInfo& AssignBasic(const RawItemData& item); + bool operator<(const ItemInfo& other) const; + bool SetName(const char* name); + void SetItemId(int value); /* 0000 */ std::uint32_t unknown_0000[4]; /* 0010 */ std::int32_t quantity; /* 0014 */ std::uint32_t unknown_0014[2];