mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-03-06 07:30:35 +07:00
Fixed #7296
This commit is contained in:
parent
11d3b1d973
commit
0f831d598d
@ -270,7 +270,7 @@ public class PowerGraph{
|
||||
if(build.power.graph != this || !build.power.init){
|
||||
//any old graph that is added here MUST be invalid, remove it
|
||||
if(build.power.graph != null && build.power.graph != this){
|
||||
if( build.power.graph.entity != null) build.power.graph.entity.remove();
|
||||
if(build.power.graph.entity != null) build.power.graph.entity.remove();
|
||||
}
|
||||
|
||||
build.power.graph = this;
|
||||
|
@ -70,7 +70,7 @@ public class VariableReactor extends PowerGenerator{
|
||||
public void updateTile(){
|
||||
heat = calculateHeat(sideHeat);
|
||||
|
||||
productionEfficiency = Mathf.clamp(heat / maxHeat);
|
||||
productionEfficiency = Mathf.clamp(heat / maxHeat) * efficiency;
|
||||
warmup = Mathf.lerpDelta(warmup, productionEfficiency > 0 ? 1f : 0f, warmupSpeed);
|
||||
|
||||
if(instability >= 1f){
|
||||
|
@ -7,8 +7,6 @@ import mindustry.world.meta.*;
|
||||
|
||||
/** An abstract class that defines a type of resource that a block can consume. */
|
||||
public abstract class Consume{
|
||||
|
||||
//TODO maybe remove these and make it an interface if possible?
|
||||
/** If true, this consumer will not influence consumer validity. */
|
||||
public boolean optional;
|
||||
/** If true, this consumer will be displayed as a boost input. */
|
||||
@ -61,7 +59,4 @@ public abstract class Consume{
|
||||
}
|
||||
|
||||
public void display(Stats stats){}
|
||||
|
||||
//TODO this should use efficiency instead - remove or deprecate
|
||||
//public abstract boolean valid(Building build);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user