From 7e6807509b77071559e3a87461793c52e35f0ff3 Mon Sep 17 00:00:00 2001 From: Anuken Date: Tue, 3 Jul 2018 10:47:33 -0400 Subject: [PATCH] Fixed mobile breaking not taking into account multiblocks --- core/src/io/anuke/mindustry/input/MobileInput.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/src/io/anuke/mindustry/input/MobileInput.java b/core/src/io/anuke/mindustry/input/MobileInput.java index f4244adfc6..88555a84b9 100644 --- a/core/src/io/anuke/mindustry/input/MobileInput.java +++ b/core/src/io/anuke/mindustry/input/MobileInput.java @@ -568,8 +568,9 @@ public class MobileInput extends InputHandler implements GestureListener{ }else if(mode == placing && isPlacing() && validPlace(cursor.x, cursor.y, recipe.result, rotation) && !checkOverlapPlacement(cursor.x, cursor.y, recipe.result)){ //add to selection queue if it's a valid place position selection.add(lastPlaced = new PlaceRequest(cursor.worldx(), cursor.worldy(), recipe, rotation)); - }else if(mode == breaking && validBreak(cursor.x, cursor.y) && !hasRequest(cursor)) { + }else if(mode == breaking && validBreak(cursor.target().x, cursor.target().y) && !hasRequest(cursor.target())) { //add to selection queue if it's a valid BREAK position + cursor = cursor.target(); selection.add(new PlaceRequest(cursor.worldx(), cursor.worldy())); }else{ //else, try and carry units if(player.getCarry() != null){