Final 2.5.14
This commit is contained in:
parent
3792e0ebfc
commit
675a5651ef
@ -6,7 +6,7 @@
|
||||
|
||||
<groupId>net.t2code</groupId>
|
||||
<artifactId>CommandGUI_V2</artifactId>
|
||||
<version>2.5.12</version>
|
||||
<version>2.5.14</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>CommandGUI</name>
|
||||
@ -81,7 +81,7 @@
|
||||
<dependency>
|
||||
<groupId>net.t2code</groupId>
|
||||
<artifactId>T2CodeLib</artifactId>
|
||||
<version>7.4</version>
|
||||
<version>8</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.t2code.minecraft.1_18.r1</groupId>
|
||||
|
@ -17,6 +17,7 @@ public class Obj_Select {
|
||||
File[] fileArray = f.listFiles();
|
||||
|
||||
for (File config_gui : fileArray) {
|
||||
|
||||
Main.allAliases.add(config_gui.getName().replace(".yml", ""));
|
||||
String sub = config_gui.getName().substring(config_gui.getName().length() - 4);
|
||||
if (sub.equals(".yml")) {
|
||||
|
@ -31,7 +31,7 @@ public class CmdExecuter_Admin implements CommandExecutor, TabCompleter {
|
||||
if (sender.hasPermission("commandgui.command.info")) {
|
||||
Commands.info(sender);
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand
|
||||
.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.command.info"));
|
||||
.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.command.info"));
|
||||
|
||||
break;
|
||||
case "reload":
|
||||
@ -39,14 +39,14 @@ public class CmdExecuter_Admin implements CommandExecutor, TabCompleter {
|
||||
if (sender.hasPermission("commandgui.admin")) {
|
||||
Commands.reload(sender);
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand
|
||||
.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.admin"));
|
||||
.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.admin"));
|
||||
break;
|
||||
case "createdefaultgui":
|
||||
if (sender.hasPermission("commandgui.admin")) {
|
||||
DefaultGUICreate.configCreate();
|
||||
sender.sendMessage(SelectMessages.DefaultGUIcreate.replace("[directory]", Main.getPath() + "/GUIs/default.yml"));
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand
|
||||
.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.admin"));
|
||||
.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.admin"));
|
||||
break;
|
||||
case "debug":
|
||||
if (sender.hasPermission("commandgui.admin")) {
|
||||
@ -63,7 +63,7 @@ public class CmdExecuter_Admin implements CommandExecutor, TabCompleter {
|
||||
} else Debug.debugmsg();
|
||||
|
||||
*/
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.admin"));
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.admin"));
|
||||
break;
|
||||
|
||||
case "give":
|
||||
|
@ -39,15 +39,12 @@ public class Commands {
|
||||
send.player(player, prefix + "§4======= §8[§4Command§9GUI§8] §4=======");
|
||||
send.player(player, prefix + " §2Autor: §6" + String.valueOf(autor).replace("[", "").replace("]", ""));
|
||||
|
||||
|
||||
|
||||
if (UpdateAPI.PluginVersionen.get(plugin.getName()).publicVersion.equalsIgnoreCase(version)) {
|
||||
send.player(player, prefix + " §2Version: §6" + version);
|
||||
} else {
|
||||
UpdateAPI.sendUpdateMsg(prefix,spigot,discord,version,UpdateAPI.PluginVersionen.get(plugin.getName()).publicVersion,player);
|
||||
}
|
||||
|
||||
|
||||
send.player(player, prefix + " §2Spigot: §6" + spigot);
|
||||
send.player(player, prefix + " §2Discord: §6" + discord);
|
||||
send.player(player, prefix + "§4======= §8[§4Command§9GUI§8] §4=======");
|
||||
@ -73,6 +70,8 @@ public class Commands {
|
||||
send.console(prefix + " §6Plugin reload...");
|
||||
send.console(prefix + "§8-------------------------------");
|
||||
|
||||
CmdExecuter_GUI.arg1.clear();
|
||||
CmdExecuter_GUI.arg1.put("admin", "commandgui.admin;commandgui.giveitem.other;commandgui.command.info");
|
||||
ConfigCreate.configCreate();
|
||||
SelectConfig.onSelect();
|
||||
plugin.reloadConfig();
|
||||
|
@ -110,17 +110,7 @@ public class AliasRegister {
|
||||
org.bukkit.craftbukkit.v1_18_R1.CraftServer craftServer = (org.bukkit.craftbukkit.v1_18_R1.CraftServer) plugin.getServer();
|
||||
craftServer.getCommandMap().register(alias, new RegisterCommand(alias));
|
||||
}
|
||||
if (Bukkit.getServer().getClass().getPackage().getName().contains("1_18_R1")) {
|
||||
send.debug(plugin, "Alias register 1.18_R1");
|
||||
send.warning(Main.plugin, "Alias commands of the GUIs not available! 1.18 is not yet supported with this version!");
|
||||
// org.bukkit.craftbukkit.v1_18_R1.CraftServer craftServer = (org.bukkit.craftbukkit.v1_18_R1.CraftServer) plugin.getServer();
|
||||
// craftServer.getCommandMap().register(alias, new RegisterCommand(alias));
|
||||
//todo 1.18
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -58,7 +58,7 @@ public class CGuiAPI {
|
||||
if (sender.hasPermission("commandgui.command.info")) {
|
||||
Commands.info(sender);
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand
|
||||
.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.command.info"));
|
||||
.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.command.info"));
|
||||
}
|
||||
|
||||
public static void createDefaultGUI(CommandSender sender) {
|
||||
@ -66,14 +66,14 @@ public class CGuiAPI {
|
||||
DefaultGUICreate.configCreate();
|
||||
sender.sendMessage(SelectMessages.DefaultGUIcreate.replace("[directory]", Main.getPath() + "\\GUIs\\default.yml"));
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand
|
||||
.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.admin"));
|
||||
.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.admin"));
|
||||
}
|
||||
|
||||
public static void reload(CommandSender sender) {
|
||||
if (sender.hasPermission("commandgui.admin")) {
|
||||
Commands.reload(sender);
|
||||
} else sender.sendMessage(SelectMessages.NoPermissionForCommand
|
||||
.replace("[cmd]", "/commandguiadmin").replace("[perm]", "commandgui.admin"));
|
||||
.replace("[cmd]", "/commandgui admin").replace("[perm]", "commandgui.admin"));
|
||||
}
|
||||
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
MySQL:
|
||||
Enable: false
|
||||
IP: localhost
|
||||
Port: 3306
|
||||
Database: database
|
||||
|
Loading…
Reference in New Issue
Block a user