AI tweaks / Control tweaks / Plastanium conveyor tweaks / Unit factories
This commit is contained in:
@@ -91,7 +91,7 @@ public class OverdriveProjector extends Block{
|
||||
float realBoost = (speedBoost + phaseHeat * speedBoostPhase) * efficiency();
|
||||
|
||||
charge = 0f;
|
||||
indexer.eachBlock(this, realRange, other -> other.timeScale() < realBoost, other -> other.applyBoost(realBoost, reload + 1f));
|
||||
indexer.eachBlock(this, realRange, other -> true, other -> other.applyBoost(realBoost, reload + 1f));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ public class StackConveyor extends Block implements Autotiler{
|
||||
update = true;
|
||||
group = BlockGroup.transportation;
|
||||
hasItems = true;
|
||||
itemCapacity = 8;
|
||||
itemCapacity = 10;
|
||||
conveyorPlacement = true;
|
||||
|
||||
idleSound = Sounds.conveyor;
|
||||
@@ -166,7 +166,7 @@ public class StackConveyor extends Block implements Autotiler{
|
||||
@Override
|
||||
public void updateTile(){
|
||||
// reel in crater
|
||||
if(cooldown > 0f) cooldown = Mathf.clamp(cooldown - speed, 0f, recharge);
|
||||
if(cooldown > 0f) cooldown = Mathf.clamp(cooldown - speed * edelta(), 0f, recharge);
|
||||
|
||||
if(link == -1){
|
||||
return;
|
||||
@@ -207,11 +207,6 @@ public class StackConveyor extends Block implements Autotiler{
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaximumAccepted(Item item){
|
||||
return Mathf.round(super.getMaximumAccepted(item) * timeScale); // increased item capacity while boosted
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean shouldIdleSound(){
|
||||
return false; // has no moving parts;
|
||||
|
||||
@@ -23,7 +23,7 @@ import mindustry.world.meta.*;
|
||||
import static mindustry.Vars.*;
|
||||
|
||||
public class UnitFactory extends Block{
|
||||
public float launchVelocity = 0f;
|
||||
public float launchVelocity = 5f;
|
||||
public TextureRegion topRegion;
|
||||
public int[] capacities;
|
||||
|
||||
@@ -123,9 +123,11 @@ public class UnitFactory extends Block{
|
||||
if(!net.client() && currentPlan != -1){
|
||||
UnitPlan plan = plans[currentPlan];
|
||||
Unitc unit = plan.unit.create(team);
|
||||
unit.set(x + Mathf.range(4), y + Mathf.range(4));
|
||||
unit.set(x, y );
|
||||
unit.add();
|
||||
unit.vel().y = launchVelocity;
|
||||
unit.rotation(90);
|
||||
unit.vel().y = launchVelocity + Mathf.range(1f);
|
||||
unit.vel().x = Mathf.range(1f);
|
||||
Events.fire(new UnitCreateEvent(unit));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user