PM help-
#6

In your code you save targetid as "u", it can be a name so no "targetid = INVALID_PLAYER_ID" nor IsPlayerConnected(targetid) can slove it maybe in your sscanf version, "u" works fine with me but try to change "u" to "d"

PHP Code:
CMD:pm(playeridparams[])
{
    new 
targetidstring[258], tekst[128];
    if(
sscanf(params"ds[128]"targetidtekst)) return SendClientMessage(playeridCOLOR_WHITE"{3BB9FF}use: {FFFFFF}/pm  < ID > < tekst >");
    if(
targetid == INVALID_PLAYER_ID) return SendClientMessage(playeridCOLOR_RED"Wrong ID");
    
format(stringsizeof(string), "[PM][IN] %s: %s"PlayerName(playerid), tekst);
    
SendClientMessage(targetidCOLOR_YELLOWstring);
    
format(stringsizeof(string), "[PM][out] %s: %s"PlayerName(targetid), tekst);
    
SendClientMessage(playeridCOLOR_REDstring);
    return 
1;

Reply


Messages In This Thread
PM help- - by b0b - 02.08.2016, 14:32
Re: PM help- - by J0sh... - 02.08.2016, 14:32
Re: PM help- - by SyS - 02.08.2016, 14:33
Re: PM help- - by F1N4L - 02.08.2016, 14:34
Re: PM help- - by b0b - 02.08.2016, 14:39
Re: PM help- - by Shinja - 02.08.2016, 18:34
Re: PM help- - by Stinged - 02.08.2016, 18:35
Re: PM help- - by Shinja - 02.08.2016, 18:37
Re: PM help- - by Fantje - 02.08.2016, 20:11
Re: PM help- - by AlexPalermitano97 - 03.08.2016, 01:18

Forum Jump:


Users browsing this thread: 2 Guest(s)