Mud tweaks / Unit count tweaks

This commit is contained in:
Anuken
2020-09-19 16:04:50 -04:00
parent 84b1c0348d
commit eb8658e140
3 changed files with 17 additions and 7 deletions

View File

@@ -37,7 +37,7 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
private UnitController controller;
private UnitType type;
boolean spawnedByCore, deactivated;
boolean spawnedByCore, deactivated; //TODO remove deactivation boolean
transient Seq<Ability> abilities = new Seq<>(0);
@@ -204,7 +204,6 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
@Override
public void add(){
teamIndex.updateCount(team, type, 1);
//check if over unit cap
if(count() > cap() && !spawnedByCore){
@@ -213,8 +212,6 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
if(!dead){
Call.unitCapDeath(self());
}
}else{
teamIndex.updateActiveCount(team, type, 1);
}
}