Unlock core units on respawn
This commit is contained in:
@@ -1697,6 +1697,7 @@ public class UnitTypes implements ContentList{
|
||||
engineOffset = 6f;
|
||||
hitSize = 8f;
|
||||
commandLimit = 3;
|
||||
alwaysUnlocked = true;
|
||||
|
||||
weapons.add(new Weapon("small-basic-weapon"){{
|
||||
reload = 17f;
|
||||
|
||||
@@ -6,6 +6,7 @@ import arc.graphics.g2d.*;
|
||||
import arc.math.*;
|
||||
import arc.math.geom.*;
|
||||
import arc.struct.*;
|
||||
import mindustry.*;
|
||||
import mindustry.annotations.Annotations.*;
|
||||
import mindustry.content.*;
|
||||
import mindustry.core.*;
|
||||
@@ -71,6 +72,10 @@ public class CoreBlock extends StorageBlock{
|
||||
unit.spawnedByCore(true);
|
||||
unit.add();
|
||||
}
|
||||
|
||||
if(state.isCampaign() && player == Vars.player){
|
||||
block.unitType.unlock();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user