From 7e6e8c2d120cd74bf6cb74b1475783de54a7d65f Mon Sep 17 00:00:00 2001 From: Quintine <15965533+Quintine@users.noreply.github.com> Date: Thu, 29 Oct 2026 05:52:58 +1100 Subject: [PATCH] Allow Advanced Auditor inspection choice --- components/choam-auditor.tsx | 48 +++++---- docs/CHOAM_AUDITOR.md | 12 +++ docs/CURRENT_STATUS.md | 9 ++ docs/RULE_DECISIONS.md | 8 ++ game/choam-auditor.ts | 16 ++- game/engine.ts | 25 +++-- game/reference.ts | 6 +- tests/choam-auditor-choice.test.ts | 161 +++++++++++++++++++++++++++++ tests/choam-auditor.test.ts | 38 +++++++ 9 files changed, 292 insertions(+), 31 deletions(-) create mode 100644 tests/choam-auditor-choice.test.ts diff --git a/components/choam-auditor.tsx b/components/choam-auditor.tsx index 48a97f05..fbe6613e 100644 --- a/components/choam-auditor.tsx +++ b/components/choam-auditor.tsx @@ -25,7 +25,7 @@ export function AuditorDecision({

{payment ? `Pay ${audit.count} spice to CHOAM to cancel the entire inspection, or allow it without payment.` - : `Your Auditor ${audit.survived ? 'survived' : 'died'}. You may inspect ${audit.count} random card${audit.count === 1 ? '' : 's'} from ${opponent?.name ?? 'your opponent'}’s hand. Cards used in this battle are excluded.`} + : `Your Auditor ${audit.survived ? 'survived' : 'died'}. You may inspect up to ${audit.count} random card${audit.count === 1 ? '' : 's'} from ${opponent?.name ?? 'your opponent'}’s hand. Cards used in this battle are excluded.`}

{!payment && (

@@ -34,25 +34,33 @@ export function AuditorDecision({

)}
- + {payment ? ( + + ) : ( + [1, 2].filter((count) => count <= audit.count).map((count) => ( + + )) + )}