From ca864655d184bb9c9a36d87ccde61fd82b299b14 Mon Sep 17 00:00:00 2001 From: Anuken Date: Tue, 18 Aug 2020 13:22:06 -0400 Subject: [PATCH] More bugfixes --- core/src/mindustry/core/NetServer.java | 2 ++ core/src/mindustry/entities/comp/WaterMoveComp.java | 4 +++- core/src/mindustry/world/blocks/logic/LogicBlock.java | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/core/src/mindustry/core/NetServer.java b/core/src/mindustry/core/NetServer.java index 0225f64f08..fd169870ad 100644 --- a/core/src/mindustry/core/NetServer.java +++ b/core/src/mindustry/core/NetServer.java @@ -332,6 +332,8 @@ public class NetServer implements ApplicationListener{ Call.sendMessage(Strings.format("[lightgray]A player has voted on kicking[orange] @[].[accent] (@/@)\n[lightgray]Type[orange] /vote [] to agree.", target.name, votes, votesRequired())); + + checkPass(); } boolean checkPass(){ diff --git a/core/src/mindustry/entities/comp/WaterMoveComp.java b/core/src/mindustry/entities/comp/WaterMoveComp.java index 4842280206..d72fe4959b 100644 --- a/core/src/mindustry/entities/comp/WaterMoveComp.java +++ b/core/src/mindustry/entities/comp/WaterMoveComp.java @@ -10,6 +10,7 @@ import mindustry.entities.*; import mindustry.gen.*; import mindustry.graphics.*; import mindustry.type.*; +import mindustry.world.*; import mindustry.world.blocks.environment.*; import static mindustry.Vars.*; @@ -95,7 +96,8 @@ abstract class WaterMoveComp implements Posc, Velc, Hitboxc, Flyingc, Unitc{ } public boolean onLiquid(){ - return floorOn().isLiquid; + Tile tile = tileOn(); + return tile != null && tile.floor().isLiquid; } } diff --git a/core/src/mindustry/world/blocks/logic/LogicBlock.java b/core/src/mindustry/world/blocks/logic/LogicBlock.java index ce4053ac9b..1f61097944 100644 --- a/core/src/mindustry/world/blocks/logic/LogicBlock.java +++ b/core/src/mindustry/world/blocks/logic/LogicBlock.java @@ -16,6 +16,7 @@ import mindustry.logic.LAssembler.*; import mindustry.logic.LExecutor.*; import mindustry.ui.*; import mindustry.world.*; +import mindustry.world.blocks.BuildBlock.*; import java.io.*; import java.util.zip.*; @@ -380,7 +381,7 @@ public class LogicBlock extends Block{ } public boolean validLink(Building other){ - return other != null && other.isValid() && other.team == team && other.within(this, range + other.block.size*tilesize/2f); + return other != null && other.isValid() && other.team == team && other.within(this, range + other.block.size*tilesize/2f) && !(other instanceof BuildEntity); } @Override