|
Veteran Member
|
01-24-2020
, 15:52
Re: [CS:GO] get m_nPersonaDataPublicLevel value
|
#3
|
Quote:
Originally Posted by DarkDeviL
If you join the server, but only select the spectator team (so you're never getting alive)? Is the "Command_SteamLvl" working as expected that way too?
Or do you have to wait until you have spawned (been alive at least once) before your "Command_SteamLvl" works fine?
As OnClientPostAdminCheck does not provide the information you want at that stage, I suggest trying player_spawn:
You can then create a global variable, e.g. "g_bHasPlayerBeenSpawned", and at the time you check the player and handle him/her accordingly, if (s)he fits the criteria to stay, set "g_bHasPlayerBeenSpawned" to TRUE, to prevent further scans.
And then remember to unset / set to FALSE again in OnClientDisconnect for the relevant client index.
If OnClientPostAdminCheck is "too soon" to check for this prop, as it appears according to your explanation, the player_spawn may be the earliest / best shot, and then add the use of the boolean variable from the beginning and/or if you experience performance issues due to the check at each spawn.
|
player_spawn can take 5 minutes from connection. player_team is the best shot in my opinion.
__________________
I am available to make plugins for pay.
Discord: Eyal282#1334
|
|
|
|