Branch 6.x characters equipmentCache

Hello

How is item id stored into that?

If my character has http://www.wowhead.com/item=57525 , it is stored as: 5 and 1727

On old core it was stored as 0 and 57525 if I’m not mistaken.

Naked
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 18 0 0 18 0 0 0 0 0 0 0 0

Wearing http://www.wowhead.com/item=57525 Studded Bearskin Jacket

0 0 0 0 0 0 0 0 0 0 0 0 5 1727 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 18 0 0 18 0 0 0 0 0 0 0 0

Any pointers, please?

I made some progress. In my example 5 = chest.

[CODE]
// cache equipment…
for (uint32 i = 0; i < INVENTORY_SLOT_BAG_END; ++i)
{
if (Item* item = GetItemByPos(INVENTORY_SLOT_BAG_0, i))
{
ss << item->GetTemplate()->GetInventoryType() << ’ ’ << item->GetDisplayId() << ’ ';
if (SpellItemEnchantmentEntry const* enchant = sSpellItemEnchantmentStore.LookupEntry(item->GetEnchantmentId(PERM_ENCHANTMENT_SLOT)))
ss << enchant->ItemVisual;
else
ss << ‘0’;

            ss << ' ';
        }
        else
            ss << "0 0 0 ";
    }[/CODE]

Thanks.

Now I just need to learn some C++ :smiley:

Thanks for the answer :slight_smile: