Skip to content

EqualizeDamageAreaEffect ​

Inherits: EqualizeAreaEffect < MinimumApplicationAreaEffect < AreaEffect < CollisionEffect < CompositeEffect < Effect < DatabaseResource < Resource

EqualizeDamageAreaEffect distributes damage among all targets in area.

Properties ​

intdamage_type0
floatbase_damage1.0
floatweapon_damage_percentage0.0
boolcan_be_avoidedtrue

Methods ​

voidapply_equalization_to_targets( effect_instance: EffectInstance, targets: Array[Variant] )
Dictionaryget_damage_distribution_preview( effect_instance: EffectInstance )
Dictionaryget_detailed_damage_preview( effect_instance: EffectInstance )
boolhas_meaningful_damage_targets( effect_instance: EffectInstance, min_damage: float = 1.0 )
Array[Variant]get_targets_that_would_take_damage( effect_instance: EffectInstance )
Stringget_effect_description()
Stringget_mode_description()
Stringget_editor_description()

Property descriptions ​

Damage Settings

int damage_type = 0 ​

Damage Type for the effect

float base_damage = 1.0 ​

The base damage that should be dealt

float weapon_damage_percentage = 0.0 ​

Percentage of weapon damage that should be added to damage done

bool can_be_avoided = true ​

If the effect can be avoided

Method descriptions ​

void apply_equalization_to_targets( effect_instance: EffectInstance, targets: Array[Variant] ) ​

Implement the specific damage distribution logic using CombatSystem

Dictionary get_damage_distribution_preview( effect_instance: EffectInstance ) ​

Get damage distribution preview for UI/tooltips

Dictionary get_detailed_damage_preview( effect_instance: EffectInstance ) ​

Get detailed damage breakdown for each target

bool has_meaningful_damage_targets( effect_instance: EffectInstance, min_damage: float = 1.0 ) ​

Check if any targets would actually take meaningful damage

Array[Variant] get_targets_that_would_take_damage( effect_instance: EffectInstance ) ​

Get only targets that would take damage (useful for EQUALIZE_CURRENT mode)

String get_effect_description() ​

The text of the effect for tooltips, with its values filled in.

String get_mode_description() ​

Get mode-specific description

String get_editor_description() ​

A short text for the effect editor that says what the effect does.