10.10.2012, 11:42
Hello,
I want to do if the name of player is "Magnum" so he can do this command.
Thank you
I want to do if the name of player is "Magnum" so he can do this command.
Thank you
CMD:blah(playerid, params[])
{
new playername[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername, MAX_PLAYER_NAME);
if(strcmp("Magnum", playername, 1)) return SendClientMessage(playerid, -1, "You're not magnum");
//your code...
}
pawn Код:
https://sampwiki.blast.hk/wiki/Strcmp |
CMD:blah(playerid, params[])
{
new pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
if (strcmp("Magnum", pName)) return SendClientMessage(playerid, 0xAFAFAFAA, "* You aren't allowed to use this command.");
//The rest of your command here ;)
}