[Help] Zcmd problem
#1

hi guys,

i making my gm e appers the bug: the OnPlayerCommandPerformed don't return false!

pawn Код:
public OnPlayerCommandPerformed(playerid, cmdtext[], success)
{
    if(!success)
    {
        SendClientMessage(playerid,-1, "This command do not exist's, use /ajuda");
        return true;
    }
    if(IsPlayerFlooding(SpamTime[playerid], 5000))
    {
        SendClientMessage(playerid, 0xAA3333AA,"[ERROR]: Pleaze, don't make spam... ( 5 seconds )");
        return 0;
    }
    SpamTime[playerid] = GetTickCount();
    return 1;
}
stock IsPlayerFlooding(varflod, time)
{
    if(GetTickCount() - varflod < time) return true;
    return 0;
}

thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)