Credit Banker for paid placement and disposal invoices
This commit is contained in:
1 parent
ff2826b980
commit
c56d9c85ef
13 files changed
+673
-11
No files matched your search
@@ -26591,6 +26591,9 @@ function decideBiddingEnd(g: Game, p: Player, action: Action) {
|
||||
p.spice -= quote.cost;
|
||||
const entries = quote.cards.map((card) => ({ card: discard(g, p, card.id),
|
||||
discardedBy: p.id, publicFace: false }));
|
||||
awardBankerIncome(g, bankerIncomePayment(g, 'kaitain-disposal', [
|
||||
{ payer: p.id, amount: quote.cost, recipient: 'bank' },
|
||||
]));
|
||||
log(g, `${p.name} paid ${quote.cost} spice to the bank and discarded ${entries.length} Treachery Card${entries.length === 1 ? '' : 's'} through high-population Kaitain. No new auction begins.`,
|
||||
{ faction: p.faction, name: 'Kaitain disposal' });
|
||||
stageTreacheryDiscard(g, 'kaitain', entries, { kind: 'kaitainDiscard',
|
||||
@@ -33982,6 +33985,9 @@ function finishResponse(g: Game, canceled: boolean, settlement?: BureaucratSettl
|
||||
);
|
||||
owner.spice -= quote.cost;
|
||||
g.ecazAmbassadors = quote.state;
|
||||
awardBankerIncome(g, bankerIncomePayment(g, 'ambassador-placement', [
|
||||
{ payer: owner.id, amount: quote.cost, recipient: 'bank' },
|
||||
]));
|
||||
g.pendingEcazPlacement = null;
|
||||
log(
|
||||
g,
|
||||
|
||||
+3
-2
@@ -6259,6 +6259,7 @@ export const RULE_TOPICS: RuleTopic[] = [
|
||||
'The printed normal band is mandatory once per phase: when another player makes a payment of at least four spice to the Spice Bank, gain one spice and place it in front of the shield. It is an additional bank grant, not a reduction of the payer’s payment or another player’s income.',
|
||||
'Only an actual completed positive bank payment qualifies. A payment to a player, zero/free/waived cost, self-payment, invalid declaration or unfinished possible payment supplies no income. Several smaller payments do not combine to reach four.',
|
||||
'Use the original actual bank portion after recipient and counter settlement, not a quoted fee or guessed wallet change. Paid auctions, funded shipments, paid revival and eligible resolved battle support keep their native continuation once. Canceled Emperor, Guild or Tleilaxu revival income can leave a real bank payment. Tleilaxu self-revival pays the Bank; other-player revival normally pays Tleilaxu. Its separate free-revival bank award is not payer debit: three paid plus that one reward never becomes four paid to the Bank. A stopped shipment supplies no payment.',
|
||||
'Accepted Ecaz Ambassador placements and high-Kaitain selected-card disposals also use their actual Bank invoices. A fourth placement costs four; declaring it earns nothing until allowed and paid. An atomic two-card disposal costs four, while separate one-card payments of two never combine. Both keep the physical once-per-phase cap and original Mentat collection; deferred spice cannot fund another placement or disposal.',
|
||||
'Actual payer contribution legs stay distinct. Two different players paying two each do not become one player paying four. The same payer’s Bureaucrat diversion and other final Bank portions of one original invoice do combine; unrelated invoices never do. Banker’s separate one-to-three battle payment does not combine with two support to manufacture a qualifying payment. Source conventions and user rulings are explicit, not a publisher split-payment example.',
|
||||
'A new grant requires an actual available living native trainer. A captive grants no normal income. Hidden unselected skills do not supply their normal band; in the trainer’s own battle, its actual selected surviving leader supplies the appropriate eligibility after reveal/resolution, not private pre-reveal timing.',
|
||||
'One physical Banker card has one use per turn and phase. Repeated payments, refresh, death, return or same-phase reassignment cannot reset that use; the next phase or turn permits a new grant.',
|
||||
@@ -6270,11 +6271,11 @@ export const RULE_TOPICS: RuleTopic[] = [
|
||||
],
|
||||
related: ['leader-skills', 'battle', 'bidding', 'revival', 'implementation-checklist'],
|
||||
checklist: [
|
||||
{ area: 'Implementation', status: 'Implemented', detail: 'Fresh ordinary all-fourteen Skills initializes the existing deferred-income ledger automatically; original supported module and native overlay setup stays authoritative. Actual final Bank payer legs, one physical Banker phase grant and original-owner Mentat collection remain. Existing games are not retrofitted; the separate initializer/profile and opt-ins are removed.', evidence: ['game/engine.ts', 'game/spice-banker-income.ts', 'game/leader-skill-profile.ts', 'game/homeworld-payment-income.ts', 'tools/prototype-room.ts'] },
|
||||
{ area: 'Implementation', status: 'Implemented', detail: 'Fresh ordinary all-fourteen Skills initializes the existing deferred-income ledger automatically; original supported module and native overlay setup stays authoritative. Accepted Ecaz placements and atomic Kaitain disposals join actual final Bank payer legs; one physical Banker phase grant and original-owner Mentat collection remain. Existing games are not retrofitted; the separate initializer/profile and opt-ins are removed.', evidence: ['game/engine.ts', 'game/spice-banker-income.ts', 'game/leader-skill-profile.ts', 'game/homeworld-payment-income.ts', 'tools/prototype-room.ts'] },
|
||||
{ area: 'Player controls', status: 'Implemented', detail: 'A full-width read-only public front-shield notice explains unavailable spice and automatic collection; genuine original payment and final Collection controls work at 390px through refresh. No new income action or confirmation.', evidence: ['components/spice-banker-income.tsx', 'components/game-table.tsx'] },
|
||||
{ area: 'AI', status: 'Partial', detail: 'All four minimal legal policies preserve identical available-budget actions with deferred income present or absent. Original wallets exclude front-shield currency; strategy/calibration remain deferred.', evidence: ['game/bots.ts', 'game/spice-banker.ts'] },
|
||||
{ area: 'Documentation', status: 'Partial', detail: 'Printed threshold/phase/collection, original payment separation, provisional earned custody and per-payer composition are explicit. The user-ruled same-payer diversion, primary-first private attribution and whole-invoice low rounding are documented without universal publisher claims.', evidence: ['docs/LEADER_SKILLS_RULES.md', 'docs/SPICE_BANKER_RUNTIME.md', 'docs/HOMEWORLD_PAYMENT_INCOME_RULES.md', 'docs/RULE_DECISIONS.md'] },
|
||||
{ area: 'Verification', status: 'Partial', detail: 'Ordinary native World and Semuta programmes cover actual payment, physical trainer, deferred spendability, threshold/recipient exclusions, overlay continuation and once-only Mentat collection. Legacy played saves are not retrofitted. Two actual phone journeys and four legal policies exercise these contexts; this is not exhaustive combination, recovery, strategy or deployed acceptance.', evidence: ['tests/fixture-banker-world-default.ts', 'tests/banker-world-default.test.ts', 'tests/fixture-banker-overlay-default.ts', 'tests/banker-overlay-default.test.ts', 'tests/homeworld-banker-income.test.ts', 'tests/homeworld-banker-transport.test.ts', 'tests/homeworld-bank-payment.test.ts', 'tests/spice-banker-income.test.ts', 'tests/native-banker-income.test.ts', 'tests/prototype-room.test.ts', 'docs/SPICE_BANKER_RUNTIME.md'] },
|
||||
{ area: 'Verification', status: 'Partial', detail: 'Ordinary native World and Semuta programmes cover actual payment, physical trainer, deferred spendability, threshold/recipient exclusions, overlay continuation and once-only Mentat collection. Legacy played saves are not retrofitted. Two actual phone journeys and four legal policies exercise these contexts; this is not exhaustive combination, recovery, strategy or deployed acceptance.', evidence: ['tests/fixture-banker-world-default.ts', 'tests/banker-world-default.test.ts', 'tests/fixture-banker-overlay-default.ts', 'tests/banker-overlay-default.test.ts', 'tests/homeworld-banker-income.test.ts', 'tests/homeworld-banker-transport.test.ts', 'tests/homeworld-bank-payment.test.ts', 'tests/spice-banker-income.test.ts', 'tests/fixture-banker-native-payments.ts', 'tests/banker-native-payments-runtime.test.ts', 'tests/native-banker-income.test.ts', 'tests/prototype-room.test.ts', 'docs/SPICE_BANKER_RUNTIME.md'] },
|
||||
],
|
||||
},
|
||||
{
|
||||
|
||||
@@ -8,6 +8,8 @@ export type BankerIncomeSourceKind =
|
||||
| 'leader-revival'
|
||||
| 'kh-revival'
|
||||
| 'emperor-extra-revival'
|
||||
| 'ambassador-placement'
|
||||
| 'kaitain-disposal'
|
||||
| 'battle-support';
|
||||
export type BankerIncomeContext = {
|
||||
turn: number;
|
||||
@@ -66,7 +68,8 @@ export class BankerIncomeError extends Error {
|
||||
const LIMIT = 50_000;
|
||||
const sourcePhases: Record<BankerIncomeSourceKind, number> = {
|
||||
auction: 3, shipment: 5, 'force-revival': 4, 'leader-revival': 4,
|
||||
'kh-revival': 4, 'emperor-extra-revival': 4, 'battle-support': 6,
|
||||
'kh-revival': 4, 'emperor-extra-revival': 4, 'ambassador-placement': 4,
|
||||
'kaitain-disposal': 3, 'battle-support': 6,
|
||||
};
|
||||
const text = (value: unknown): value is string =>
|
||||
typeof value === 'string' && value.length > 0 && value.length <= 512 && value.trim() === value;
|
||||
|
||||
Reference in new issue
Block a user