From 6ee58f4191c5b7acca5427b2fbcdc8482411b47f Mon Sep 17 00:00:00 2001 From: Scott Anderson <662325+scottanderson@users.noreply.github.com> Date: Thu, 3 Apr 2025 01:23:42 -0400 Subject: [PATCH] cost --- src/core/execution/FakeHumanExecution.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/core/execution/FakeHumanExecution.ts b/src/core/execution/FakeHumanExecution.ts index e286a0991..36082ebae 100644 --- a/src/core/execution/FakeHumanExecution.ts +++ b/src/core/execution/FakeHumanExecution.ts @@ -298,8 +298,7 @@ export class FakeHumanExecution implements Execution { const silos = this.player.units(UnitType.MissileSilo); if ( silos.length == 0 || - this.player.gold() < - this.mg.config().unitInfo(UnitType.AtomBomb).cost(this.player) || + this.player.gold() < this.cost(UnitType.AtomBomb) || this.player.isOnSameTeam(other) ) { return; @@ -462,9 +461,7 @@ export class FakeHumanExecution implements Execution { if (units.length >= maxNum) { return; } - if ( - this.player.gold() < this.mg.config().unitInfo(type).cost(this.player) - ) { + if (this.player.gold() < this.cost(type)) { return; } const tile = this.randTerritoryTile(this.player);