Author Topic: showing group in players tab  (Read 4144 times)

0 Members and 1 Guest are viewing this topic.

Offline jay209015

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 934
  • Karma: 62
    • Dev-Solutions
showing group in players tab
« on: July 28, 2007, 01:41:27 AM »
Most Ulx servers I've been to have it so that when you press tab it shows what group your in, and is it possible to change the background color of you name on the players menu too ex: superadmins green. Also I would like to know how to add more ratings. Ty
An error only becomes a mistake when you refuse to correct it. --JFK

"And thus the downfall of the great ULX dynasty was wrought not by another dynasty, but the slow and steady deterioration of the leaders themselves, followed by the deprecation of the great knowledge they possessed." -Gmod, Chapter 28, verse 34 -- Stickly

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: showing group in players tab
« Reply #1 on: July 28, 2007, 10:56:15 AM »
Search for sui_scoreboard on facepunch.
Experiencing God's grace one day at a time.

Offline jay209015

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 934
  • Karma: 62
    • Dev-Solutions
Re: showing group in players tab
« Reply #2 on: July 28, 2007, 04:26:11 PM »
Wow, Thank you. I just wanted to let the administration know that this is the best and most responsive help forums. Thanks again.
An error only becomes a mistake when you refuse to correct it. --JFK

"And thus the downfall of the great ULX dynasty was wrought not by another dynasty, but the slow and steady deterioration of the leaders themselves, followed by the deprecation of the great knowledge they possessed." -Gmod, Chapter 28, verse 34 -- Stickly

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: showing group in players tab
« Reply #3 on: July 28, 2007, 07:21:39 PM »
Thanks jay.
I'll have to keep your post saved for the next time someone asks a question we've already answered many times, we answer in one sentence, and they get upset because we weren't helpful.

You're actually one of few question askers that seem to research your question first, and then when not finding the answer, ask in a clear detailed manner.

We grow tired of the "it doesn't work! I (insert one thing they think they did correctly but with no detail here), and it doesn't work!!"

We appreciate our hobby much better with those who use thier intelligence.

Thank you again.
« Last Edit: July 28, 2007, 07:23:53 PM by JamminR »
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline jay209015

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 934
  • Karma: 62
    • Dev-Solutions
Re: showing group in players tab
« Reply #4 on: July 28, 2007, 07:42:34 PM »
N/P, But now I have another question and didn't feel like I needed to open another topic. I've Created a group here

Code: [Select]
"out"
{
"Respected"
{
"allow"
{
"1" "ulx jail"
"2" "ulx unjail"
}
"deny"
{
"1" "ulx cexec"
}
}
}
Users.txt here
Code: [Select]
"out"
{
"Users"
{
"superadmin"
{
"Jay209015" "STEAM_0:1:1363076"
"TriTon->" "STEAM_0:0:6021248"
"CryWolf" "STEAM_0:0:11353240"
}

"Respected"
{
"[CB] Mr. Random" "STEAM_0:0:11449735"
"empty"    "steam"
}
}
}

<root>/data/ulib/users.txt here

Code: [Select]
"Out"
{
"Jay209015"
{
"id" "STEAM_0:1:13630765"
"type" "steamid"
"groups"
{
"1" "superadmin"
"2" "immunity"
}
}
"[CB] Mr. Random"
{
"type" "steamid"
"groups"
{
"1" "Respected"
}
"id" "STEAM_0:0:11449735"
}
}

BTW I know TriTon and crywolf aren't on there I just removed them for debugging.

Status:
Code: [Select]
# userid name uniqueid connected ping loss state adr
#  8 "Jay209015" STEAM_0:1:13630765  1:26:57 33 0 active 74.193.56.197:27006
# 15 "[CB] Mr. Random" STEAM_0:0:11449735 08:03 120 0 active 71.198.229.3:43621
# 14 "Templeton60" STEAM_0:0:15637241 09:14 117 0 active 71.198.229.3:43623
# 16 "[SGS]     CP-DUTY-8034" STEAM_0:1:4202138 02:31 133 0 active 67.160.153.177:27005
Ulx Who:
Code: [Select]

] ulx who
Userid   Name   Level   Immune
1      Jay209015   Superadmin   yes
2      [CB] Mr. Random   Guest   no
3      Templeton60   Guest   no
4      [SGS]     CP-DUTY-8034   Guest   no

I don't understand why My Respected group isn't working.

BTW if you need more information I'll post it but I felt this post was long enough. Ty

An error only becomes a mistake when you refuse to correct it. --JFK

"And thus the downfall of the great ULX dynasty was wrought not by another dynasty, but the slow and steady deterioration of the leaders themselves, followed by the deprecation of the great knowledge they possessed." -Gmod, Chapter 28, verse 34 -- Stickly

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: showing group in players tab
« Reply #5 on: July 28, 2007, 08:12:03 PM »
Is that middle users.txt from /settings/users.txt?

If it is, my default /settings/users.txt doesn't have
Code: [Select]
"Out"
{
 blah
}

It has
Code: [Select]
"Users"
{
    "group_name"
      {
          "name"    "steamid"
      }
    "group_name_2"
      {
          "name"    "steamid"
      }

}

I know our format.txt states to use the OUT entry, but, I'm pretty sure thats for custom table store files, not Garry's default files. the /settings/users.txt is one of Garry's. We just read it and import it to try to make things easy.

Hope that fixes it for you.
I'll have to find my thinking cap if that doesn't work
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline spbogie

  • Ulysses Team Member
  • Sr. Member
  • *****
  • Posts: 456
  • Karma: 41
Re: showing group in players tab
« Reply #6 on: July 28, 2007, 08:23:45 PM »
Are you sure he is not getting his access. "ulx who" only reports back for SuperAdmin, Admin, and Opperator. Please give the output of "lua_run PrintTable( ULib.ucl )" from the server console while he is on the server. (If you need help with copying from the server console see the FAQ.)
I have not failed. I've just found 10,000 ways that won't work. - Thomas A. Edison
I reject your reality and substitute my own. - Adam Savage

Offline jay209015

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 934
  • Karma: 62
    • Dev-Solutions
Re: showing group in players tab
« Reply #7 on: July 28, 2007, 09:21:48 PM »
Code: [Select]
> PrintTable( ULib.ucl )...
initClient = function: 0251BD68
passTimeout = function: 0251BD08
checkPass = function: 0251BCD8
checkAuth = function: 0251BCF0
callbacks:
1 = function: 0251BD68
2 = function: 0251C5F0
3 = function: 0290BC90
addGroup = function: 0251BC78
addUser = function: 0251BC90
awaitingauth:
addAccessCallback = function: 0251BAE0
authed:
Player [1][TriTon->]:
deny:
type = steamid
groups:
1 = user
1 = superadmin
2 = immunity
account = triton->
id = STEAM_0:0:6021248
allow:
uniqueid = 1758816892
Player [2][[CB] Mr. Random]:
deny:
type = steamid
groups:
1 = user
1 = Respected
account = [cb] mr. random
id = STEAM_0:0:11449735
allow:
uniqueid = 848711622
users:
jay209015:
deny:
type = steamid
groups:
1 = superadmin
2 = immunity
id = STEAM_0:1:13630765
pass =
allow:
crywolf:
deny:
type = steamid
groups:
1 = superadmin
2 = immunity
id = STEAM_0:0:11353240
pass =
allow:
triton->:
deny:
type = steamid
groups:
1 = superadmin
2 = immunity
id = STEAM_0:0:6021248
pass =
allow:
[cb] mr. random:
deny:
type = steamid
groups:
1 = Respected
id = STEAM_0:0:11449735
pass =
allow:
query = function: 0251BA80
removeUser = function: 0251BCA8
probe = function: 0251BCC0
groups:
respected:
allow:
1 = ulx jail
2 = ulx unjail
deny:
1 = ulx cexec
superadmin:
allow:
deny:
Respected:
allow:
deny:
immunity:
allow:
deny:
callCallbacks = function: 0251BAC8

There's the code you asked for
An error only becomes a mistake when you refuse to correct it. --JFK

"And thus the downfall of the great ULX dynasty was wrought not by another dynasty, but the slow and steady deterioration of the leaders themselves, followed by the deprecation of the great knowledge they possessed." -Gmod, Chapter 28, verse 34 -- Stickly

Offline spbogie

  • Ulysses Team Member
  • Sr. Member
  • *****
  • Posts: 456
  • Karma: 41
Re: showing group in players tab
« Reply #8 on: July 29, 2007, 07:24:18 AM »
Ah, yep. As I thought. Groups are case-sensitive, and in the current version where we use Garry's import methods it won't maintain the case for keys ( the part where you name the group). Change Respected to respected in both your groups and users file and you should be good.

Megiddo, why did we not make groups not case-sensitive? I know they are keys in a table but why don't we call string.lower on all of them?
I have not failed. I've just found 10,000 ways that won't work. - Thomas A. Edison
I reject your reality and substitute my own. - Adam Savage

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: showing group in players tab
« Reply #9 on: July 29, 2007, 12:57:18 PM »
Megiddo, why did we not make groups not case-sensitive? I know they are keys in a table but why don't we call string.lower on all of them?

Never really thought about it. Go ahead and make this change if you want. :)
Experiencing God's grace one day at a time.

Offline jay209015

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 934
  • Karma: 62
    • Dev-Solutions
Re: showing group in players tab
« Reply #10 on: July 29, 2007, 04:01:29 PM »
Oh ok, Thanks that fixed it. I saw the same thing when I posted that code and I was confused at why they were different. Thanks again.
An error only becomes a mistake when you refuse to correct it. --JFK

"And thus the downfall of the great ULX dynasty was wrought not by another dynasty, but the slow and steady deterioration of the leaders themselves, followed by the deprecation of the great knowledge they possessed." -Gmod, Chapter 28, verse 34 -- Stickly