Skip to main content

Item removal targets

ScriptDeleteTarget · signed byte, first operand of Delete items

Scripts · Script instructions

This byte says which items the instruction removes: the item in hand, every item of a block, or the items of one type in a block. Any byte that is not one of the two special values is used as the item type.1

The range of valid item types is not established.

typedef enum ScriptDeleteTarget {
SCRIPT_DELETE_HELD_ITEM = 0xff, /* Remove the item held or selected. */
SCRIPT_DELETE_ALL_IN_BLOCK = 0xfe /* Remove every item from the block that follows. */
} ScriptDeleteTarget;

SCRIPT_DELETE_ALL_IN_BLOCK is followed by a little-endian block index. With any other byte, the same block word follows and the byte is the ItemType to remove. See scripted item removal.

Sources​

Locations refer to the game executable reference.

Footnotes​

  1. Delete items handler, remove the selected inventory item and delete block items by type. Comparative source: oeob_deleteItem in REF-SCUMM-003. ↩