PM problem
#2

pawn Код:
dcmd_pm(playerid, params[])
{
    new id, text[128], iName[MAX_PLAYER_NAME], name[MAX_PLAYER_NAME], str[128];
    if(sscanf(params, "us", id, text)) return SendClientMessage(playerid, LIGHTBLUE, "USAGE: {FFFFFF}/pm [playerid] [text]");
    if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, ORANGERED, "ERROR: {FFFFFF}Invalid PlayerID");
    GetPlayerName(id,iName,sizeof(iName));
    GetPlayerName(playerid, name,sizeof(name));
    format(str,sizeof(str),"PM sent %s (ID: %d): %s",iName,id,text);
    SendClientMessage(playerid,YELLOW,str);
    format(str,sizeof(str),"PM From %s (ID: %d): %s",name,playerid,text);
    SendClientMessage(id,ORANGE,str);
    PlayerPlaySound(id,1085,0.0,0.0,0.0);
    printf("PM Logger: %s (From: %s) (To: %s)",str, iName, name);
    return 1;
}
?
Reply


Messages In This Thread
PM problem - by Chris' - 03.03.2012, 15:04
AW: PM problem - by Drebin - 03.03.2012, 15:25
Re: PM problem - by Campbell- - 03.03.2012, 15:28
Re: PM problem - by Chris' - 03.03.2012, 15:34
Re: PM problem - by ]Rafaellos[ - 03.03.2012, 15:38
Re: PM problem - by Chris' - 03.03.2012, 15:52
Re: PM problem - by Mark™ - 03.03.2012, 15:54
Re: PM problem - by ]Rafaellos[ - 03.03.2012, 15:57
Re: PM problem - by Walsh - 03.03.2012, 15:59
Re: PM problem - by suhrab_mujeeb - 03.03.2012, 16:32

Forum Jump:


Users browsing this thread: 3 Guest(s)