Difference between revisions of "Osiris/Shared/DB HasStoryEvent"

From Divinity Engine Wiki
Jump to: navigation, search
(DB_HasStoryEvent)
 
m (clarify that the flag gets removed when the item is removed)
Line 2: Line 2:
 
* '''DB_HasStoryEvent'''(''(ITEMGUID)'''''_Item''',''(STRING)'''''_HasItemEvent''')
 
* '''DB_HasStoryEvent'''(''(ITEMGUID)'''''_Item''',''(STRING)'''''_HasItemEvent''')
 
===== Description =====
 
===== Description =====
Defining this database will result in the character/object flag '''_HasItemEvent''' to be set on a character as soon as '''_Item''' is added to its inventory/
+
Defining this database will result in the character/object flag '''_HasItemEvent''' to be set on a character while '''_Item''' is in its inventory.
 
===== Notes =====
 
===== Notes =====
 
* This is useful to check in a dialog whether a character actually still has an item before you give it to a player. Note that you should perform the check and give action on the same dialog node, as otherwise the item could still be pick-pocketed in between the check and the transfer.
 
* This is useful to check in a dialog whether a character actually still has an item before you give it to a player. Note that you should perform the check and give action on the same dialog node, as otherwise the item could still be pick-pocketed in between the check and the transfer.

Revision as of 13:24, 8 October 2017

Full Definition(s)
  • DB_HasStoryEvent((ITEMGUID)_Item,(STRING)_HasItemEvent)
Description

Defining this database will result in the character/object flag _HasItemEvent to be set on a character while _Item is in its inventory.

Notes
  • This is useful to check in a dialog whether a character actually still has an item before you give it to a player. Note that you should perform the check and give action on the same dialog node, as otherwise the item could still be pick-pocketed in between the check and the transfer.
See Also