ChaosBauGUI #183
@ -170,7 +170,7 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
inv.setItem(18, Material.BARRIER, "§eKeine Region", clickType -> {});
|
inv.setItem(18, Material.BARRIER, "§eKeine Region", clickType -> {});
|
||||||
inv.setItem(27, Material.BARRIER, "§eKeine Region", clickType -> {});
|
inv.setItem(27, Material.BARRIER, "§eKeine Region", clickType -> {});
|
||||||
}else {
|
}else {
|
||||||
inv.setItem(27, Material.HEAVY_WEIGHTED_PRESSURE_PLATE, "§eRegion Reseten", getNoPermsLore(Arrays.asList("§8/§7reset"), player, "§cDu hast keine Worldrechte", Permission.world), false, clickType -> {
|
inv.setItem(27, getMaterial("HEAVY_WEIGHTED_PRESSURE_PLATE", "IRON_PLATE"), "§eRegion Reseten", getNoPermsLore(Arrays.asList("§8/§7reset"), player, "§cDu hast keine Worldrechte", Permission.world), false, clickType -> {
|
||||||
if(Welt.noPermission(player, Permission.world))
|
if(Welt.noPermission(player, Permission.world))
|
||||||
return;
|
return;
|
||||||
confirmationInventory(player, "Region Reseten?", () -> player.performCommand("reset"), () -> openBauGui(player));
|
confirmationInventory(player, "Region Reseten?", () -> player.performCommand("reset"), () -> openBauGui(player));
|
||||||
@ -233,7 +233,7 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case ONLY_TB:
|
case ONLY_TB:
|
||||||
inv.setItem(23, Material.TNT_MINECART, "§7TNT: §enur Testblock", tntLore, false, clickType -> {
|
inv.setItem(23, getMaterial("TNT_MINECART", "EXPLOSIVE_MINECART"), "§7TNT: §enur Testblock", tntLore, false, clickType -> {
|
||||||
if(Welt.noPermission(player, Permission.world))
|
if(Welt.noPermission(player, Permission.world))
|
||||||
return;
|
return;
|
||||||
player.performCommand("tnt on");
|
player.performCommand("tnt on");
|
||||||
@ -250,7 +250,7 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(region.isFreeze()) {
|
if(region.isFreeze()) {
|
||||||
inv.setItem(24, Material.GUNPOWDER, "§7Freeze: §eEingeschaltet", getNoPermsLore(Arrays.asList("§8/§7freeze"), player, "§cDu hast keine Worldrechte", Permission.world), false, clickType -> {
|
inv.setItem(24, getMaterial("GUNPOWDER", "SULPHUR"), "§7Freeze: §eEingeschaltet", getNoPermsLore(Arrays.asList("§8/§7freeze"), player, "§cDu hast keine Worldrechte", Permission.world), false, clickType -> {
|
||||||
if(Welt.noPermission(player, Permission.world))
|
if(Welt.noPermission(player, Permission.world))
|
||||||
return;
|
return;
|
||||||
player.performCommand("freeze");
|
player.performCommand("freeze");
|
||||||
@ -339,7 +339,7 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
inv.setItem(4, Material.TNT_MINECART, "§7Trace GUI", Collections.singletonList("§8/§7trace show gui"), false, clickType -> {
|
inv.setItem(4, getMaterial("TNT_MINECART", "EXPLOSIVE_MINECART"), "§7Trace GUI", Collections.singletonList("§8/§7trace show gui"), false, clickType -> {
|
||||||
player.closeInventory();
|
player.closeInventory();
|
||||||
player.performCommand("trace show gui");
|
player.performCommand("trace show gui");
|
||||||
});
|
});
|
||||||
@ -399,7 +399,7 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
anvilInv.open();
|
anvilInv.open();
|
||||||
});
|
});
|
||||||
|
|
||||||
inv.setItem(6, Material.CLOCK, "§7Block platzier Geschwindigkeit", Arrays.asList("§7Aktuell: §e" + loader.getTicksBetweenBlocks(), "§8/§7loader speed §8[§eTicks§8]"), false, clickType -> {
|
inv.setItem(6, getMaterial("CLOCK", "WATCH"), "§7Block platzier Geschwindigkeit", Arrays.asList("§7Aktuell: §e" + loader.getTicksBetweenBlocks(), "§8/§7loader speed §8[§eTicks§8]"), false, clickType -> {
|
||||||
SWAnvilInv anvilInv = new SWAnvilInv(player, "Platzier Geschwindigkeit", loader.getTicksBetweenBlocks() + "");
|
SWAnvilInv anvilInv = new SWAnvilInv(player, "Platzier Geschwindigkeit", loader.getTicksBetweenBlocks() + "");
|
||||||
anvilInv.setItem(Material.STONE);
|
anvilInv.setItem(Material.STONE);
|
||||||
anvilInv.setCallback(s -> {
|
anvilInv.setCallback(s -> {
|
||||||
@ -550,11 +550,11 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
|
|
||||||
private static void confirmationInventory(Player player, String title, Runnable confirm, Runnable decline) {
|
private static void confirmationInventory(Player player, String title, Runnable confirm, Runnable decline) {
|
||||||
SWInventory inv = new SWInventory(player, 9, title);
|
SWInventory inv = new SWInventory(player, 9, title);
|
||||||
inv.setItem(0, SWItem.getDye(1), "§cAbbrechen", clickType -> {
|
inv.setItem(0, SWItem.getDye(1), (byte) 1, "§cAbbrechen", clickType -> {
|
||||||
player.closeInventory();
|
player.closeInventory();
|
||||||
decline.run();
|
decline.run();
|
||||||
});
|
});
|
||||||
inv.setItem(8, SWItem.getDye(10), "§aBestätigen", clickType -> {
|
inv.setItem(8, SWItem.getDye(10), (byte) 10, "§aBestätigen", clickType -> {
|
||||||
player.closeInventory();
|
player.closeInventory();
|
||||||
confirm.run();
|
confirm.run();
|
||||||
});
|
});
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren