@@ -69,7 +69,7 @@ public class Puddles{
|
||||
if(tile.floor().solid) return;
|
||||
|
||||
Puddle p = map.get(tile.pos());
|
||||
if(p == null){
|
||||
if(p == null || p.liquid == null){
|
||||
Puddle puddle = Puddle.create();
|
||||
puddle.tile = tile;
|
||||
puddle.liquid = liquid;
|
||||
@@ -107,6 +107,8 @@ public class Puddles{
|
||||
|
||||
/** Reacts two liquids together at a location. */
|
||||
private static float reactPuddle(Liquid dest, Liquid liquid, float amount, Tile tile, float x, float y){
|
||||
if(dest == null) return 0f;
|
||||
|
||||
if((dest.flammability > 0.3f && liquid.temperature > 0.7f) ||
|
||||
(liquid.flammability > 0.3f && dest.temperature > 0.7f)){ //flammable liquid + hot liquid
|
||||
Fires.create(tile);
|
||||
|
||||
@@ -142,6 +142,8 @@ abstract class PuddleComp implements Posc, Puddlec, Drawc, Syncc{
|
||||
|
||||
@Override
|
||||
public void afterSync(){
|
||||
Puddles.register(self());
|
||||
if(liquid != null){
|
||||
Puddles.register(self());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -261,7 +261,9 @@ public class ArcNetProvider implements NetProvider{
|
||||
}
|
||||
ByteBuffer buffer = ByteBuffer.wrap(packet.getData());
|
||||
Host host = NetworkIO.readServerData((int)Time.timeSinceMillis(time), packet.getAddress().getHostAddress(), buffer);
|
||||
callback.get(host);
|
||||
Core.app.post(() -> {
|
||||
callback.get(host);
|
||||
});
|
||||
foundAddresses.add(packet.getAddress());
|
||||
}catch(Exception e){
|
||||
//don't crash when there's an error pinging a server or parsing data
|
||||
|
||||
Reference in New Issue
Block a user