mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-07-30 05:49:40 +00:00
validate all intent input
This commit is contained in:
@@ -43,6 +43,11 @@ export class WarshipExecution implements Execution {
|
||||
) {}
|
||||
|
||||
init(mg: Game, ticks: number): void {
|
||||
if (!mg.hasPlayer(this.playerID)) {
|
||||
console.log(`WarshipExecution: player ${this.playerID} not found`);
|
||||
this.active = false;
|
||||
return;
|
||||
}
|
||||
this.pathfinder = PathFinder.Mini(mg, 5000, false);
|
||||
this._owner = mg.player(this.playerID);
|
||||
this.mg = mg;
|
||||
|
||||
Reference in New Issue
Block a user