PermissionsEx

PermissionsEx

14M Downloads

Subgroups

Loonyy opened this issue · 26 comments

commented

Hey, I've transferred from GroupManager to PermissionsEx and one feature in GroupManager that I used was Subgroups.

Subgroups was basically like inherit. Players can be in a group but inherit the permissions of another group. I'm not sure how to do this with PermissionsEx; I tried the /pex user Loonyy group add Helper but that either seems to put me in the Helper group or add the group to me but give me the Helper prefix, it's a little unreliable.

Any help?

commented

The following is in regards to PermissionsEx 1.x versions.
(I'm not sure how it works exactly in PEX 2.x, but it's likely very similar.)

See this example first.

With PEX, if Stormbow joined the server and was promoted to the group named "Member", and we have setup "Member" to inherit permissions from the group named "Guest" (lines 29 and 30), Stormbow gains all of the permissions of both groups. Stormbow wouldn't need to actually be a member of both groups.

Much further down the example, if Stormbow was an "Admin", he would inherit from "Mod", which inherits from "Member", which inherits from "Guest" and Stormbow would end up with all of the permissions from "Admin", "Mod", "Member", and "Guest" without needing to be in all 4 groups.

Is that was you're asking about?

commented

No, but thank you for the reply.

I already have group inherits set up correctly. I'm wanting player-group inherits.
I need player group inherits because if I hire a player as Moderator, and they donate for the highest rank (Emperor) with lots of permissions in that Emperor group, I want their main rank to continue to be Moderator but I want that player to inherit the Emperor rank so they still have access to Emperor commands and permissions. Does that make sense?

commented

Basically;
A player can be in multiple groups at once but only one specific groups' prefix shows up.

commented

That's accomplished with group add and weight values. See the example I linked above.

If a user was in "Member" and "Admin", only the "Admin" prefix would show up, depending on how you setup your required chat management plugin. (And the EssentialsChat/EssentialsXChat plugin requires Vault.)

commented

"Loonyy" would start in the "Guest" group of that example. If you wanted them to also be an Admin, you'd type /pex user Loonyy group add Admin and they'd now be a member of 2 groups, with "Admin" showing in chat.

commented

I've just setup all the ranks and weights for each group and the wrong prefix for groups on users are showing up still. I am using the latest version of PEX but I'm on Spigot 1.11

commented

Copy your full permissions.yml file to Pastebin for me to look at.

Tell me exactly which user, groups they're in, and prefix is showing.

commented
commented

Every group I've tried it with, it doesn't work.

I've mainly been doing it with my staff ranks and donation ranks, here's some examples:
Moderator and Emperor.
Architect and Defender.
Helper and Knight.

commented

Also, when I use the PEX command in game to check the weight and rank for groups, it's all listed as normal.

commented

Which user is getting the wrong prefix? Which prefix should they be getting?

commented

Many, many problems in that file that I can see so far:

• Groups should not have the same rank values. (e.g., Helper, Moderator)

• Groups should not have the same weight values. (e.g., Prince, Emperor)

• All of your option: sections are not indented properly.

• All of your permissions: sections are indented too far.

• All of your weight values are backwards. "Owner" should be 1 and "Squire" should be the highest number, typically 1000.

commented

You're welcome. Let me know— after you've gotten it all fixed —if you run into other problems.

commented

(You can still reply here. It's just not on the 'open' tickets list now.)

commented

Brb while I /suicide because I now have to fix all this

  • Thanks for the support :)
commented

I fixed the issues in the config;
The issue I can see right now is that Emperor is overriding all other groups, meaning if I add someone the Moderator group and Emperor, the Emperor prefix will show.

Here's my Permissions file:
http://pastebin.com/tdgVAgES

commented

In the server.properties file on the server, is online-mode set to true?

commented

Yes it is.

commented

Are there any error messages at all in the startup log?

commented

Nope, no errors.

commented

Show me the full file, including all of the user information. Upload it to Dropbox or something if it's too long to paste.

Nevermind. I bet this is the problem (in the Emperor group):

  weight: ‘500'

is not encapsulated in apostrophes.

Change it to:

weight: '500'
commented

Sigh. Longest sigh of my life. /suicide x10.

Thanks for all the helper, mind answering one more question?
Is there a way to easily add someone a prefix from two groups without doing it manually?
So I can just give someone the prefix from builder and helper rank so it would look like:
[Builder] [Helper] Loonyy

commented

That, unfortunately, would be entirely up to whatever chat management plugin you use.

Personally, I've always stayed away from double and long prefixes displayed in-game because they clutter up chat too much, so I'm not 100% sure on how to do it. I know others have done it, but I don't know how and haven't done it myself.

commented

My Prefix/Suffix Guide only details setting up one prefix.

commented

Yeah me too, it's only for double staff members (Helper and Builder) - although I might use suffix instead.

Thanks for all your help :)

commented

You're welcome. :) Have fun.