-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow bukkit commands in /execute command #6501
Allow bukkit commands in /execute command #6501
Conversation
I feel like there should be a config option for this, this looks like it may have a chance of breaking maps designed for vanilla environments. |
I think that the ultimate end goal is that we replace the SimpleCommandMap with something which actually basically backs the internal command dispatcher, the current command system setup is basically a hacked together clusterfuck of hell |
How exactly would it break? You can still run all the same commands, there's just more of them.
Yeah absolutely. The whole CommandMap thing is really annoying. |
Some servers have plugins like Essentials installed, which override commands such as /tp. /execute is probably the most used command for checking if certain conditions are met. I'd imagine that servers running command block/function based maps would break if they also had a plugin installed that overrode a command that was working in /execute before this change. While trying to test for this, I tried to put the following command in a command block: |
Tbh. this isn't really a main concern in my eyes, especially seeing the major benefit of having plugin commands working again. Before the internal command changes plugin commands worked just fine in command blocks and similar issues arose hence the |
This… might be a bigger concern when my PR that fixes plugin commands in datapack functions is merged. Because then, any server with a datapack that uses /tp for example and has essentials, will break. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
3cb536c
to
c213444
Compare
Rebased for 1.18.1 |
c213444
to
b8a113d
Compare
Rebased for 1.18.2 |
#8235 |
Closing in favor of #8235 |
Oh what a beautiful command system bukkit has crammed on top of brigadier...
If there's a better way to fix this, let me know. Main issue is that when the
/execute
command, and its children are registered, the root node from the dispatcher it's using gets thrown away because a new instance of the dispatcher is created later on (inCraftServer#syncCommands
). So the root node it's using is "outdated". ThisDelegatingRootCommandNode
always calls for the latest one. Further changes were needed to make sure the player's are sent the correct redirect node for /execute instead of the "outdated" root node.