02.02.2018, 09:25
This function can help you to get player ID from player name, so when you get player id you can get other infos
Код:
stock GetPlayerIDS(string[]) { new testname[MAX_PLAYER_NAME]; for(new i=0; i<MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { GetPlayerName(i, testname, sizeof(testname)); if(!strcmp(testname, string, true)) { return i; } } } return INVALID_PLAYER_ID; }