Harder default waves

This commit is contained in:
Anuken
2019-05-04 17:14:47 -04:00
parent 8d6afbd80d
commit f137c11c6c
5 changed files with 8 additions and 12 deletions
@@ -19,7 +19,7 @@ public class UnitDrops{
TileEntity core = unit.getClosestEnemyCore();
if(core == null){
if(core == null || core.dst(unit) > Vars.mineTransferRange){
return;
}
@@ -37,8 +37,9 @@ public class UnitDrops{
if(Mathf.chance(0.03)){
int amount = Mathf.random(20, 40);
amount = core.tile.block().acceptStack(item, amount, core.tile, null);
if(amount > 0)
if(amount > 0){
Call.transferItemTo(item, amount, unit.x + Mathf.range(2f), unit.y + Mathf.range(2f), core.tile);
}
}
}
}