add @commanded for units (#3870)

This commit is contained in:
DeltaNedas 2020-12-17 00:42:48 +00:00 committed by GitHub
parent b12cac7b30
commit 8bc349b68c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View file

@ -133,6 +133,7 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
case mineY -> mining() ? mineTile.y : -1;
case flag -> flag;
case controlled -> controller instanceof LogicAI || controller instanceof Player ? 1 : 0;
case commanded -> controller instanceof FormationAI ? 1 : 0;
case payloadCount -> self() instanceof Payloadc pay ? pay.payloads().size : 0;
default -> 0;
};

View file

@ -34,6 +34,7 @@ public enum LAccess{
type,
flag,
controlled,
commanded,
name,
config,
payloadCount,