Selecting an item is not using it
Figure 31. The player selected bearing_oil, then received another bottle. The live inventory list updated to ×2.
Selecting Bearing oil writes bearing_oil to selected_item. It does not automatically equip it, switch the adventure cursor, combine it with another item or remove it from inventory. Add a separate Use, Inspect or Give Button with the game logic you want.
| Goal | Change the correct data |
|---|---|
| Give an item | Use Add Inventory with the inventory item ID and Count. |
| Remove an item | Use the inventory removal action. |
| Change a stack quantity | Use the inventory quantity action. |
| Only remove a row from a local list | List Box: Delete Item changes that widget’s view; it does not remove the carried item. |
The example’s Add one oil bottle Button uses Add Inventory, item bearing_oil, Count 1. Because the item definition is stackable, the list shows the new total. Test a nonstackable item separately rather than assuming it behaves like a stack.
A specific-character list refers to the character definition ID. Make sure you chose the intended owner when a party or NPC inventory looks empty.
