Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2017
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.46 KB | None | 0 0
  1. local url = "https://example.org/update.php"
  2.  
  3. local function sendUsers()
  4.     local users = {}
  5.     for steamid, data in pairs( ULib.ucl.users ) do
  6.         users[ util.SteamIDTo64( steamid ) ] = data.group
  7.     end
  8.     http.Post(url, { data=util.TableToJSON( users ) })
  9. end
  10.  
  11. local hooks = {
  12.     ULib.HOOK_GROUP_RENAMED,
  13.     ULib.HOOK_USER_GROUP_CHANGE,
  14.     ULib.HOOK_USER_REMOVED
  15. }
  16. for i=1, #hooks do
  17.     hook.Add( hooks[i], "loadingscreen", sendUsers )
  18. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement