Closed Nerus87 closed 3 years ago
How to use this native to get stats from DB when player -> OnClientPostAdminCheck?
/** * Gets detailed statistics about the client. * * @param iClient Client index. * @param StatsType Type data. * @param bSession Output data from session. * * @return Data value. */ native int LR_GetClientInfo(int iClient, LR_StatsType StatsType, bool bSession = false);
Example usage:
player.Rank = LR_GetClientInfo(player.Index, ST_RANK); float kills = float(LR_GetClientInfo(player.Index, ST_KILLS)); float deaths = float(LR_GetClientInfo(player.Index, ST_DEATHS));
Example - https://github.com/levelsranks/levels-ranks-modules/blob/master/%5BLevels%20Ranks%5D%20Module%20-%20ExStats%20Maps/addons/sourcemod/scripting/levelsranks_exstats_maps.sp#L61
How to use this native to get stats from DB when player -> OnClientPostAdminCheck?
Example usage: