User Tools

Site Tools


dragengine:modules:dragonscript:behavior_stashable

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
dragengine:modules:dragonscript:behavior_stashable [2025/05/11 13:29] – [stashable.set] dragonlorddragengine:modules:dragonscript:behavior_stashable [2025/05/13 14:10] (current) dragonlord
Line 74: Line 74:
 |remove|empty string, ''dispose''|Remove stashable from inventory if located in one. If value is ''dispose'' disposes of element (even if not in an inventory) and returns BTResult.running to stop the behavior tree.| |remove|empty string, ''dispose''|Remove stashable from inventory if located in one. If value is ''dispose'' disposes of element (even if not in an inventory) and returns BTResult.running to stop the behavior tree.|
 |interactElement.assign|string|Assign inventory element to [[behavior_interactelement|ECBehaviorInteractElement]] with identifier matching value string. Action fails if not stashed or interact element behavior is absent| |interactElement.assign|string|Assign inventory element to [[behavior_interactelement|ECBehaviorInteractElement]] with identifier matching value string. Action fails if not stashed or interact element behavior is absent|
 +|interact|string|Interact with inventory. If element is absent action fails. Runs interaction with name value. If interaction with name value is absent fails action. If interaction returns false fails action. Otherwise action succeeds.|
 +|interact.parameters|string|Optional parameters to use with ''interaction''.|
  
 This is an example of using this action: This is an example of using this action:
Line 88: Line 90:
 ^Parameter^Value^Description^ ^Parameter^Value^Description^
 |stashed|''true'', ''false''|Stashable is located in an inventory| |stashed|''true'', ''false''|Stashable is located in an inventory|
 +|interact.name|string|Name of interaction|
 +|interact.has|''true'', ''false''|Has inventory and interaction with name ''interaction.name'' is present|
 +|interact.query|''true'', ''false''|Interact with inventory and test result. Condition is true if inventory is present, interaction with name ''interaction.name'' is present and interaction returns true. It is recommended to use here only interactions without side effects (hence query interactions).|
 +|interact.parameters|string|Optional parameters to use with ''interaction.query''.|
 |wait| |If present action returns BTResult.running instead of BTResult.failed to wait until the checks are all fulfilled| |wait| |If present action returns BTResult.running instead of BTResult.failed to wait until the checks are all fulfilled|
  
Line 110: Line 116:
 ^Parameter^Value^Description^ ^Parameter^Value^Description^
 |stashable.stashed|''true'', ''false''|Stashable is located in an inventory| |stashable.stashed|''true'', ''false''|Stashable is located in an inventory|
 +|stashable.interact.name|string|Name of interaction|
 +|stashable.interact.has|''true'', ''false''|Has inventory and interaction with name ''interaction.name'' is present|
 +|stashable.interact.query|''true'', ''false''|Interact with inventory and test result. Condition is true if inventory is present, interaction with name ''interaction.name'' is present and interaction returns true. It is recommended to use here only interactions without side effects (hence query interactions).|
 +|stashable.interact.parameters|string|Optional parameters to use with ''interaction.query''.|
  
 This is an example of using this condition: This is an example of using this condition:
dragengine/modules/dragonscript/behavior_stashable.1746970159.txt.gz · Last modified: 2025/05/11 13:29 by dragonlord