- summary: One item stack: which item it is, how many, its unique handle, and the effects rolled onto it.
- area: Game.Inventory
One item stack: which item it is, how many, its unique handle, and the effects rolled onto it.
Kind struct · Area Game.Inventory
One item instance. The same record is reused across the inventory, exchange and storage protocols, so everything below applies wherever it appears.
THE TWO IDS ARE BOTH INT32 AND ARE TRIVIAL TO SWAP. THIS IS THE EASIEST BUG TO WRITE AGAINST THIS PROTOCOL.
gid the TEMPLATE id - WHAT KIND of item this is. Every copy of the same
item in the game shares one gid. Use it to look the item up in your
own data.
uid the handle for THIS stack, unique within the character. This is the
value a destroy, drop, move or exchange request wants.
Send a gid where a uid belongs and you address a different stack or none at all. Nothing in the declaration separates them: on the current build both are int32 and the field numbers were shuffled, so read by NAME, never by position.
effects is the roll on this instance - see ObjectEffect. It is a oneof:
branch on which member is set, never read positionally.
storage_quantities is not an Ankama name - see InventoryQuantity.
Not sent on its own — it is only ever reached as a member of another message. proven
Used by
Fields
| # | Field | Type | Meaning | You set it |
|---|---|---|---|---|
| 1 | storage_quantities | repeated InventoryQuantity | How this stack is split across the character's storages, counted per storage. WE CHOSE THIS NAME. The beta build predates the field, so there is no Ankama name to check it against. See InventoryQuantity for what the element actually carries. | never |
| 3 | quantity | int32 | How many units are in this stack. Range: 1 or more for a stack that exists | never |
| 4 | gid | int32 | The item template id: what kind of item this is. (item template id) Declared int64 in the beta build and int32 here; the value is the same id. Shared by every instance of that item. NOT a handle - see uid. | never |
| 5 | uid | int32 | The unique handle for this stack, and the value later requests address it by. (item instance id) Unique within one character's storages, not globally. This is what ObjectUidWithQuantity.uid wants. | never |
| 7 | effects | repeated ObjectEffect | The effects rolled onto this particular instance. Element type ObjectEffect, a oneof - branch on it. | never |