bufix: ports execution still active after port dies

This commit is contained in:
Evan
2024-11-29 17:10:28 -08:00
parent 4899196613
commit 7a961c68b4
3 changed files with 9 additions and 6 deletions
+4
View File
@@ -49,6 +49,10 @@ export class PortExecution implements Execution {
}
this.port = player.buildUnit(UnitType.Port, 0, spawns[0])
}
if (!this.port.isActive()) {
this.active = false
return
}
const alliedPorts = this.player().alliances().map(a => a.other(this.player())).flatMap(p => p.units(UnitType.Port))