mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-22 01:57:44 +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();
|
||||
return;
|
||||
}
|
||||
if (this.warship.owner().isDisconnected()) {
|
||||
this.warship.delete();
|
||||
return;
|
||||
}
|
||||
|
||||
const hasPort = this.warship.owner().unitCount(UnitType.Port) > 0;
|
||||
if (hasPort) {
|
||||
this.warship.modifyHealth(1);
|
||||
|
||||
Reference in New Issue
Block a user