Author Topic: ULX kick/ban reasons  (Read 3809 times)

0 Members and 2 Guests are viewing this topic.

Offline Avoid

  • Full Member
  • ***
  • Posts: 142
  • Karma: 42
ULX kick/ban reasons
« on: November 09, 2014, 06:01:57 AM »
Hello there,
I have a quick question about the ulx kick/ban reasons.
For me, as a superadmin I get to have the following menu, where I can open a dropdown list with reasons: Dropbox-Link

But my moderators cannot see this menu, so where exactly is this permission set? Do I have to restrict the kick/ban reason string?

P.S.: Yes, I know there are two entries for AFK! :P

Thanks,
Avoid

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: ULX kick/ban reasons
« Reply #1 on: November 09, 2014, 06:39:30 AM »
I did a quick look through the permissions, and didn't find anything specifically for kick/ban reasons.
Have you (or your moderators) tried using "ulx ban" in console and seeing if the autocomplete works there too?
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline Avoid

  • Full Member
  • ***
  • Posts: 142
  • Karma: 42
Re: ULX kick/ban reasons
« Reply #2 on: November 09, 2014, 06:44:31 AM »
I did a quick look through the permissions, and didn't find anything specifically for kick/ban reasons.
Have you (or your moderators) tried using "ulx ban" in console and seeing if the autocomplete works there too?

Yes, they only get to type the {reason} string, autocomplete with the pre-set reasons do not work for them, but for me!
I removed ulx ban, as I do prefer using sourcebans for banning.

EDIT:
When I restrict the string argument to the reasons they get the dropdown menu, but of course typing any string is restricted, so they can only select the whitelisted strings, of course.
« Last Edit: November 09, 2014, 06:54:49 AM by Avoid »

Offline Stickly Man!

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 1270
  • Karma: 164
  • What even IS software anymore?
    • XGUI
Re: ULX kick/ban reasons
« Reply #3 on: November 10, 2014, 09:56:16 AM »
I'm curious- it's likely ULX is only sending those reasons if you have access to "ulx ban" as well. Do your other admins only have access to "ulx kick"?
Join our Team Ulysses community discord! https://discord.gg/gR4Uye6

Offline Avoid

  • Full Member
  • ***
  • Posts: 142
  • Karma: 42
Re: ULX kick/ban reasons
« Reply #4 on: November 10, 2014, 10:24:33 AM »
I'm curious- it's likely ULX is only sending those reasons if you have access to "ulx ban" as well. Do your other admins only have access to "ulx kick"?
Yes, they do have access to ulx kick, but I removed everyones permission from ulx ban, as we use the sourcebans module instead.
Any way fixing this without granting them access to ulx ban?

EDIT:
So I found those two addDataType( "banreasons" ...) and common_kick_reasons, where exactly does it rely on ulx ban permissions?

Avoid
« Last Edit: November 10, 2014, 10:35:55 AM by Avoid »

Offline Bryantdl7

  • Jr. Member
  • **
  • Posts: 86
  • Karma: -2
Re: ULX kick/ban reasons
« Reply #5 on: November 12, 2014, 08:13:44 AM »
If you go to the group tab, click on say 'mod' click permissions and then click ulx kick it should say restrict reasons in the bottom ish right of xgui



Offline Avoid

  • Full Member
  • ***
  • Posts: 142
  • Karma: 42
Re: ULX kick/ban reasons
« Reply #6 on: November 12, 2014, 09:16:20 AM »
If you go to the group tab, click on say 'mod' click permissions and then click ulx kick it should say restrict reasons in the bottom ish right of xgui
You didn't read properly:
When I restrict the string argument to the reasons they get the dropdown menu, but of course typing any string is restricted, so they can only select the whitelisted strings, of course.

Offline Bryantdl7

  • Jr. Member
  • **
  • Posts: 86
  • Karma: -2
Re: ULX kick/ban reasons
« Reply #7 on: November 12, 2014, 09:29:33 AM »
I'm pretty sure that's exactly what I understood. Maybe I'm missing something. If you have reasons whitelisted they are the only options available.



Offline Stickly Man!

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 1270
  • Karma: 164
  • What even IS software anymore?
    • XGUI
Re: ULX kick/ban reasons
« Reply #8 on: November 15, 2014, 11:51:55 AM »
Hmm, that is interesting. I've noticed that ULX sends them on PlayerInit and on UCLAuth:
https://github.com/Nayruden/Ulysses/blob/master/ulx/lua/ulx/base.lua#L79

But XGUI will only update them if they have access to ULX ban:
https://github.com/Nayruden/Ulysses/blob/master/ulx/lua/ulx/xgui/server/sv_settings.lua#L11

Theoretically, this should be fine- ULX should send the autocompletes needed for players that don't have access. Either way, you can try having XGUI send them to anyone regardless of their permissions by changing "ulx ban" to nil on the sv_settings.lua line #11, and see if that fixes the problem.
Join our Team Ulysses community discord! https://discord.gg/gR4Uye6

Offline Avoid

  • Full Member
  • ***
  • Posts: 142
  • Karma: 42
Re: ULX kick/ban reasons
« Reply #9 on: November 15, 2014, 05:00:10 PM »
Thank you Stickly Man,
that was exactly the line I was looking for! :)