Hello need help with giverespect cmd..
#1

Hello dear samp forum members.


So i want to let people use this cmd every one hour so it wouldn't be abused..

Here is the cmd and errors:

Errors
pawn Код:
error 001: expected token: ";", but found "-identifier-"
error 035: argument type mismatch (argument 1)
error 035: argument type mismatch (argument 1)
error 001: expected token: ")", but found ";"
error 036: empty statement
CODE:
pawn Код:
CMD:giverespect(playerid, params[])
{
    if(!IsPlayerLoggedIn(playerid)) return SendClientMessage(playerid, COLOR_GREY, "You need to login first before using any command.");
    if(CanUseCmd[playerid] == true)
    {
        new id, playerb[32], string[128];
        if(sscanf(params, "r", id)) return SendClientMessage(playerid, 0xCC0000AA, "USAGE: /respect <playerid/partofname>");
        PlayerInfo[playerid][pStreetRespect] ++
        PlayerInfo[playerid][pCMDT] = gettime();//error 001: expected token: ";", but found "-identifier-"
        if((gettime() - PlayerInfo[playerid][pCMDT]) < 3600000)
        CanUseCmd[playerid] = false;
        format(string, sizeof(string), " You have gived Street Respect to %s.", NORPN(playerb));//error 035: argument type mismatch (argument 1)
        SendClientMessage(playerid, COLOR_WHITE, string);
        format(string, sizeof(string), " Player %s has gived you Street Respect to you.", NORPN(playerid));
        SendClientMessage(playerb, COLOR_WHITE, string);//  error 035: argument type mismatch (argument 1)
    }
    else if(PlayerInfo[playerid][pCMDT] < gettime(); //here last two errors...
    {
        CanUseCmd[playerid] = true;
    }
    return 1;
}
With best regards Scrillex.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)