Equip Hero
Equip Hero¶
Assigns a piece of equipment from the inventory to a specific equipment slot on a hero.
Properties¶
System¶
| Name | Explanation | Type |
|---|---|---|
| Equipment | The equipment to assign to the hero. | Equipment |
| Equipment Slot | The equipment slot on the hero where the equipment will be placed. | Equipment Slot |
| Hero | The hero who will receive the equipment. | Character |
| Ignore Constraints | When enabled, equipment restrictions such as class or level requirements are bypassed. | Toggle |
| Require Unequipped | When enabled, the equipment must not already be equipped by another party member. | Toggle |
| Result | The switch to store whether the equip operation succeeded. | Switch or Value |
| Store Results | When enabled, the success or failure of the equip operation is stored in a switch. | Toggle |
Examples¶
Equip Hero 0 with Equipment 0 in Equipment Slot 0¶
This assigns equipment at index 0 to the first equipment slot on hero 0.
{"Data":{"Equipment":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"EquipmentSlot":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"Hero":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"IgnoreConstraints":0,"IsConstrainedToUnequipped":0,"Result":{"IsGlobalSwitch":true,"IsLocalSwitch":false,"IsValue":true,"Value":false,"SwitchIndex":0,"Metadata":null},"StoreResults":0,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Inventory.EquipItemCommand"}
Equip Hero 1 Ignoring Constraints and Store the Result¶
This equips hero 1 with equipment 2 in equipment slot 0, bypassing restrictions, and stores whether the operation succeeded in Global Switch 0.
{"Data":{"Equipment":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"2","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"EquipmentSlot":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"Hero":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"IgnoreConstraints":1,"IsConstrainedToUnequipped":0,"Result":{"IsGlobalSwitch":true,"IsLocalSwitch":false,"IsValue":false,"Value":false,"SwitchIndex":0,"Metadata":null},"StoreResults":1,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Inventory.EquipItemCommand"}
Equip Hero 0 Requiring the Equipment to Be Unequipped¶
This equips hero 0 with equipment 1 in equipment slot 0, but only if the equipment is not already worn by another party member.
{"Data":{"Equipment":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"EquipmentSlot":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"Hero":{"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsInstanceIndex":0,"IsReferenceIndex":1,"IsUniqueID":0,"Metadata":null},"IgnoreConstraints":0,"IsConstrainedToUnequipped":1,"Result":{"IsGlobalSwitch":true,"IsLocalSwitch":false,"IsValue":true,"Value":false,"SwitchIndex":0,"Metadata":null},"StoreResults":0,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Inventory.EquipItemCommand"}