Minor bugfixes

This commit is contained in:
Anuken
2021-06-09 08:37:26 -04:00
parent 1895c7b8e0
commit 7dcfd648f7
2 changed files with 19 additions and 12 deletions
+5 -3
View File
@@ -131,7 +131,11 @@ public abstract class InputHandler implements InputProcessor, GestureListener{
@Remote(called = Loc.both, targets = Loc.both, forward = true, unreliable = true)
public static void deletePlans(Player player, int[] positions){
if(netServer.admins.allowAction(player, ActionType.removePlanned, a -> a.plans = positions)){
if(net.server() && !netServer.admins.allowAction(player, ActionType.removePlanned, a -> a.plans = positions)){
throw new ValidateException(player, "Player cannot remove plans.");
}
if(player == null) return;
var it = player.team().data().blocks.iterator();
//O(n^2) search here; no way around it
@@ -146,8 +150,6 @@ public abstract class InputHandler implements InputProcessor, GestureListener{
}
}
}
}
}
public static void createItemTransfer(Item item, int amount, float x, float y, Position to, Runnable done){
@@ -16,6 +16,11 @@ public class BlockUnloader extends BlockLoader{
return true;
}
@Override
public boolean rotatedOutput(int x, int y){
return false;
}
public class BlockUnloaderBuild extends BlockLoaderBuild{
@Override