Crash fix / tilesSecond speed unit
This commit is contained in:
@@ -1978,25 +1978,25 @@ public class Blocks implements ContentList{
|
||||
}};
|
||||
|
||||
repairPoint = new RepairPoint("repair-point"){{
|
||||
requirements(Category.units, with(Items.lead, 25, Items.copper, 25, Items.silicon, 20));
|
||||
repairSpeed = 0.5f;
|
||||
repairRadius = 65f;
|
||||
requirements(Category.units, with(Items.lead, 30, Items.copper, 30, Items.silicon, 20));
|
||||
repairSpeed = 0.45f;
|
||||
repairRadius = 60f;
|
||||
beamWidth = 0.73f;
|
||||
powerUse = 1f;
|
||||
pulseRadius = 5f;
|
||||
}};
|
||||
|
||||
repairTurret = new RepairPoint("repair-turret"){{
|
||||
requirements(Category.units, with(Items.silicon, 90, Items.thorium, 80, Items.plastanium, 80));
|
||||
requirements(Category.units, with(Items.silicon, 90, Items.thorium, 80, Items.plastanium, 60));
|
||||
size = 2;
|
||||
length = 6f;
|
||||
repairSpeed = 3f;
|
||||
repairRadius = 140f;
|
||||
repairRadius = 145f;
|
||||
powerUse = 5f;
|
||||
beamWidth = 1.1f;
|
||||
pulseRadius = 6.1f;
|
||||
coolantUse = 0.16f;
|
||||
coolantMultiplier = 1.5f;
|
||||
coolantMultiplier = 1.6f;
|
||||
acceptCoolant = true;
|
||||
}};
|
||||
|
||||
|
||||
@@ -255,7 +255,7 @@ public class UnitType extends UnlockableContent{
|
||||
|
||||
stats.add(Stat.health, health);
|
||||
stats.add(Stat.armor, armor);
|
||||
stats.add(Stat.speed, speed);
|
||||
stats.add(Stat.speed, speed * 60f / tilesize, StatUnit.tilesSecond);
|
||||
stats.add(Stat.size, hitSize / tilesize, StatUnit.blocksSquared);
|
||||
stats.add(Stat.itemCapacity, itemCapacity);
|
||||
stats.add(Stat.range, (int)(maxRange / tilesize), StatUnit.blocks);
|
||||
|
||||
@@ -75,7 +75,7 @@ public class PayloadConveyor extends Block{
|
||||
|
||||
@Override
|
||||
public boolean canControlSelect(Player player){
|
||||
return this.item == null && !player.unit().spawnedByCore && player.unit().hitSize / tilesize <= payloadLimit && player.tileOn().build == this;
|
||||
return this.item == null && !player.unit().spawnedByCore && player.unit().hitSize / tilesize <= payloadLimit && player.tileOn() != null && player.tileOn().build == this;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -10,6 +10,7 @@ import java.util.*;
|
||||
public enum StatUnit{
|
||||
blocks,
|
||||
blocksSquared,
|
||||
tilesSecond,
|
||||
powerSecond,
|
||||
liquidSecond,
|
||||
itemsSecond,
|
||||
|
||||
Reference in New Issue
Block a user