Fixed some bugs with multiplayer/file chooser
This commit is contained in:
@@ -6,6 +6,7 @@ import com.badlogic.gdx.math.Rectangle;
|
|||||||
import com.badlogic.gdx.math.Vector2;
|
import com.badlogic.gdx.math.Vector2;
|
||||||
import com.badlogic.gdx.utils.Array;
|
import com.badlogic.gdx.utils.Array;
|
||||||
import io.anuke.mindustry.Vars;
|
import io.anuke.mindustry.Vars;
|
||||||
|
import io.anuke.mindustry.entities.Player;
|
||||||
import io.anuke.mindustry.graphics.Fx;
|
import io.anuke.mindustry.graphics.Fx;
|
||||||
import io.anuke.mindustry.net.Net;
|
import io.anuke.mindustry.net.Net;
|
||||||
import io.anuke.mindustry.resource.ItemStack;
|
import io.anuke.mindustry.resource.ItemStack;
|
||||||
@@ -26,6 +27,7 @@ import io.anuke.ucore.util.Mathf;
|
|||||||
import io.anuke.ucore.util.Tmp;
|
import io.anuke.ucore.util.Tmp;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.*;
|
import static io.anuke.mindustry.Vars.*;
|
||||||
|
import static io.anuke.mindustry.Vars.player;
|
||||||
|
|
||||||
public abstract class InputHandler extends InputAdapter{
|
public abstract class InputHandler extends InputAdapter{
|
||||||
public float breaktime = 0;
|
public float breaktime = 0;
|
||||||
@@ -106,8 +108,10 @@ public abstract class InputHandler extends InputAdapter{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!Vars.android && Tmp.r2.overlaps(player.hitbox.getRect(player.x, player.y))){
|
for(Player player : Vars.control.playerGroup.all()){
|
||||||
return false;
|
if(!player.isAndroid && Tmp.r2.overlaps(player.hitbox.getRect(player.x, player.y))){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Tile tile = world.tile(x, y);
|
Tile tile = world.tile(x, y);
|
||||||
|
|||||||
@@ -50,6 +50,7 @@ public class FileChooser extends FloatingDialog {
|
|||||||
Table content = new Table();
|
Table content = new Table();
|
||||||
|
|
||||||
filefield = new TextField();
|
filefield = new TextField();
|
||||||
|
filefield.setOnlyFontChars(false);
|
||||||
if(!open) Mindustry.platforms.addDialog(filefield);
|
if(!open) Mindustry.platforms.addDialog(filefield);
|
||||||
filefield.setDisabled(open);
|
filefield.setDisabled(open);
|
||||||
|
|
||||||
|
|||||||
@@ -52,6 +52,7 @@ public class DefenseBlocks{
|
|||||||
range = 30;
|
range = 30;
|
||||||
reload = 60f;
|
reload = 60f;
|
||||||
health = 60;
|
health = 60;
|
||||||
|
powerUsed = 0.08f;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -59,8 +60,8 @@ public class DefenseBlocks{
|
|||||||
{
|
{
|
||||||
range = 44;
|
range = 44;
|
||||||
reload = 30f;
|
reload = 30f;
|
||||||
powerUsed = 0.15f;
|
|
||||||
health = 90;
|
health = 90;
|
||||||
|
powerUsed = 0.13f;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user