Support Harkonnen special Karama truth commitments
Verify and publish checkpoint container / container (push) Successful in 10m17s

This commit is contained in:
Quintine committed 2026-10-29 18:08:04 +11:00
1 parent 15a4f3038a
commit b448144c52
15 files changed
+449 -35

No files matched your search

+8 -1
View File
@@ -7,7 +7,7 @@ import { RevivalExpressionPromiseError, type RevivalExpressionReturn } from './r
import { parseBattleActionClaim, type MixedBattleActionClaim } from './mixed-battle-question';
import { PlanClaimError } from './battle-promises';
import { PRINTED_CARD_EFFECTS, type PrintedCardEffect } from './printed-card-play';
import { WINDOW_CARD_EFFECTS, type WindowCardEffect } from './window-card-play';
import { WINDOW_CARD_EFFECTS, parseKaramaHarkonnenSpecialSource, type WindowCardEffect } from './window-card-play';
import { StormDialQuestionError, parseStormDialClaim, parseStormDialSource, stormDialMatches, type StormDialClaim } from './storm-dial-question';
import { nativePromiseScopeSupported, type NativePromiseScope } from './native-promise-scope';
import { BattlePowerQuestionError, battlePowerMatches, battlePowerOf, parseBattlePowerClaim,
@@ -167,6 +167,8 @@ export function parseTurnActionLeaf(value: unknown): TurnActionLeaf {
if (value.kind === 'windowCardPlay') {
check(keys(value, 'effect,kind,source') && windowEffect(value.effect) && identifier(value.source),
'Choose one original phase-opening, Storm, first-reveal, fresh-blow, ordinary-lot or shipment-price printed-card play after this answer.');
if (value.effect === 'karamaHarkonnenSpecial') check(!!parseKaramaHarkonnenSpecialSource(value.source),
'Retain the original Harkonnen special Karama Bidding window.');
return { kind: 'windowCardPlay', effect: value.effect, source: value.source };
}
if (value.kind === 'battlePower') {
@@ -363,6 +365,11 @@ function readPromise(promise: TurnActionPromise): CompiledMixedAction<TurnAction
for (const effect of cardEffects) check(!!promise.cardPlays?.[effect], 'Retain the original future interval for each printed-card play clause.');
for (const effect of windowSources.keys()) check(!!promise.windowCards?.[effect],
'Retain the original native window for every printed-card window clause, including folded ones.');
for (const source of windowSources.get('karamaHarkonnenSpecial') ?? []) {
const binding = parseKaramaHarkonnenSpecialSource(source);
check(binding && binding.turn === promise.turn && binding.owner === promise.player,
'Retain the respondent’s original Harkonnen special Karama Bidding window.');
}
if ('windowCards' in promise) {
check(object(promise.windowCards) && keys(promise.windowCards, [...windowSources.keys()].sort().join(',')),
'Retain exactly the original named window-card effects.');