Skip to content

ObjectDestructibleDamagedTrigger ​

Inherits: EventTrigger < Resource

Triggers when a specific destructible object takes damage

Properties ​

intinteractable_unique_id0
Condition.CheckLogicdamage_check_logicCondition.CheckLogic.GREATER_EQUAL
inttarget_damage0

Variables ​

InteractableObjecttarget_objectnull

Methods ​

Stringget_display_name()
Stringget_function_description()
voidsetup()
voidcleanup()
voidfind_target_object()
boolmeets_damage_condition( damage_taken: int )
boolis_triggered( event_data: Dictionary )
Stringgenerate_objective_description()

Property descriptions ​

int interactable_unique_id = 0 ​

The object ID to track

Condition.CheckLogic damage_check_logic = Condition.CheckLogic.GREATER_EQUAL ​

Comparison logic for damage check

int target_damage = 0 ​

Damage amount to compare against

Variable descriptions ​

InteractableObject target_object = null ​

Reference to the target destructible object

Method descriptions ​

String get_display_name() ​

Return the display name for this trigger

String get_function_description() ​

Return the function description with parameter placeholders

void setup() ​

Set up any listeners or connections needed by this trigger

void cleanup() ​

Clean up any listeners or connections

void find_target_object() ​

Try to find the target object in the world

bool meets_damage_condition( damage_taken: int ) ​

Check if the current damage meets the comparison logic

bool is_triggered( event_data: Dictionary ) ​

Check if this trigger is currently active

String generate_objective_description() ​

Generate quest objective description