0 Members and 1 Guest are viewing this topic.
local function addUser( pl, res, status, err ) pl:ChatPrint("Loading " .. pl:Nick() .. "'s account \n") print( err ) ULib.ucl.addUser( pl:Nick(), "steamid", pl:SteamID(), { res[1] } ) pl:ChatPrint("Loaded " .. pl:Nick() .. "'s rank.\n") ULib.ucl.probe( pl ) end local function LoadUsers( pl ) local steamID = pl:SteamID() ULib.ucl.authed[ pl ] = nil ULib.ucl.awaitingauth[ pl ] = nil tmysql.query( "SELECT Rank FROM rank WHERE SteamID = '" .. steamID .. "'", addUser, nil, pl ) endhook.Add( "PlayerInitialSpawn", "LoadUserRank", LoadUsers )hook.Remove( "PlayerInitialSpawn", "ucl_initialspawn" )
13:40:39 Lua Error: ERROR: Hook 'LoadUserRank' Failed: [addons\ulx\lua\ulx\init.lua:79] attempt to index field 'awaitingauth' (a nil value)13:40:39 Lua Error: Removing Hook 'LoadUserRank'