This commit is contained in:
VariableVince
2026-02-14 01:10:07 +01:00
parent 916da39001
commit 0fc57131d5
2 changed files with 3 additions and 2 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
import { NukeMagnitude } from "../configuration/Config";
import { Game, Player } from "../game/Game";
import { Game, Player, UnitType } from "../game/Game";
import { euclDistFN, GameMap, TileRef } from "../game/GameMap";
import { GameView } from "../game/GameView";
@@ -119,7 +119,7 @@ export function listNukeBreakAlliance(
// Also check if any allied structures would be destroyed
game
.nearbyUnits(targetTile, magnitude.outer, this.game.getStructureTypes())
.nearbyUnits(targetTile, magnitude.outer, [...game.getStructureTypes()])
.forEach(({ unit }) =>
playersToBreakAllianceWith.add(unit.owner().smallID()),
);
+1
View File
@@ -780,6 +780,7 @@ export interface Game extends GameMap {
): Array<{ unit: Unit; distSquared: number }>;
getStructureTypes(): readonly UnitType[];
isStructureType(type: UnitType): boolean;
getPlayerBuildableUnitTypes(): readonly UnitType[];
addExecution(...exec: Execution[]): void;
displayMessage(