Message added to the '/gui-item' command if this function is disabled

This commit is contained in:
JaTiTV 2021-12-29 06:55:36 +01:00
parent a80d0d3e43
commit f734748df8

View File

@ -23,7 +23,9 @@ public class CmdExecuter_GUIItem implements CommandExecutor, TabCompleter {
Player player = (Player) sender;
if (sender.hasPermission("commandgui.useitem.toggle")) {
if (args.length == 0) {
Help.sendGUIItemHelp(sender, prefix);
if (SelectConfig.UseItem_AllowToggle) {
Help.sendGUIItemHelp(sender, prefix);
} else send.sender(sender, "§4UseItem toggle is disabled!");// todo
} else {
if (args.length == 1 || args.length == 2) {
if (sender instanceof Player) {
@ -50,7 +52,7 @@ public class CmdExecuter_GUIItem implements CommandExecutor, TabCompleter {
Help.sendHelp(player, prefix);
}
}
} else send.sender(sender, "§4UseItem toggle is disabled!");// todo
} else sender.sendMessage(SelectMessages.OnlyForPlayer);
}
}