refactor(battle-node): replace int IsSelf with CardOwner enum on mined-token tuples
MineAddOps/MineChoicePicks/MineCopyTokens return types and all extraction casts changed from int to CardOwner. The 4 routing comparisons in BattleSessionState now read isSelf == CardOwner.Self instead of isSelf == 1. No wire or behavioral change — CardOwner was already in use on the wire-facing side (OppoTargetEntry, UnapprovedCardEntry); this extends it to the internal mining path so the bare-int transpose risk is gone. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -414,7 +414,7 @@ public class CaptureConformanceTests
|
||||
.MineCopyTokens(orderList, new Dictionary<int, long>(), otherMap)
|
||||
.ToList();
|
||||
|
||||
Assert.That(mined, Is.EquivalentTo(new[] { (49, 123_456_789L, 0) }));
|
||||
Assert.That(mined, Is.EquivalentTo(new[] { (49, 123_456_789L, CardOwner.Opponent) }));
|
||||
}
|
||||
|
||||
[Test]
|
||||
|
||||
Reference in New Issue
Block a user