mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-03-04 06:31:42 +07:00
Fixed #7633
This commit is contained in:
parent
e21cac75b5
commit
48a5ae443f
@ -507,9 +507,7 @@ public class Damage{
|
||||
}
|
||||
|
||||
public static void tileDamage(Team team, int x, int y, float baseRadius, float damage, @Nullable Bullet source){
|
||||
|
||||
Core.app.post(() -> {
|
||||
|
||||
var in = world.build(x, y);
|
||||
//spawned inside a multiblock. this means that damage needs to be dealt directly.
|
||||
//why? because otherwise the building would absorb everything in one cell, which means much less damage than a nearby explosion.
|
||||
|
@ -21,7 +21,7 @@ public class LiquidDisplay extends Table{
|
||||
this.perSecond = perSecond;
|
||||
|
||||
add(new Stack(){{
|
||||
add(new Image(liquid.uiIcon));
|
||||
add(new Image(liquid.uiIcon).setScaling(Scaling.fit));
|
||||
|
||||
if(amount != 0){
|
||||
Table t = new Table().left().bottom();
|
||||
|
@ -237,6 +237,19 @@ public class GenericCrafter extends Block{
|
||||
dumpOutputs();
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getProgressIncrease(float baseTime){
|
||||
//limit progress increase by maximum amount of liquid it can produce
|
||||
float scaling = 1f;
|
||||
if(outputLiquids != null){
|
||||
for(var s : outputLiquids){
|
||||
scaling = Math.min(scaling, (liquidCapacity - liquids.get(s.liquid)) / (s.amount * edelta()));
|
||||
}
|
||||
}
|
||||
|
||||
return super.getProgressIncrease(baseTime) * scaling;
|
||||
}
|
||||
|
||||
public float warmupTarget(){
|
||||
return 1f;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user