ElgarL / GroupManager

The original permission plug-in for Spigot/Bukkit.
https://elgarl.github.io/GroupManager/
GNU General Public License v3.0
80 stars 36 forks source link

[BUG] Players don't get their current world permissions when joining #17

Closed ghost closed 4 years ago

ghost commented 4 years ago

Hello ! ^^ First of all, thank you very much for maintaining this historical plugin. :D

Describe the bug : I have some worlds which avec more permissions than the globalgroups.yml file for some groups. But players in those groups don't get those permissions in the world where they are joining. If they go to another world, and come back to the first one, they get thos permissions.

On the contrary, if there is a permission in globalgroups.yml but not in the current world, they are denied to execute the command... Which is 100% normal.

To Reproduce : Create a multi-world configurations with more permissions in a certain world.

Informations :

Thank you in advance for you answer and have a nice day !

ghost commented 4 years ago

Update : I made some tests with your code on my server, and durint the onPlayerLogin event, player.getWorld().getName() returns the default world, not the player current's. Which is strange, but has nothing to do with GroupManager. Sorry for inconvenience, I'm closing this issue. Have a nice day !

ghost commented 4 years ago

Update : This is a Spigot problem : PlayerLoginEvent.getPlayer().getWorld() always returns the first world.