Choose your operating system:
Windows
macOS
Linux
| UGameplayBehavior::Trigger()
|
Module |
|
Header |
/Engine/Plugins/Experimental/GameplayBehaviors/Source/GameplayBehaviorsModule/Public/AI/GameplayBehavior_BehaviorTree.h |
Include |
#include "AI/GameplayBehavior_BehaviorTree.h" |
Source |
/Engine/Plugins/Experimental/GameplayBehaviors/Source/GameplayBehaviorsModule/Private/AI/GameplayBehavior_BehaviorTree.cpp |
virtual bool Trigger
(
AActor & Avatar,
const UGameplayBehaviorConfig * Config,
AActor * SmartObjectOwner
)
Default implementation will trigger the appropriate Blueprint event based on their presence in the script and in the following priority:
OnTriggeredCharacter if used and Avatar is a Character
OnTriggeredPawn if used and Avatar is a Pawn
OnTriggered if used
Subclasses can override this method to control the whole flow
True if behavior was triggered and caller should register to OnBehaviorFinished to be notified on completion
Parameter |
Description |
---|---|
Avatar |
The actor on which the behavior should be execute |
Config |
Configuration parameters of the behavior |
SmartObjectOwner |
The actor associated to the smart object |