LuckPerms

LuckPerms

41.4k Downloads

group-weight in config.yml

voodootje0 opened this issue ยท 9 comments

commented

This is my config.yml

group-weight:
  immortal: 45

But when I type /lp group immortal info it shows 25 (since that's the global weight). Also in /lp listgroups it shows 25 instead of 45.

commented

You probably have set the weight to 25 manually.

commented

What's then the meaning of group-weight in the config? There is also no explanation in the wiki.

commented

The group-weight config option was used before the command existed. There's no real use for it now, as it's much easier to just use the commands.

commented

Ahaaa.

Then I would suggest making the group-weight config option overriding the setweight command. This would be really helpful if you're having the same rank name on different servers.

commented

Any weights set with the setweight command will override what's in the config.

commented

This would break compat, and I prefer it the other way around.

commented

Could you then add /lp group setweight [context...]?

commented

Uhh, this is going to be difficult.

The weight of group is used throughout the permission resolution process. At this stage, the current context of the group is not known, therefore, it is not possible to determine a weight in a specific context.

Therefore, I am going to close this issue. I initially re-opened it because I thought changing this would be possible - it's only now when I went to actually implement it that I realised it won't be possible, due to the nature and current uses of the weight system.

Hopefully that makes sense. :)

This would be really helpful if you're having the same rank name on different servers.

If the ranks have different 'priorities' on different servers, then that's probably a sign that they should have distinct names.

commented

Aha, understood.

Thanks for your help.