Author Topic: Problems with groups  (Read 3603 times)

0 Members and 3 Guests are viewing this topic.

Offline tryitnow

  • Newbie
  • *
  • Posts: 5
  • Karma: 0
Problems with groups
« on: April 21, 2014, 03:06:23 PM »
Hey,

like the subject says I have a few problems with my groups. In the attach you see my groups.txt. I've been working on it for about 12 hours and more and it just doesn't want to work like I want so I hope you guys can help me.
What do I want?
Owner can target everyone
Co-Owner can target everyone except Owner
Superadmin can target everyone except Co-Owner and above
Admin can target everyone except superadmin and above
Member can target everyone except Admin and Above
User can target everyone except Owner, Co-Owner, superadmin, admin Member
Monsterkill can target everyone except Admin, superadmin, Co-Owner and Owner

Will maybe add a few ranks who will be similar to Monsterkill.

What does not work?
Co-Owner can do things to everyone (to Owner, too)
Member can't do things to user.
And maybe some other things I didn't try yet.

I don't want that anyone makes my full groups.txt (would be cool but a lot of work I think^^), I just want to understand how it works and what I did wrong. Thank you in advance for your answer.

Regards,
Julian

P.S.: I'm not a native english speaker so I'm sorry if there are any (huge) mistakes.
And what didn't want to work, too, was:
Owner can add everyone to every group
Co-Owner can add everyone except Owners to every group except Owner and Co-Owner
Superadmin everyone except Co-Owners and Owners to every group except superadmin and above
Admin only user, Member and the other groups except Admins, Superadmins, Co-Owner and Owner to every group except admin and above
« Last Edit: April 21, 2014, 04:07:10 PM by tryitnow »

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Problems with groups
« Reply #1 on: April 22, 2014, 08:33:59 AM »
I don't think I'm able to help you with the adduser thing, because I'm completely blank on that part.
However, I will try to help you with the general can_target and all.
I need to ask; What does "$$member, $user" do when with the ulx votekick? I'm pretty sure you would need "#member" for it to target that group only. Also, since "Member" inherits from user, you should only need to put: "!%Member", as that will mean "group Member and below" (at least I'm pretty sure about that).
You seen to have done it right with "Monsterkill", but "user" seems to have the same thing as "Member".

Also, I recommend making all your group names lowercase. As there are multiple reports of capital letters that break the inheritance system. Heck, that can be what fixes it too:
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline tryitnow

  • Newbie
  • *
  • Posts: 5
  • Karma: 0
Re: Problems with groups
« Reply #2 on: April 22, 2014, 09:03:37 AM »
Okay, thx. The thing with $ was just a test and I forget to remove it^^
Member can votekick, users can't :P
What did you mean with
Quote
Also, since "Member" inherits from user, you should only need to put: "!%Member", as that will mean "group Member and below"
? Where should I only need to put "!%Member" (or "!%member" after I remove the capital letters)? In user cantarget? And shouldn't "!%Member" mean everything except Member and below? oO I'm very very very confused atm because I think I mixed many things up.

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Problems with groups
« Reply #3 on: April 22, 2014, 09:12:29 AM »
I put the wrong thing. "!" means not and "%" means group, so basically "!%member" means "not group 'member'" (and higher, following the inheritance tree). So basically, for both user and member, you should only need to put "!%monsterkill", as that seems to be the higher group.

Actually, I just saw that "admin" inherits from "member". It would be better to have it inherit from "monsterkill" to get the inheritance tree properly.
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline tryitnow

  • Newbie
  • *
  • Posts: 5
  • Karma: 0
Re: Problems with groups
« Reply #4 on: April 22, 2014, 09:18:08 AM »
That's because Monsterkill is a special rank. In the future I'm going to make more ranks exactly like this just with other names so I thought it's the best if the admin inherits from member :S

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Problems with groups
« Reply #5 on: April 22, 2014, 10:11:58 AM »
Alright, try this can_target for user & member: "!%monsterkill, !%admin". Then just add a comma after "!%admin" and then "!%groupname" for each group you would like to prevent in the future (unless those groups inherit from either "admin" or "monsterkill", then you won't need to).
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline tryitnow

  • Newbie
  • *
  • Posts: 5
  • Karma: 0
Re: Problems with groups
« Reply #6 on: April 22, 2014, 11:13:30 AM »
I think you understood sth wrong :P I want member and user to be able to target everyone except admin and above. I think it should work like that (attach), shouldn't it? And then every new group exactly like monsterkill just with another name.

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Problems with groups
« Reply #7 on: April 22, 2014, 11:28:49 AM »
Oh okay. Yeah, sorry, it looks good except for one thing: user's can_target is "*", which means everyone. Change that to "!%admin", and it should work fine.
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline tryitnow

  • Newbie
  • *
  • Posts: 5
  • Karma: 0
Re: Problems with groups
« Reply #8 on: April 22, 2014, 11:49:21 AM »
Thanks for your help! First I did it because I thought they can't (vote-)kick/ban but totally forgot that members can target everyone too because of the inherit, can't they?

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Problems with groups
« Reply #9 on: April 22, 2014, 11:56:59 AM »
I believe if someone inherits "user" and their can_target is something else than user's, it will override user's "everyone" target. I'm not completely sure about that though.
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.