unreal.BTDecorator_BlueprintBase

class unreal.BTDecorator_BlueprintBase(outer=None, name='None')

Bases: unreal.BTDecorator

Base class for blueprint based decorator nodes. Do NOT use it for creating native c++ classes!

Unlike task and services, decorator have two execution chains:

ExecutionStart-ExecutionFinish and ObserverActivated-ObserverDeactivated

which makes automatic latent action cleanup impossible. Keep in mind, that you HAVE TO verify is given chain is still active after resuming from any latent action (like Delay, Timelines, etc).

Helper functions: - IsDecoratorExecutionActive (true after ExecutionStart, until ExecutionFinish) - IsDecoratorObserverActive (true after ObserverActivated, until ObserverDeactivated)

C++ Source:

  • Module: AIModule

  • File: BTDecorator_BlueprintBase.h

Editor Properties: (see get_editor_property/set_editor_property)

  • check_condition_only_black_board_changes (bool): [Read-Write] Applies only if Decorator has any FBlackboardKeySelector property and if decorator is

    set to abort BT flow. Is set to true ReceiveConditionCheck will be called only on changes

    to observed BB keys. If false or no BB keys observed ReceiveConditionCheck will be called every tick

  • custom_description (str): [Read-Write] Custom Description

  • flow_abort_mode (BTFlowAbortMode): [Read-Write] flow controller settings

  • inverse_condition (bool): [Read-Write] if set, condition check result will be inversed

  • node_name (str): [Read-Write] node name

  • show_property_details (bool): [Read-Write] show detailed information about properties

property custom_description

[Read-Write] Custom Description

Type

(str)

is_decorator_execution_active()bool

check if decorator is part of currently active branch

Returns

Return type

bool

is_decorator_observer_active()bool

check if decorator’s observer is currently active

Returns

Return type

bool

perform_condition_check(owner_actor)bool

called when testing if underlying node can be executed, must call FinishConditionCheck that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters

owner_actor (Actor) –

Returns

Return type

bool

perform_condition_check_ai(owner_controller, controlled_pawn)bool

Alternative AI version of ReceiveConditionCheck ReceiveConditionCheck for more details: that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
Returns

Return type

bool

receive_execution_finish(owner_actor, node_result)None

called when execution of underlying node is finished that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
receive_execution_finish_ai(owner_controller, controlled_pawn, node_result)None

Alternative AI version of ReceiveExecutionFinish ReceiveExecutionFinish for more details: that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
receive_execution_start(owner_actor)None

called on execution of underlying node that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters

owner_actor (Actor) –

receive_execution_start_ai(owner_controller, controlled_pawn)None

Alternative AI version of ReceiveExecutionStart ReceiveExecutionStart for more details: that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
receive_observer_activated(owner_actor)None

called when observer is activated (flow controller) that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters

owner_actor (Actor) –

receive_observer_activated_ai(owner_controller, controlled_pawn)None

Alternative AI version of ReceiveObserverActivated ReceiveObserverActivated for more details: that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
receive_observer_deactivated(owner_actor)None

called when observer is deactivated (flow controller) that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters

owner_actor (Actor) –

receive_observer_deactivated_ai(owner_controller, controlled_pawn)None

Alternative AI version of ReceiveObserverDeactivated ReceiveObserverDeactivated for more details: that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
receive_tick(owner_actor, delta_seconds)None

tick function that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters
  • owner_actor (Actor) –

  • delta_seconds (float) –

receive_tick_ai(owner_controller, controlled_pawn, delta_seconds)None

Alternative AI version of ReceiveTick ReceiveTick for more details: that if both generic and AI event versions are implemented only the more suitable one will be called, meaning the AI version if called for AI, generic one otherwise:

Parameters