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
/<gamemode> cmd generates island even if the create permission is unset #759
Comments
@wellnesscookie I understand the report but what is it that you are actually trying to do? It sounds like you want to prevent players who don't have an island from being able to use /island? If so, then you can give them the -bskyblock.island permission. That'll block all island commands. Is there a situation where you want to give a player who does not have an island access to island commands, but not island create? |
Yes, I'll give you an example: I want to give individiual player a permission to generate the island and let him invite as many more players as he wants. This means that those players would have standard access to all of acid commands, except ones that would allow them to anyhow generate their own acid island. I think that there is a walkthrough by blocking something here and there, but the bug report will stay unchanged since it really doesn't make any sense. |
I think it's because the main command might not call the "canExecute" method of each of the subcommand it tries to run. |
I was wondering if we could therefore add a |
I'm moving it to the 1.5.3 milestone and reduced priority. @tastybento, I need your feedback on my previous comments. |
@Poslovitch Yes. As this affects BSkyBlock, I went ahead and wrote a proposal. Please check it out. I took your idea of doing a call method. This will check permissions as well as run the canExecute and Execute methods. Note that permission checking was being done in the CompositeCommand execute method. |
* Implements new call API for commands #759 * pom.xml should not use tabs * Improved javadoc * refixed the since tag in javadoc
Now that the API has been implemented into BentoBox, it's going to be the job of gamemode addons to use it. Closing this ticket. |
Description
Describe the bug
The [gamemode].island.create permission does not prevents /ai from generating an island, instead it prevents only /ai create (Which makes this permission completely senseless)
This is probably related to all of the gamemodes and my issue should have been placed in each gamemode repository, but I find it more comforting to post it here rather than opening an issue per each gamemode section.
Steps to reproduce the behavior
Expected behavior
That actually makes no sense. I'd rather consider the island.create permission to block any kind of a generation started by a player that hasn't got this permission (even if the generation comes from /ai, and not /ai create)
Environment
Server
Java(TM) SE Runtime Environment 18.3 (build 10.0.1+10)
Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.1+10, mixed mode)
Plugins
BentoBox setup
BentoBox and Addons
Configuration
Additional context
Please move the issue if it really has to be placed in one of the gamemode addon repo trackers.
Sorry and thanks!
The text was updated successfully, but these errors were encountered: