refactor(runtime): own combat and magic intent

Move attack build/repeat state, combat-mode policy, authoritative auto-target transitions, and spell-cast intent beneath RuntimeActionState. Keep App as the input, world-query, DAT-policy, transport, and presentation adapter while preserving retail request and busy ordering. Add direct/graphical parity, reset, failure, and instance-isolation coverage.

Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
Erik 2026-07-26 11:56:40 +02:00
parent 81b31857c6
commit 20df9d155d
49 changed files with 1949 additions and 634 deletions

View file

@ -2,6 +2,7 @@ using AcDream.App.Combat;
using AcDream.App.UI;
using AcDream.App.UI.Layout;
using AcDream.Core.Combat;
using AcDream.Runtime.Gameplay;
using AcDream.UI.Abstractions.Panels.Settings;
namespace AcDream.App.Tests.UI.Layout;
@ -33,7 +34,7 @@ public sealed class CombatUiControllerTests
Assert.False(high.Selected);
Assert.True(medium.Selected);
Assert.False(low.Selected);
Assert.Equal(CombatAttackController.InitialDesiredPower, power.ScalarPosition);
Assert.Equal(RuntimeCombatAttackState.InitialDesiredPower, power.ScalarPosition);
}
[Fact]
@ -123,7 +124,7 @@ public sealed class CombatUiControllerTests
"Speed", "Power", "Repeat Attacks", "Auto Target", "Keep in View",
"High", "Medium", "Low");
private static CombatAttackController CreateAttacks(
private static RuntimeCombatAttackState CreateAttacks(
CombatState combat,
Func<double> now,
List<(AttackHeight Height, float Power)> sent)