~ Engine update.
This commit is contained in:
parent
bc7e312dd2
commit
463b5e7f37
@ -192,7 +192,7 @@ public class BlockHunt extends JavaPlugin implements Listener {
|
|||||||
Permissions.start, ConfigC.help_start,
|
Permissions.start, ConfigC.help_start,
|
||||||
(Boolean) W.config.get(ConfigC.commandEnabled_start),
|
(Boolean) W.config.get(ConfigC.commandEnabled_start),
|
||||||
BlockHuntCMD, new CMDstart(),
|
BlockHuntCMD, new CMDstart(),
|
||||||
"/BlockHunt <start|st> <arenaname>");
|
"/BlockHunt <start|go> <arenaname>");
|
||||||
CMDwand = new CommandM("BlockHunt WAND", "BlockHunt", "wand", "w",
|
CMDwand = new CommandM("BlockHunt WAND", "BlockHunt", "wand", "w",
|
||||||
Permissions.create, ConfigC.help_wand,
|
Permissions.create, ConfigC.help_wand,
|
||||||
(Boolean) W.config.get(ConfigC.commandEnabled_wand),
|
(Boolean) W.config.get(ConfigC.commandEnabled_wand),
|
||||||
@ -704,49 +704,49 @@ public class BlockHunt extends JavaPlugin implements Listener {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (CommandM command : W.commands) {
|
for (CommandM command : W.commands) {
|
||||||
if (PermissionsM.hasPerm(player, command.permission, true)) {
|
String[] argsSplit = null;
|
||||||
String[] argsSplit = null;
|
String[] argsSplitAlias = null;
|
||||||
String[] argsSplitAlias = null;
|
|
||||||
|
|
||||||
if (command.args != null && command.argsalias != null) {
|
if (command.args != null && command.argsalias != null) {
|
||||||
argsSplit = command.args.split("/");
|
argsSplit = command.args.split("/");
|
||||||
argsSplitAlias = command.argsalias.split("/");
|
argsSplitAlias = command.argsalias.split("/");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cmd.getName().equalsIgnoreCase(command.label)) {
|
if (cmd.getName().equalsIgnoreCase(command.label)) {
|
||||||
boolean equals = true;
|
boolean equals = true;
|
||||||
|
|
||||||
if (argsSplit == null) {
|
if (argsSplit == null) {
|
||||||
if (args.length == 0) {
|
if (args.length == 0) {
|
||||||
equals = true;
|
equals = true;
|
||||||
} else {
|
} else {
|
||||||
equals = false;
|
equals = false;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (args.length >= argsSplit.length) {
|
||||||
|
for (int i2 = argsSplit.length - 1; i2 >= 0; i2 = i2 - 1) {
|
||||||
|
int loc = argsSplit.length - i2 - 1;
|
||||||
|
if (!argsSplit[loc].equalsIgnoreCase(args[loc])
|
||||||
|
&& !argsSplitAlias[loc]
|
||||||
|
.equalsIgnoreCase(args[loc])) {
|
||||||
|
equals = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (args.length >= argsSplit.length) {
|
equals = false;
|
||||||
for (int i2 = argsSplit.length - 1; i2 >= 0; i2 = i2 - 1) {
|
|
||||||
int loc = argsSplit.length - i2 - 1;
|
|
||||||
if (!argsSplit[loc].equalsIgnoreCase(args[loc])
|
|
||||||
&& !argsSplitAlias[loc]
|
|
||||||
.equalsIgnoreCase(args[loc])) {
|
|
||||||
equals = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
equals = false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (equals) {
|
if (equals) {
|
||||||
|
if (PermissionsM.hasPerm(player, command.permission, true)) {
|
||||||
if (command.enabled) {
|
if (command.enabled) {
|
||||||
command.CMD.exectue(player, cmd, label, args);
|
command.CMD.exectue(player, cmd, label, args);
|
||||||
} else {
|
} else {
|
||||||
MessageM.sendFMessage(player,
|
MessageM.sendFMessage(player,
|
||||||
ConfigC.error_commandNotEnabled);
|
ConfigC.error_commandNotEnabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,6 +13,6 @@ public class EngineInfo {
|
|||||||
* @author Steffion
|
* @author Steffion
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static String engineVersion = "3.0.0";
|
public static String engineVersion = "3.0.2";
|
||||||
public static String engineAuthors = "Steffion";
|
public static String engineAuthors = "Steffion";
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user