EquipItem
Equip an item from a member's item list (zero time).
Full documentation: EquipItem. Wire type: equip_item.
Legal session modes: exploring, town
JSON Schema
{
"description": "Equip an item from a member's item list (zero time).\n\nLegal in town and while exploring. Class armour and weapon policies validate\nbefore anything changes. `item_id` is the magic item's instance id for a magic\nitem, or the catalog id for a mundane one, which has no per-instance id. A\nmundane id is either a shipped one (from\n`load_equipment`, see the equipment id\nindex) or one the adventure bundles, which no index\ndocuments.\n\nModes:\n `town`, `exploring`\n\nRejections:\n - `session.command.wrong_mode` - an encounter or battle is underway, or the\n game is over.\n - `session.command.unknown_member` - `character_id` names no party member.\n - `session.command.member_incapacitated` - the member cannot act.\n - `exploration.item.not_carried` - nothing by that id in the item list.\n - `items.equip.armour_forbidden`, `items.equip.armour_not_allowed`,\n `items.equip.shield_forbidden`, `items.equip.weapon_not_allowed`,\n `items.equip.weapon_forbidden` - the class policy forbids it.\n - `items.equip.two_handed_with_shield` - a two-handed weapon and a shield\n cannot pair.\n - `items.equip.not_equippable` - potions, scrolls, ammunition, and plain\n gear without a combat use do not equip.\n - `items.equip.not_usable` - the magic device is not usable by this class.\n - `items.ring.hands_full` - two rings are already worn.\n\nEvents:\n Usually none. Equipping a worn magic item can attach its effects\n (`EffectAttachedEvent`). A cursed\n ring identifies and reveals at wearing\n (`ItemIdentifiedEvent`,\n `CurseRevealedEvent`).",
"properties": {
"command_type": {
"const": "equip_item",
"default": "equip_item",
"title": "Command Type",
"type": "string",
"description": "The wire discriminator. Each subclass fixes it to its own snake_case literal, like\n`\"move_party\"` or `\"open_door\"`, so you never set it yourself: constructing the subclass\ndoes. It's what `parse_command` and the\n`AnyCommand` union read to rebuild the right class\nfrom a serialized mapping, and it stays the same across releases."
},
"source": {
"anyOf": [
{
"minLength": 1,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Source",
"description": "An annotation naming the authored object (a trigger or quest id) or the game\nsystem on whose behalf the command was issued. Execution never reads it: a stamped\ncommand does exactly what the same command unstamped does. It is logged and replayed\nwith the command, so the log alone answers \"why did this happen\". Absent is `None`,\nand the empty string is not a value."
},
"character_id": {
"title": "Character Id",
"type": "string",
"description": "The member doing the equipping, by\n`MemberView.id`. Their class decides what they may wear\nand wield, and the class policy is checked before anything moves."
},
"item_id": {
"title": "Item Id",
"type": "string",
"description": "What to equip, which has to be in this member's item list already. A magic item is named by\nits per-instance id, because each one is a distinct object. A mundane item is named by its\ncatalog id, because mundane items stack and have no per-instance id. Both are visible in\n`MemberView.inventory`."
}
},
"required": [
"character_id",
"item_id"
],
"title": "EquipItem",
"type": "object"
}