Bugfixes
This commit is contained in:
@@ -484,7 +484,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.unit().activelyBuilding() && !droppingItem &&
|
||||
if(!tryTapPlayer(Core.input.mouseWorld().x, Core.input.mouseWorld().y) && !tileTapped(selected.build) && !player.unit().activelyBuilding() && !droppingItem &&
|
||||
!tryBeginMine(selected) && player.unit().mineTile == null && !Core.scene.hasKeyboard()){
|
||||
player.shooting = shouldShoot;
|
||||
}
|
||||
|
||||
@@ -1056,6 +1056,10 @@ public abstract class InputHandler implements InputProcessor, GestureListener{
|
||||
return droppingItem;
|
||||
}
|
||||
|
||||
public boolean canDropItem(){
|
||||
return droppingItem && !canTapPlayer(Core.input.mouseWorldX(), Core.input.mouseWorldY());
|
||||
}
|
||||
|
||||
public void tryDropItems(@Nullable Building tile, float x, float y){
|
||||
if(!droppingItem || player.unit().stack.amount <= 0 || canTapPlayer(x, y) || state.isPaused() ){
|
||||
droppingItem = false;
|
||||
|
||||
Reference in New Issue
Block a user