29.04.2011, 22:17
ok folks because i forget alot of stuff due to being old i made this cmd ages ago and it didnt work, then i forgot all about it, so i will know throw it open to someone to help me out please,its probally something realy easy,but my brain doesnt work at the moment 
cheers for your help in advance

Код:
CMD:doughnut(playerid,params[]) {
new giveplayerid,string[128],giveplayer[MAX_PLAYER_NAME],sendername[MAX_PLAYER_NAME];
if (sscanf(params, "u", giveplayerid)) return SendClientMessage(playerid, COLOR_LIGHTBLUE, "USAGE: /doughnut <ID> ");
if(PlayerInfo[playerid][Jailed] == 1) {
SendClientMessage(playerid, COLOR_BRIGHTRED, "You are in jail and cannot use this command");
return 1;}
if (IsPlayerConnected(giveplayerid)){
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "%s has given %s a doughnut,hope he doesnt leave crumbs every where", sendername, giveplayer);
SendClientMessageToAll(COLOR_INDIGO, string);
return 1;}
else{
format(string, sizeof(string), "ID:%d is not an active player ID number.", giveplayerid);
SendClientMessage(playerid, COLOR_BRIGHTRED, string);}
return 1;}

