Skip to content

EntitiesInRangeHealthCondition ​

Inherits: EntityCondition < Condition < Resource

Checks if minimum number of entities in range are above/below health threshold

Properties ​

floatrange10.0
intmin_count1
floathealth_threshold_percent50.0
EntityTypeentity_typeEntityType.NPCS
boolhealth_abovefalse

Methods ​

Stringget_entity_function_description()
boolevaluate_entity( entity: Entity )
Stringget_entity_description()

Enumerations ​

enum EntityType ​

The options of entity type: npcs, players, any.

  • NPCS = 0 - Only NPCs
  • PLAYERS = 1 - Only players
  • ANY = 2 - Any entity type

Property descriptions ​

float range = 10.0 ​

Maximum range to search for entities

int min_count = 1 ​

Minimum count required

float health_threshold_percent = 50.0 ​

Health threshold percentage (0-100)

EntityType entity_type = EntityType.NPCS ​

Type of entities to search for

bool health_above = false ​

If true, checks for health ABOVE threshold; if false, checks BELOW

Method descriptions ​

String get_entity_function_description() ​

The sentence the editor shows for the condition, with {placeholders} for its values.

bool evaluate_entity( entity: Entity ) ​

Is the condition met for this entity?

String get_entity_description() ​

A short text about what the condition checks on the entity.