Script:inventory open: Difference between revisions
(Created page with "{{ScriptCommandPage |description=open the inventory in the HUD |context=any |intro=This command does not have any effect if the calling entity did not have an inventory created using {{Command|inventory create}}. The inventory will automatically close once the player is 350 units away from the inventory owner unless the player is has the {{Spell|telekinesis}} spell active in which case the maximum distance is 900 units. The player can also close the inv...") |
mNo edit summary |
||
Line 3: | Line 3: | ||
|context=any | |context=any | ||
|intro=This command does not have any effect if the calling entity did not have an inventory created using {{Command|inventory create}}. | |intro=This command does not have any effect if the calling entity did not have an inventory created using {{Command|inventory create}}. | ||
Entities set to act as a shop using {{Command|setshop}} will have their inventory automatically sorted when opened with matching items being [[Script:playerstacksize|combined into stacks if possible]]. The player will also be restricted in how they can interact with the inventory. | |||
The inventory will automatically close once the player is 350 units away from the inventory owner unless the player is has the {{Spell|telekinesis}} spell active in which case the maximum distance is 900 units. The player can also close the inventory from the [[Gameplay#HUD|HUD]] or scripts can use {{Command|inventory close}} to manually close the inventory again. | The inventory will automatically close once the player is 350 units away from the inventory owner unless the player is has the {{Spell|telekinesis}} spell active in which case the maximum distance is 900 units. The player can also close the inventory from the [[Gameplay#HUD|HUD]] or scripts can use {{Command|inventory close}} to manually close the inventory again. | ||
}} | }} |
Revision as of 11:50, 26 June 2022
The inventory open
script command is used to open the inventory in the HUD for an entity. This command does not have any effect if the calling entity did not have an inventory created using inventory create
.
Entities set to act as a shop using setshop
will have their inventory automatically sorted when opened with matching items being combined into stacks if possible. The player will also be restricted in how they can interact with the inventory.
The inventory will automatically close once the player is 350 units away from the inventory owner unless the player is has the Telekinesis () spell active in which case the maximum distance is 900 units. The player can also close the inventory from the HUD or scripts can use inventory close
to manually close the inventory again.
Usage
inventory open
Context: Any Entity