feat: add active effects inspector to tile drawer

- Track active effects with human-readable labels in AbilitySystem
  (LabelFromReversal/LabelFromTick for stat mods, status flags, DOT/HOT)
- Add ActiveEffectDto to GameStateDto and GameStateDelta; delta now
  always includes the full effects list so clients are never stale
- Add ResolveLabelFromEffectJson fallback for effects stored before the
  Label field was introduced (old game sessions show correct labels)
- Client _append_active_effect_lines helper filters activeEffects by
  targetRef and appends formatted lines to the tile drawer for spirits,
  archspirits, spirit tokens, and ruins

Generated with [Claude Code](https://claude.ai/code)
via [Happy](https://happy.engineering)

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Happy <yesreply@happy.engineering>
This commit is contained in:
dingo
2026-04-14 11:52:37 -04:00
co-authored by Claude Happy
parent 144ad84cac
commit b4062d8179
8 changed files with 239 additions and 6 deletions
+5
View File
@@ -551,6 +551,11 @@ func _apply_delta(delta: Dictionary) -> void:
if meta.has("activePlayerAccountId") and meta["activePlayerAccountId"] != null: state["activePlayerAccountId"] = meta["activePlayerAccountId"]
if meta.has("turnNumber") and meta["turnNumber"] != null: state["turnNumber"] = int(meta["turnNumber"])
# 10. Active effects (full replacement when changed)
var active_effects = delta.get("activeEffects")
if active_effects is Array:
state["activeEffects"] = active_effects
_state_version = int(delta.get("stateVersion", _state_version))
if debug_output:
print("[Game] delta applied ver=", _state_version,