24.08.2016, 19:54
Hi,
If want if string is number then no search by name, instantly retunr that number if player connected
Код:
SSCANF:playername(string[])
{
new
name[MAX_PLAYER_NAME];
foreach (new playerid : Player)
{
GetPlayerName(playerid, name, sizeof (name));
//if (!strcmp(name, string, true)) // Exact match.
if (strfind(name, string, true) != -1) // Far less accurate.
{
return playerid;
}
}
return INVALID_PLAYER_ID;
}


