mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-08-06 10:54:21 +00:00
delete warship when player is afk
This commit is contained in:
@@ -55,6 +55,11 @@ export class WarshipExecution implements Execution {
|
|||||||
this.warship.delete();
|
this.warship.delete();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (this.warship.owner().isDisconnected()) {
|
||||||
|
this.warship.delete();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const hasPort = this.warship.owner().unitCount(UnitType.Port) > 0;
|
const hasPort = this.warship.owner().unitCount(UnitType.Port) > 0;
|
||||||
if (hasPort) {
|
if (hasPort) {
|
||||||
this.warship.modifyHealth(1);
|
this.warship.modifyHealth(1);
|
||||||
|
|||||||
Reference in New Issue
Block a user