08.06.2016, 15:10
Can i make this cmd check if the player name is example Red_John and if it is let him use it.Only him!
PHP код:
COMMAND:glazba(playerid,params[])
{
if (APlayerData[playerid][LoggedIn] == true && APlayerData[playerid][PlayerLevel] > 4)
{
new Link[128];
if(sscanf(params, "s[128]", Link)) return SendClientMessage(playerid, 0xFF0000FF, "{FF0000}Komanda:{FF0000} {FFFFFF}/Glazba <Link> {FFFFFF}");
for (new i=0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && !IsPlayerNPC(i)){
PlayAudioStreamForPlayer(i, Link);
}
}
return 1;
}
return 0;
}