Treat a generic battle-power decline as passing borrowed Nexus Voice
This commit is contained in:
1 parent
5961c75a29
commit
2dbbe8859e
4 files changed
+12
No files matched your search
@@ -33830,6 +33830,11 @@ function applyActionInner(
|
||||
}
|
||||
if (t === 'declineBattlePower') {
|
||||
const b = g.battle;
|
||||
if (b?.preparation?.kind === 'nexusVoice' && b.preparation.owner === id && b.nexusBorrowedVoice) {
|
||||
// A generic decline is the same as continuing without the borrowed command.
|
||||
playNexusBorrowedVoice(g, p, { type: 'nexusBorrowedVoice', event: b.nexusBorrowedVoice.event, use: false });
|
||||
return g;
|
||||
}
|
||||
requireRule(
|
||||
b?.preparation?.owner === id && !['nexusVoice', 'prescienceAnswer', 'nexusPrescienceAnswer'].includes(b.preparation.kind),
|
||||
'You do not own this battle power decision.',
|
||||
|
||||
@@ -19,6 +19,8 @@ export function suboidFixture(advanced = true, atreides = false) {
|
||||
g = applyAction(g, 'p', { type: 'chooseBattle', territory: 'pasty_mesa', target: 'q' });
|
||||
for (const id of ['p', 'q']) if (g.battle!.preLeader && !g.battle!.preLeader.closed)
|
||||
g = applyAction(g, id, { type: 'battlePreparationReady', event: g.battle!.event });
|
||||
while (g.battle?.preparation?.kind === 'nexusVoice')
|
||||
g = applyAction(g, g.battle.preparation.owner, { type: 'declineBattlePower' });
|
||||
validateNexusCards(g.nexusCards!.cards!, g.players);
|
||||
return g;
|
||||
}
|
||||
|
||||
@@ -126,6 +126,9 @@ export function nexusInspectionFixture(
|
||||
type: 'battlePreparationReady',
|
||||
event: g.battle!.event,
|
||||
});
|
||||
// Pass the absent-BG borrowed Voice opportunity that precedes native Prescience.
|
||||
while (g.battle?.preparation?.kind === 'nexusVoice')
|
||||
g = applyAction(g, g.battle.preparation.owner, { type: 'declineBattlePower' });
|
||||
return g;
|
||||
}
|
||||
export function inspectionHold(g: Game, id: string, kind: Card['kind']): Card {
|
||||
|
||||
@@ -80,6 +80,8 @@ export function nexusSardaukarFixture(
|
||||
type: 'battlePreparationReady',
|
||||
event: g.battle!.event,
|
||||
});
|
||||
while (g.battle?.preparation?.kind === 'nexusVoice')
|
||||
g = applyAction(g, g.battle.preparation.owner, { type: 'declineBattlePower' });
|
||||
nexusSardaukarInventory(g);
|
||||
return g;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user