This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
dragengine:modules:dragonscript:behavior_playerinteractprompt [2025/05/07 14:28] – dragonlord | dragengine:modules:dragonscript:behavior_playerinteractprompt [2025/05/07 14:31] (current) – dragonlord | ||
---|---|---|---|
Line 98: | Line 98: | ||
Accept interact prompt to be shown. If all listeners return true the prompt is accepted otherwise rejected. | Accept interact prompt to be shown. If all listeners return true the prompt is accepted otherwise rejected. | ||
+ | |||
+ | ====== Behavior Tree Actions ====== | ||
+ | |||
+ | This behavior adds these behavior tree actions if behavior tree is present. | ||
+ | |||
+ | ===== playerInteractPrompt.set ===== | ||
+ | |||
+ | Set one or more player interact prompt parameters. | ||
+ | |||
+ | ^Parameter^Value^Description^ | ||
+ | |enabled|'' | ||
+ | |||
+ | This is an example of using this action: | ||
+ | <code xml> | ||
+ | <action name=' | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== playerInteractPrompt.check ===== | ||
+ | |||
+ | Check one or more player interact prompt parameters. Action succeeds if all parameter value matches their respective player interact prompt parameter otherwise action fails. This action is typically used as first action in a sequence to run the sequence only if a player interact prompt parameter matches (or not). | ||
+ | |||
+ | ^Parameter^Value^Description^ | ||
+ | |enabled|'' | ||
+ | |wait| |If present action returns BTResult.running instead of BTResult.failed to wait until the checks are all fulfilled| | ||
+ | |||
+ | This is an example of using this action: | ||
+ | <code xml> | ||
+ | < | ||
+ | <action name=' | ||
+ | < | ||
+ | </ | ||
+ | <!-- actions here run only if player interact prompt is enabled --> | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ====== Behavior Tree Conditions ====== | ||
+ | |||
+ | This behavior adds these behavior tree conditions if behavior tree is present. | ||
+ | |||
+ | ===== playerInteractPrompt.check ===== | ||
+ | |||
+ | Check one or more player interact prompt parameters. Conditions returns true if all parameter value match their respective player interact prompt parameter. This condition is typically used to run an action or sequence of actions as long as player interact prompt conditions are true. | ||
+ | |||
+ | ^Parameter^Value^Description^ | ||
+ | |playerInteractPrompt.enabled|'' | ||
+ | |||
+ | This is an example of using this condition: | ||
+ | <code xml> | ||
+ | <action name=' | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ====== State Machine Actions ====== | ||
+ | |||
+ | Same as [[# | ||
+ | |||
+ | ====== State Machine Conditions ====== | ||
+ | |||
+ | Same as [[# | ||
+ | |||
+ | ====== State Machine Events ====== | ||
+ | |||
+ | This behavior send no events to state machine. | ||
====== Required Behaviors ====== | ====== Required Behaviors ====== |