Fixed tests again, locally

This commit is contained in:
Anuken
2019-01-26 13:20:07 -05:00
parent 4be675f977
commit 956448a1a5
6 changed files with 236 additions and 11 deletions

View File

@@ -151,7 +151,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
if(health <= 0){
Call.onTileDestroyed(tile);
}else if(preHealth >= maxHealth() - 0.00001f && health < maxHealth()){ //when just damaged
}else if(preHealth >= maxHealth() - 0.00001f && health < maxHealth() && world != null){ //when just damaged
world.indexer.notifyTileDamaged(this);
}
}

View File

@@ -87,9 +87,7 @@ public class ItemLiquidGenerator extends PowerGenerator{
float used = Math.min(entity.liquids.get(liquid) * calculationDelta, maximumPossible);
entity.liquids.remove(liquid, used);
// Note: 0.5 = 100%. PowerGraph will multiply this efficiency by two on its own.
entity.productionEfficiency = Mathf.clamp(baseLiquidEfficiency * used / maximumPossible);
entity.productionEfficiency = baseLiquidEfficiency * used / maximumPossible;
if(used > 0.001f && Mathf.chance(0.05 * entity.delta())){
Effects.effect(generateEffect, tile.drawx() + Mathf.range(3f), tile.drawy() + Mathf.range(3f));