Fix BauSystem RedstoneTester loading
Fix CommandGUI RedstoneTester loading
Dieser Commit ist enthalten in:
Ursprung
5706c79389
Commit
f75292cbbc
@ -99,7 +99,9 @@ public class BauSystem extends JavaPlugin implements Listener {
|
|||||||
getCommand("script").setExecutor(new CommandScript());
|
getCommand("script").setExecutor(new CommandScript());
|
||||||
getCommand("simulator").setExecutor(new CommandSimulator());
|
getCommand("simulator").setExecutor(new CommandSimulator());
|
||||||
getCommand("simulator").setTabCompleter(new CommandSimulatorTabCompleter());
|
getCommand("simulator").setTabCompleter(new CommandSimulatorTabCompleter());
|
||||||
getCommand("redstonetester").setExecutor(new CommandRedstoneTester());
|
if (Core.getVersion() >= 15) {
|
||||||
|
getCommand("redstonetester").setExecutor(new CommandRedstoneTester());
|
||||||
|
}
|
||||||
getCommand("gui").setExecutor(new CommandGUI());
|
getCommand("gui").setExecutor(new CommandGUI());
|
||||||
|
|
||||||
Bukkit.getPluginManager().registerEvents(this, this);
|
Bukkit.getPluginManager().registerEvents(this, this);
|
||||||
@ -110,7 +112,9 @@ public class BauSystem extends JavaPlugin implements Listener {
|
|||||||
Bukkit.getPluginManager().registerEvents(new TNTSimulatorListener(), this);
|
Bukkit.getPluginManager().registerEvents(new TNTSimulatorListener(), this);
|
||||||
Bukkit.getPluginManager().registerEvents(new CommandGUI(), this);
|
Bukkit.getPluginManager().registerEvents(new CommandGUI(), this);
|
||||||
Bukkit.getPluginManager().registerEvents(new DetonatorListener(), this);
|
Bukkit.getPluginManager().registerEvents(new DetonatorListener(), this);
|
||||||
Bukkit.getPluginManager().registerEvents(new RedstoneListener(), this);
|
if (Core.getVersion() >= 15) {
|
||||||
|
Bukkit.getPluginManager().registerEvents(new RedstoneListener(), this);
|
||||||
|
}
|
||||||
new AFKStopper();
|
new AFKStopper();
|
||||||
|
|
||||||
autoShutdown = Bukkit.getScheduler().runTaskLater(this, Bukkit::shutdown, 1200);
|
autoShutdown = Bukkit.getScheduler().runTaskLater(this, Bukkit::shutdown, 1200);
|
||||||
|
@ -81,7 +81,11 @@ public class CommandGUI implements CommandExecutor, Listener {
|
|||||||
if (Welt.noPermission(player, Permission.build))
|
if (Welt.noPermission(player, Permission.build))
|
||||||
return;
|
return;
|
||||||
player.closeInventory();
|
player.closeInventory();
|
||||||
player.performCommand("redstonetester");
|
if (Core.getVersion() >= 15) {
|
||||||
|
player.performCommand("redstonetester");
|
||||||
|
} else {
|
||||||
|
player.sendMessage(BauSystem.PREFIX + "Der RedstoneTester ist nicht in der 1.12 verfügbar");
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
inv.setItem(40, getMaterial("WOODEN_AXE", "WOOD_AXE"), "§eWorldedit Axt", getNoPermsLore(Arrays.asList("§8//§7wand"), player, "§cDu hast keine Worldeditrechte", Permission.worldedit), false, clickType -> {
|
inv.setItem(40, getMaterial("WOODEN_AXE", "WOOD_AXE"), "§eWorldedit Axt", getNoPermsLore(Arrays.asList("§8//§7wand"), player, "§cDu hast keine Worldeditrechte", Permission.worldedit), false, clickType -> {
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren