-
-
Notifications
You must be signed in to change notification settings - Fork 74
CommandPermission.fromString doesn't provide suggestions #73
Copy link
Copy link
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
CommandAPI version
v2.2
Minecraft version
1.14.4
Describe the bug
Using CommandPermission.fromString() to provide a permission node doesn't work as intended when using the GroupManager permission system. The text remains red when typing (should provide context and show argument colors such as aqua and light yellow), yet the command will run normally and work. Suggestions also don't work.
My code
This code reproduces the behavior:
LinkedHashMap<String, Argument> args = new LinkedHashMap<>();
args.put("player-name", new PlayerArgument());
args.put("message-text", new GreedyStringArgument());
CommandAPI.getInstance().register("test", CommandPermission.fromString("debug.command.sendmessage"), args, (commandSender, objects) -> {
final Player player = (Player) objects[0];
final String message = (String) objects[1];
player.sendMessage(ChatColor.translateAlternateColorCodes('&', message));
});Expected behavior
Commands work as you'd expect them to, with suggestions and color highlighting
Additional context
Originally posted by @portlek in #66 (comment)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
