Connect the Basic Ecaz new-ally Duke loan

This commit is contained in:
Quintine committed 2026-10-08 08:30:38 +11:00
1 parent c28e24b5fa
commit 2d0f20b69c
11 files changed
+106 -25

No files matched your search

+1 -1
View File
@@ -23,7 +23,7 @@ import { TERRITORIES } from '@/game/board';
import { faction } from '@/game/catalog';
export const AMBASSADOR_COVERAGE =
'Development coverage: Ambassador placement, Ecaz’s direct Duke acquisition and consensual alliance, Emperor, Atreides, Harkonnen, CHOAM, Ixian, Richese, Fremen, Guild and Tleilaxu entry effects are supported, plus Bene Gesserit copies. The Tleilaxu effect offers physical force returns or a first-death own-leader revival. Ordinary allowance and income accounting, repeat-death and shared-leader cases remain for refinement. Duke loan choices and some competing arrival reactions remain unfinished; full Ecaz starts remain disabled.';
'Development coverage: Ambassador placement, Ecaz’s direct Duke acquisition and consensual alliance, Emperor, Atreides, Harkonnen, CHOAM, Ixian, Richese, Fremen, Guild and Tleilaxu entry effects are supported, plus Bene Gesserit copies. The Tleilaxu effect offers physical force returns or a first-death own-leader revival. Basic Ecaz can optionally lend Duke to a newly accepted ally, with provisional one-battle/turn-end tenure. Ordinary revival accounting, repeat-death/shared-leader cases, Advanced loans and competing arrival reactions remain for refinement; full Ecaz starts remain disabled.';
function tokenLocation(token: AmbassadorToken) {
if (token.zone === 'placed')
return `Placed in ${TERRITORIES.find((t) => t.id === token.location)?.name ?? 'a stronghold'}`;
+18 -4
View File
@@ -32,7 +32,7 @@ export function EcazEntry({
!entry ||
game.decision?.kind !== 'ecazAmbassador' ||
game.decision.player !== game.me ||
!['offer', 'allianceReply', 'copy', 'cards', 'move', 'ship', 'revival'].includes(
!['offer', 'allianceReply', 'loan', 'copy', 'cards', 'move', 'ship', 'revival'].includes(
entry.stage,
)
)
@@ -141,7 +141,8 @@ export function EcazEntry({
<p className="m-0 text-sm leading-6">
Both factions must be unallied. The entrant chooses whether to
accept. The triggered Ambassador returns to supply even if the
offer is refused. Duke loans remain unfinished.
offer is refused. In Basic, an accepted alliance can be followed
by an optional Duke loan when the disc is available.
</p>
</>
) : (
@@ -194,8 +195,8 @@ export function EcazEntry({
<p className="m-0 text-sm leading-6">
{game.players.find((p) => p.id === entry.owner)?.name} offers you an
alliance. Accepting activates both factions’ alliance abilities
immediately. Duke Vidal is not included in this offer. Your
remaining actions resume after your reply.
immediately. In Basic, Ecaz can then optionally lend an available
Duke Vidal. Your remaining actions resume after those choices.
</p>
<Button
className={buttonClass}
@@ -213,6 +214,19 @@ export function EcazEntry({
Refuse alliance
</Button>
</>
) : entry.stage === 'loan' ? (
<>
<p className="m-0 text-sm leading-6">
Lend Duke Vidal to your new ally for this turn, or continue without
lending him. Basic prototype: one battle; an unused living Duke is
set aside at turn end. Return and capture interactions remain provisional.
</p>
<Button className={buttonClass} disabled={busy || !!entry.dukeLoan?.blocked}
onClick={() => send({ loan: true })}>Lend Duke Vidal to the new ally</Button>
{entry.dukeLoan?.blocked && <p>{entry.dukeLoan.blocked}</p>}
<Button variant="outline" className={buttonClass} disabled={busy}
onClick={() => send({ loan: false })}>Continue without lending Duke</Button>
</>
) : entry.stage === 'copy' ? (
<>
<p className="m-0 text-sm leading-6">