ULX

Author Topic: Several Help Questions -- Help!  (Read 1947 times)

0 Members and 2 Guests are viewing this topic.

Offline locololo2

  • Newbie
  • *
  • Posts: 12
  • Karma: 0
Several Help Questions -- Help!
« on: September 17, 2008, 01:21:50 PM »
Okay several things I need checked out.

1. How do I remove permanent ban from some players? I want to be able to limit it to 7days tops.
2. How do I make a welcome message that only superadmins get but for everyone? When a server admin joins it says in their chat, "Welcome back "name", you are a superadmin in this server." (I want to be able to set that for all of my admin groups.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: Several Help Questions -- Help!
« Reply #1 on: September 17, 2008, 06:25:19 PM »
1) ULX has no way to limit the ban command to different groups. They either have ban access, or they don't.
You could use rcon access as a superadmin and set permanently if you wish after someone is banned 7 days.
Find in /addons/ulx/modules/util.lua the function named "ulx.cc_ban"
Find the following lines
Code: [Select]
local time = "for " .. bantime .. " minute(s)"
if bantime == 0 then time = "permanently" end
Change them to
Code: [Select]
local time = "for " .. bantime .. " minute(s)"
if bantime == 0 or 10800 then time, bantime = "one week", 10800 end
and a few lines down from that change
Code: [Select]
ulx.addToMenu( ulx.ID_MCLIENT, "Ban (perma)", "ulx ban #T 0" )
to
Code: [Select]
ulx.addToMenu( ulx.ID_MCLIENT, "Ban (one week)", "ulx ban #T 10800" )

2) That message your seeing is most likely from the permissions list in gmod/settings/users.txt, not ULX.
Gmod by default does superadmins and admins. Not sure any other groups are checked by default.
You may test by adding an individual to a newly created group in gmod/settings/users.txt
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming