Skip to content

CombatLogManager ​

Inherits: RefCounted

CombatLogManager now receives comprehensive reports from CombatSystem

Variables ​

Stringcurrent_time""
Arraylog_batch[]
Array[Timer]active_timers[]
Timerbatch_timer
Timertime_update_timer
intcurrent_log_levelLogLevel.NORMAL
boollogging_enabledtrue

Methods ​

voidset_batch_interval( interval: float )
voidupdate_time()

Signals ​

batch_log( log_entries: Array ) ​

Emitted when a batch log is ready

damage_done_details( entity: Entity, amount: int ) ​

Emits damage done to the details manager

healing_taken_details( entity: Entity, amount: int ) ​

Emits healing taken to the details manager

Enumerations ​

enum LogLevel ​

Log levels for controlling verbosity

  • CRITICAL = 0
  • NORMAL = 1

enum LogCategory ​

Log categories with associated colors

  • DAMAGE = 0
  • HEALING = 1
  • STATUS = 2

Constants ​

  • const CATEGORY_COLORS = { - Color mapping for log categories
  • const MAX_BATCH_SIZE = 50 - Maximum number of entries in a single batch

Variable descriptions ​

String current_time = "" ​

Current time string in format "HH:MM:SS"

Array log_batch = [] ​

Array to store log entries before batching

Array[Timer] active_timers = [] ​

========== CHRONO MANAGER INTEGRATION ========== Track active timers so we can return them properly

Timer batch_timer ​

Store timer references for easy access

Timer time_update_timer ​

The timer that updates the time shown in the log.

int current_log_level = LogLevel.NORMAL ​

Current log level (default to NORMAL)

bool logging_enabled = true ​

Whether logging is enabled

Method descriptions ​

void set_batch_interval( interval: float ) ​

Sets how many seconds the log waits to send its lines together.

void update_time() ​

Updates the clock shown in the log lines.