Implemented new spawnlist

This commit is contained in:
Anuken
2018-06-27 13:54:50 -04:00
parent 5cefecced8
commit 6364b9e06b
17 changed files with 694 additions and 440 deletions
@@ -179,6 +179,8 @@ public class Puddle extends BaseEntity implements SaveTrait, Poolable, DrawTrait
//effects-only code
if(amount >= maxLiquid/2f && updateTime <= 0f){
Units.getNearby(rect.setSize(Mathf.clamp(amount/(maxLiquid/1.5f))*10f).setCenter(x, y), unit -> {
if(unit.isFlying()) return;
unit.getHitbox(rect2);
if(!rect.overlaps(rect2)) return;
@@ -155,7 +155,7 @@ public abstract class GroundUnit extends BaseUnit {
@Override
public void readSave(DataInput stream) throws IOException{
weapon = Upgrade.getByID(weapon.id);
weapon = Upgrade.getByID(stream.readByte());
super.readSave(stream);
}
@@ -229,7 +229,7 @@ public abstract class GroundUnit extends BaseUnit {
state.set(resupply);
}else if(target != null){
if(core != null){
if(dst > inventory.getAmmo().getRange() * 0.7f){
if(dst > inventory.getAmmo().getRange() * 0.5f){
moveToCore();
}