[HELP]Can someone make for me [/pm] ?[+REP]
#3

Quote:
Originally Posted by Barnwell
Посмотреть сообщение
do this will work!

Код:
dcmd_pm(playerid, params[])
{
        if(PlayerInfo[playerid][pLevel] < 1)
            {
                SendClientMessage(playerid, COLOR_WHITE, "You need level 2 to use this");
                return 1;
            }

         if(PlayerInfo[playerid][pHelper] == 1)
            {
                SendClientMessage(playerid, TEAM_CYAN_COLOR, "you are not a helper.");
                return 1;
            }

        new pID, text[128], string[128];
        if(sscanf(params, "us", pID, text)) return SendClientMessage(playerid, COLOR_RED, "USAGE: /pm (nick/id) (message) - Enter a valid Nick / ID");
        if(!IsPlayerConnected(pID)) return SendClientMessage(playerid, COLOR_RED, "Player is not connected.");
        if(pID == playerid) return SendClientMessage(playerid, COLOR_RED, "You cannot PM yourself.");
        format(string, sizeof(string), "%s (%d) is not accepting private messages at the moment.", PlayerName(pID), pID);
        if(pInfo[pID][NoPM] == 1) return SendClientMessage(playerid, COLOR_RED, string);
        format(string, sizeof(string), "(( PM to %s: %s ))", PlayerName(pID), text);
        SendClientMessage(playerid, COLOR_YELLOW, string);
        format(string, sizeof(string), "(( PM from %s: %s ))", PlayerName(playerid), text);
        SendClientMessage(pID, COLOR_YELLOW, string);
        pInfo[pID][Last] = playerid;
        return 1;
}
That would cause me error ...
Reply


Messages In This Thread
[HELP]Can someone make for me [/pm] ?[+REP] - by EgyptForLife - 07.09.2014, 12:43
Re: [HELP]Can someone make for me [/pm] ?[+REP] - by Barnwell - 07.09.2014, 13:25
Re: [HELP]Can someone make for me [/pm] ?[+REP] - by EgyptForLife - 07.09.2014, 14:33
Re: [HELP]Can someone make for me [/pm] ?[+REP] - by SoldadoH - 07.09.2014, 14:44
Re: [HELP]Can someone make for me [/pm] ?[+REP] - by Fred1993 - 07.09.2014, 14:52

Forum Jump:


Users browsing this thread: 1 Guest(s)