Author Topic: ~[ULX EXPERIENCED PLEASE]~ ulib group data read  (Read 1497 times)

0 Members and 1 Guest are viewing this topic.

Offline Bite That Apple

  • Hero Member
  • *****
  • Posts: 858
  • Karma: 416
  • Apple Innovations 2010®
    • Fun 4 Everyone Gaming
~[ULX EXPERIENCED PLEASE]~ ulib group data read
« on: December 19, 2014, 03:20:12 PM »
To be honest, I'm not sure if anyone can help me on this. I'm not going to try to spend 6111484 years looking for the answer myself, and maybe more experienced players with ulib can assist me, or maybe ULIB team themselves.

I'm looking for the hook or code that ulib uses to group the players data from data/users.txt. Sadly, ulx is still not using SQL, so I can't do this the easiest way, but I'm just looking for the code to properly get a players rank. Also looking for the code to get data/groups.txt and find the usergroups colors..
Quote from: John F. Kennedy 1963
A man may die, nations may rise and fall, but an idea lives on.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: ~[ULX EXPERIENCED PLEASE]~ ulib group data read
« Reply #1 on: December 19, 2014, 10:28:05 PM »
Player:GetUserGroup

The vars for group colors are passed to client from uteam.lua using umsg.
group_data.color.<r|b|g> or a default.
Becomes team data colors.
See https://github.com/Nayruden/Ulysses/blob/master/ulx/lua/ulx/modules/uteam.lua for server and https://github.com/Nayruden/Ulysses/blob/master/ulx/lua/ulx/modules/cl/uteam.lua
(Both are reasonably small files/code functions.)
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming