Prototype Harkonnen Nexus with standalone E3 factions
Verify and publish checkpoint container / container (push) Successful in 14m6s

This commit is contained in:
Quintine committed 2026-11-16 21:03:08 +11:00
1 parent 6a30fdf376
commit 007508185e
14 files changed
+647 -18

No files matched your search

+15 -4
View File
@@ -12968,7 +12968,14 @@ export function initializeHarkonnenNexusBetrayalGameForAudit(state: Game): Game
requireFreshBaseRuntime(state);
return initializeNexusGameForAudit(state);
}
/** Bare Advanced E3 retains its native profile after the reaction is stamped. */
function harkonnenE3NexusBetrayalProfile(g: Game): boolean {
return !!g.advanced && !!byFaction(g, 'harkonnen') && !g.homeworlds &&
!g.techTokens && !g.strongholdCards && !g.discoveryEnabled && !g.discoveries &&
!g.ecazTreachery && !g.leaderSkills && standaloneE3NexusProfile(g);
}
function harkonnenNexusBetrayalModeSupported(g: Game): boolean {
if (harkonnenE3NexusBetrayalProfile(g)) return true;
if (nexusCoreProfile(g)) return !!byFaction(g, 'harkonnen');
return typeof g.advanced === 'boolean' && !!g.nexusCards && g.expansions.length === 0 &&
g.players.length >= 2 && g.players.length <= 6 && !!byFaction(g,'harkonnen') &&
@@ -13086,6 +13093,9 @@ function harkonnenNexusBetrayalIntegrity(g: Game, mentatOpening = false): void {
function offerHarkonnenNexusBetrayal(g: Game, provider: string, response?: ResponseWindow): boolean {
if (!g.nexusHarkonnenBetrayalPreview || getPlayer(g,provider).faction !== 'harkonnen') return false;
const b = g.battle!;
// Occupy can add co-side voters that the current two-sided source cannot bind.
// Retain the original Traitor call until that declaration is supported.
if (b.ecazOccupy && harkonnenE3NexusBetrayalProfile(g)) return false;
const required = nexusRule(() => harkonnenBetrayalResponders(g.nexusCards!.cards!,g.players));
if (!required.length) return false;
requireRule(!b.nexusHarkonnenAllowance && (!response || response.kind === 'harkonnenTraitor'),
@@ -14408,7 +14418,8 @@ function initializeSetupGameForAudit(state: Game, homeworlds: boolean, nexus = f
g.spiceBankerIncomePreview = true;
g.spiceBankerIncome = bankerIncomeRule(() => createBankerIncomeState(bankerIncomeContext(g)));
}
if (nativeNexusReactions && nexusCoreProfile(g)) {
const nativeNexusCore = nexusCoreProfile(g);
if (nativeNexusReactions && (nativeNexusCore || harkonnenE3NexusBetrayalProfile(g))) {
requireRule(g.nexusIxianReplacementPreview === undefined &&
g.nexusIxianReplacementHistory === undefined && g.nexusIxianReplacementCursor === undefined &&
!g.pendingNexusIxianReplacement && !g.pendingNexusIxianSpecialPurchase &&
@@ -14422,13 +14433,13 @@ function initializeSetupGameForAudit(state: Game, homeworlds: boolean, nexus = f
requireRule(g.nexusIxianBetrayalPreview === undefined && g.nexusIxianBetrayalHistory === undefined &&
g.nexusIxianBetrayalCursor === undefined && !g.pendingNexusIxianBetrayal,
'Native Ixian Nexus reactions require original undealt effect state.');
if (!byFaction(g, 'ixians')) {
if (nativeNexusCore && !byFaction(g, 'ixians')) {
g.nexusIxianReplacementPreview = true;
g.pendingNexusIxianReplacement = null;
g.nexusIxianReplacementHistory = [];
g.nexusIxianReplacementCursor = initialIxianReplacementCursor();
}
if (byFaction(g, 'ixians')) {
if (nativeNexusCore && byFaction(g, 'ixians')) {
g.nexusIxianBetrayalPreview = true;
g.pendingNexusIxianBetrayal = null;
g.nexusIxianBetrayalHistory = [];
@@ -14442,7 +14453,7 @@ function initializeSetupGameForAudit(state: Game, homeworlds: boolean, nexus = f
g.pendingNexusHarkonnenReplacement = null;
g.nexusHarkonnenReplacementHistory = [];
}
if (byFaction(g, 'guild')) initializeGuildBetrayalState(g);
if (nativeNexusCore && byFaction(g, 'guild')) initializeGuildBetrayalState(g);
}
if (semuta) {
requireRule(factions && bareBasicSemutaProfile(g),
+1 -1
View File
@@ -360,7 +360,7 @@ function nativeBankNexusProfile(g: Game): boolean {
if (g.semutaPreview && !basicSemutaNexus || g.advancedPreview || g.kullPreview || g.nexusKullPreview ||
g.guildBetrayalPreview || g.richeseBetrayalPreview ||
g.nexusIxianReplacementPreview || g.nexusIxianBetrayalPreview ||
g.nexusHarkonnenBetrayalPreview) return false;
(g.nexusHarkonnenBetrayalPreview && !standaloneE3NexusProfile(g))) return false;
if (g.leaderSkills)
return pairedNexusLeaderSkillsProfile(g) || singleE1E2NexusLeaderSkillsProfile(g) ||
mixedE1E2NexusLeaderSkillsProfile(g) || standaloneE3NexusLeaderSkillsProfile(g) ||
+2 -1
View File
@@ -241,7 +241,8 @@ function revivalModeSupported(g: Game): boolean {
(singleE1E2NexusProfile(g) || pairedNexusModulesProfile(g) || mixedE1E2NexusProfile(g))) return true;
if (g.semutaPreview || g.advancedPreview || g.kullPreview || g.nexusKullPreview ||
g.guildBetrayalPreview || g.richeseBetrayalPreview || g.nexusIxianReplacementPreview ||
g.nexusIxianBetrayalPreview || g.nexusHarkonnenBetrayalPreview || g.ecazTreachery)
g.nexusIxianBetrayalPreview ||
(g.nexusHarkonnenBetrayalPreview && !standaloneE3NexusProfile(g)) || g.ecazTreachery)
return false;
if (g.leaderSkills)
return classicNexusLeaderSkillsProfile(g) || pairedNexusLeaderSkillsProfile(g) ||
+3 -1
View File
@@ -78,7 +78,9 @@ export function standaloneE3NexusProfile(game: FactionModuleProfile): boolean {
game.ecazTreachery || game.semutaPreview || game.advancedPreview ||
game.kullPreview || game.nexusKullPreview || game.guildBetrayalPreview ||
game.richeseBetrayalPreview || game.nexusIxianReplacementPreview ||
game.nexusIxianBetrayalPreview || game.nexusHarkonnenBetrayalPreview) return false;
game.nexusIxianBetrayalPreview || (game.nexusHarkonnenBetrayalPreview &&
!(game.advanced && !game.homeworlds && !game.techTokens && !game.strongholdCards &&
game.players.some(player => player.faction === 'harkonnen')))) return false;
let native: 'ecaz' | 'moritani' | null = null;
for (let i = 0; i < game.players.length; i++) {
const player = game.players[i];
+5 -4
View File
@@ -6257,11 +6257,12 @@ export const RULE_TOPICS: RuleTopic[] = [
title: 'Harkonnen Nexus Betrayal: cancel a declared traitor',
category: 'Advanced & expansions',
coverage: 'Partial',
developmentStage: 'Verified',
summary: 'Fresh supported classic starts cancel one original native Harkonnen traitor call, return that physical card immediately and give Harkonnen a private replacement during Mentat Pause.',
developmentStage: 'Prototyped',
summary: 'Fresh supported starts cancel one original native Harkonnen traitor call, return that physical card immediately and give Harkonnen a private replacement during Mentat Pause.',
searchText: 'Harkonnen Nexus Betrayal revealed declared traitor ally caller beneficiary shuffle replacement Mentat neutral acknowledgement',
steps: [
'Fresh supported Basic and Advanced Nexus core starts with selected faction decks initialize this reaction for native expansion leaders and the Ix Cheap Hero Traitor. Advanced CHOAM’s Auditor has its real Traitor identity. An owed replacement waits through Ix phase-opening acknowledgements before the original Mentat draw. Advanced Ecaz/Moritani roster initialization and wider combinations remain unfinished.',
'Fresh supported Basic and Advanced Nexus core starts with selected faction decks initialize this reaction for native expansion leaders and the Ix Cheap Hero Traitor. Advanced CHOAM’s Auditor has its real Traitor identity. An owed replacement waits through Ix phase-opening acknowledgements before the original Mentat draw. Fresh Advanced games with Harkonnen and one Ecaz or Moritani faction also support the reaction with Nexus alone; wider E3 combinations remain unfinished.',
'Ecaz Occupy battles retain the ordinary Traitor call without the Harkonnen Nexus reaction until coalition declarations are supported. Harkonnen replacement precedes Moritani assassination replacement when both are due; that ordering is provisional.',
'Original standalone preview requires native Harkonnen, classic2–6 Basic/Advanced, base33 and Nexus alone. Fresh classic Nexus core initializes the same effect with base33 or selected36, optional14, original Tech3+ and Advanced Strongholds2+, alongside actual Guild/Ixian reactions. Public selection binds the census; real held-card effects and cleanup stay native. No played game is reflagged; other native/module envelopes remain separate.',
'Nexus has no initial deal. An actual alliance-qualified closing Nexus must supply the unallied holder. An effect scenario needs at least three seats; two seats can continue ordinary play without inventing a card. Two simultaneous receivers need four actual seats.',
'The photographed publisher face cancels a revealed Harkonnen traitor, shuffles that exact card back immediately, and gives Harkonnen one replacement during Mentat Pause. It is not a draw-now exchange, whole-battle ban or refund of an already resolved outcome. Native Cunning and absent-Harkonnen Secret Ally remain separate effects.',
@@ -6282,7 +6283,7 @@ export const RULE_TOPICS: RuleTopic[] = [
{ area: 'Player controls', status: 'Partial', detail: 'Public declared-Traitor inspector, own eligible event-only Use/Pass/Nexus inspector, sole/multiple public ownership and every-seat independent autopilot are connected. Actual phone Use, wrong-face Pass, partial refresh and raw administrator owner agree.', evidence: ['components/nexus-harkonnen-betrayal.tsx', 'components/game-table.tsx', 'game/table-turn.ts', 'db/admin-directory.ts'] },
{ area: 'AI', status: 'Partial', detail: 'All four minimal policies consume canonical own-view choices and native pending priority with legal paced continuation; full strategy and calibration remain separate.', evidence: ['game/bot-nexus-harkonnen-betrayal.ts', 'game/bots.ts'] },
{ area: 'Documentation', status: 'Partial', detail: 'Printed immediate/delayed operations, personal/allied roles, inferred local counter/privacy convention, fresh natural card rights and unchanged outside-profile/module/public/deployment questions are explicit.', evidence: ['docs/NEXUS_HARKONNEN_RULES.md', 'docs/NEXUS_CARD_RUNTIME.md', 'docs/RULE_DECISIONS.md'] },
{area:'Verification',status:'Partial',detail:"Fresh classic core base33 or selected36 optional14 initializes the original actual-Harkonnen source without a card-variant dependency. Genuine base33 all14 Use reaches one real Mentat draw; earlier independent Harass, Pass and allied-counter cases remain. Ten combined consumer cases and four legal policies pass. Other modes, universal timing and deferred assurance remain open.",evidence:['tests/classic-nexus-core.test.ts','tests/fixture-classic-nexus-core.ts','game/faction-module-profile.ts','tests/classic-independent-nexus-reactions.test.ts','tests/fixture-classic-independent-nexus-reactions.ts','tests/fixture-nexus-harkonnen-betrayal.ts', 'tests/nexus-harkonnen-betrayal.test.ts', 'tests/nexus-harkonnen-betrayal-runtime.test.ts', 'tests/nexus-harkonnen-betrayal-controls.test.tsx', 'tests/bot-nexus-harkonnen-betrayal.test.ts', 'tests/nexus-harkonnen-betrayal-recovery.test.ts', 'tests/prototype-room.test.ts', 'tests/admin-directory.test.ts']},
{area:'Verification',status:'Partial',detail:"Fresh classic and selected-deck evidence remains. Standalone Advanced Ecaz and Moritani have staged native battle, control and delayed-replacement smoke; Occupy and simultaneous replacement composition remain open. Other modes, universal timing and deferred assurance remain open.",evidence:['tests/classic-nexus-core.test.ts','tests/fixture-classic-nexus-core.ts','game/faction-module-profile.ts','tests/classic-independent-nexus-reactions.test.ts','tests/fixture-classic-independent-nexus-reactions.ts','tests/fixture-nexus-harkonnen-betrayal.ts', 'tests/nexus-harkonnen-betrayal.test.ts', 'tests/nexus-harkonnen-betrayal-runtime.test.ts', 'tests/nexus-harkonnen-betrayal-controls.test.tsx', 'tests/bot-nexus-harkonnen-betrayal.test.ts', 'tests/nexus-harkonnen-e3-runtime.test.ts', 'tests/nexus-harkonnen-e3-controls.test.tsx', 'tests/nexus-harkonnen-e3-quote.test.ts', 'tests/nexus-harkonnen-betrayal-recovery.test.ts', 'tests/prototype-room.test.ts', 'tests/admin-directory.test.ts']},
],
},
{