Fixed #2224
This commit is contained in:
@@ -432,6 +432,10 @@ public class DesktopInput extends InputHandler{
|
||||
if(Core.input.keyTap(Binding.pause_building)){
|
||||
isBuilding = !isBuilding;
|
||||
buildWasAutoPaused = false;
|
||||
|
||||
if(isBuilding){
|
||||
player.shooting = false;
|
||||
}
|
||||
}
|
||||
|
||||
if((cursorX != lastLineX || cursorY != lastLineY) && isPlacing() && mode == placing){
|
||||
@@ -460,7 +464,7 @@ public class DesktopInput extends InputHandler{
|
||||
deleting = true;
|
||||
}else if(selected != null){
|
||||
//only begin shooting if there's no cursor event
|
||||
if(!tileTapped(selected.build) && !tryTapPlayer(Core.input.mouseWorld().x, Core.input.mouseWorld().y) && (player.builder().plans().size == 0 || !player.builder().isBuilding()) && !droppingItem &&
|
||||
if(!tileTapped(selected.build) && !tryTapPlayer(Core.input.mouseWorld().x, Core.input.mouseWorld().y) && (player.builder().plans().size == 0 || !player.builder().updateBuilding()) && !droppingItem &&
|
||||
!tryBeginMine(selected) && player.miner().mineTile() == null && !Core.scene.hasKeyboard()){
|
||||
player.shooting = shouldShoot;
|
||||
}
|
||||
|
||||
@@ -299,7 +299,7 @@ public abstract class InputHandler implements InputProcessor, GestureListener{
|
||||
player.typing = ui.chatfrag.shown();
|
||||
|
||||
if(player.isBuilder()){
|
||||
player.builder().building(isBuilding);
|
||||
player.builder().updateBuilding(isBuilding);
|
||||
}
|
||||
|
||||
if(!player.dead()){
|
||||
@@ -901,7 +901,7 @@ public abstract class InputHandler implements InputProcessor, GestureListener{
|
||||
}
|
||||
|
||||
public boolean canShoot(){
|
||||
return block == null && !Core.scene.hasMouse() && !onConfigurable() && !isDroppingItem();
|
||||
return block == null && !Core.scene.hasMouse() && !onConfigurable() && !isDroppingItem() && !(player.builder().updateBuilding() && player.builder().isBuilding());
|
||||
}
|
||||
|
||||
public boolean onConfigurable(){
|
||||
|
||||
Reference in New Issue
Block a user