Varieties of /teleport create ambiguities for tab-completion and syntax highlighting
The different syntaxes of /teleport introduce ambiguities for tab completion and syntax highlighting.
- Is the first argument destination or targets? "/tp @p <tab>" doesn't give tab completions for the <destination> argument. "/tp @a" doesn't complain that the <destination> argument may only return one entity.
- Is the first argument a player name or part of a set of coordinates? Attempting to teleport the player 1234321 to 0 0 0: type "/teleport 1234321" and start typing in the coordinates, after the y-coordinate, "1234321 0 0" will be highlighted as one argument even though it isn't.
- Is the second argument a player name or part of a set of coordinates? When I want to teleport myself to 0 0 0, I type "/teleport @p". After the x coordinate, it highlights the 0 in "/teleport @p 0" as a valid argument.
This could be fixed by introducing keywords or even subcommands like it was done to avoid ambiguities in /execute, or like it was done in /data.
2018-01-10, 08:00 PM
2023-10-26, 07:42 PM
78
30
Minecraft 18w02a - 23w05a
Minecraft 18w02a, Minecraft 18w06a, Minecraft 18w20c, Minecraft 1.13-pre1, Minecraft 1.13, Minecraft 18w31a, Minecraft 1.13.1, Minecraft 1.13.2, Minecraft 19w02a, Minecraft 19w03a, Minecraft 19w03b, Minecraft 1.14.2, 1.14.4, 19w37a, 1.15 Pre-release 6, 1.15.1, 1.15.2, 20w07a, 1.16 Pre-release 2, 1.16.1, 20w29a, 1.16.4 Pre-release 2, 21w03a, 1.17.1, 1.18, 1.18.1, 1.18.2, 23w05a
-