Preserve Emperor gift opportunity before bot Extortion
Verify and publish checkpoint container / container (push) Successful in 10m54s
Verify and publish checkpoint container / container (push) Successful in 10m54s
This commit is contained in:
1 parent
a6be17fc5d
commit
7c1f4b4e09
13 files changed
+370
-13
No files matched your search
+7
-6
@@ -1250,12 +1250,6 @@ function policyActions(g: GameView): Action[] {
|
||||
? [{ type: 'victoryContinuation', event: g.victoryContinuation.event, mode: 'finish' }]
|
||||
: [];
|
||||
if (g.homeworldTupileBlocked) return [];
|
||||
if (g.saphoStationPriority) {
|
||||
const own = g.players.find(player => player.id === g.me), priority = g.saphoStationPriority;
|
||||
return (own?.bot || own?.autopilot) && g.status === 'playing' && priority.canPass &&
|
||||
!g.roomControl?.paused && !g.roomControl?.closed && !g.automaticContinuationPending
|
||||
? [{type:'saphoStationPass', event:priority.event}] : [];
|
||||
}
|
||||
const dukeGrant = g.homeworldEcazDuke;
|
||||
if (dukeGrant && dukeGrant.occupier === me.id && !dukeGrant.blocked && dukeGrant.event && dukeGrant.recipients.length)
|
||||
return [{ type: 'homeworldDuke', event: dukeGrant.event, recipient: dukeGrant.recipients[0].id }];
|
||||
@@ -4377,6 +4371,13 @@ function botAdvisorMatchingAllowed(g:GameView,action:Action) {
|
||||
} catch(error) { if(error instanceof AdvisorMatchingError) return false; throw error; }
|
||||
}
|
||||
export function botActions(g: GameView): Action[] {
|
||||
if (g.saphoStationPriority) {
|
||||
const own = g.players.find(player => player.id === g.me), priority = g.saphoStationPriority;
|
||||
return (own?.bot || own?.autopilot) && g.status === 'playing' && priority.canPass &&
|
||||
!g.roomControl?.paused && !g.roomControl?.closed && !g.automaticContinuationPending
|
||||
? [{type:'saphoStationPass', event:priority.event}] : [];
|
||||
}
|
||||
if (g.emperorExtortionPriority) return [];
|
||||
if (g.emperorAuctionGiftPending && !g.response) {
|
||||
const me = g.players.find(player => player.id === g.me);
|
||||
return (me?.bot || me?.autopilot) && g.status === 'playing' &&
|
||||
|
||||
Reference in new issue
Block a user