# Gameplay TODO ## Aura transition walkthrough scenario (movement) Goal scenario: "A spirit moves on the battlefield and another spirit enters its aura range." ### Current flow in engine 1. `GameEngine.MoveUnit(...)` validates movement/path/MP. 2. Unit position is updated on board. 3. `AbilitySystem.EvaluateAuraTransitions(state, movingUnitId, from, to)` runs. 4. System checks both: - stationary aura units vs moving unit transition - moving unit's own aura vs stationary units 5. If range crossing occurs: - outside -> inside => `EnterAuraRange` trigger fires - inside -> outside => `LeaveAuraRange` trigger fires 6. Triggered abilities are evaluated via `FireTrigger(...)` and matching triggered actions execute. ### Test case outline - Place Aura Spirit A (with AuraRange 1..1 and an `OnEnterAuraRange` trigger). - Place Spirit B outside A's range. - Move B one tile so Manhattan distance to A becomes 1. - Expected: - `EnterAuraRange` trigger emitted with `SourceId=A`, `TargetId=B`. - Any matching triggered actions on A resolve. ### Notes - Aura enter/leave also has dedicated helpers for summon/death transitions: - `EvaluateAurasOnEnter(...)` - `EvaluateAurasOnLeave(...)`