-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Labels
type: bugSomething doesn't work as it was intended to.Something doesn't work as it was intended to.version: 1.16Game version 1.16Game version 1.16
Description
Expected behavior
Player1 or Console performed command:
/tt 1 2 3 4 5 0
TestPlugin onCommand handler received:
arguments: ["1", "2", "3", "4", "5", "0"]
Observed/Actual behavior
Player1 performed command:
/tt 1 2 3 4 5 0
TestPlugin onCommand handler received:
arguments: ["1", "2", "3", "4", "5", "0"]
Console performed command:
/tt 1 2 3 4 5 0
TestPlugin onCommand handler received:
arguments: ["1", "2", "", "3", "", "", "4", "", "", "", "5", "", "", "", "", "0"]
Steps/models to reproduce
@Override
public boolean onCommand(CommandSender theSender, Command theCommand, String labelString, String[] arguments) {
if (theCommand.getName().equalsIgnoreCase("tt")) {
System.out.println("arguments: [\"" + String.join("\", \"", arguments) + "\"]");
return true;
}
return false;
}Then try to perform tt command with more than 1 space between arguments from game chat and server console and see the difference. This problem can break some plugins which do not expect to see empty strings as the argument value, because you can't send an empty argument from a game chat.
Plugin list
TestPlugin
Paper version
git-Paper-763 (MC: 1.16.5)
Agreements
- I am running the latest version of Paper available from https://papermc.io/downloads.
- I have searched for and ensured there isn't already an open issue regarding this.
- My version of Minecraft is supported by Paper.
Other
No response
Metadata
Metadata
Assignees
Labels
type: bugSomething doesn't work as it was intended to.Something doesn't work as it was intended to.version: 1.16Game version 1.16Game version 1.16