Command issues (ZCMD)
#1

Having issues making my /forthelulz command return /ftl. Here's the code:
pawn Код:
zcmd(forthelulz,playerid,params[])
{
    return zcmd(ftl,playerid,params[]); //line 177
}
zcmd(ftl,playerid,params[])
{
    if(HasPlayerLulzed[MAX_PLAYERS] == 0)
    {
        SetPlayerDrunkLevel(playerid,50000);
        new Float:X, Float:Y, Float:Z;
        GetPlayerVelocity(playerid,X,Y,Z);
        SetPlayerVelocity(playerid,X*1.5,Y*1.5,(Z+1)*1.5);
        SetTimer(public stoplulz,30000,false);
        new name[MAX_PLAYER_NAME];
        new string[64];
        GetPlayerName(playerid,name,sizeof(name));
        format(string,sizeof(string),"*****%s is lulzing, watch out!",name);
        SendClientMessageToAll(yellow,string);
        HasPlayerLulzed[MAX_PLAYERS] += 1;
        SetTimer(public SetHasPlayerLulzed,60000,false);
    }
    else SendClientMessage(playerid,red,"You can only lulz once every minute!");
    return 1;
}
public stoplulz(playerid)
{
    SetPlayerDrunkLevel(playerid, 0)
    SendClientMessage(playerid,lightred,"You stopped lulzing.");
}
public SetHasPlayerLulzed(playerid)
{
    HasPlayerLulzed[MAX_PLAYERS] == 1;
    return 1;
}
But it tells me that line 177 is an invalid expression and assumed zero THREE TIMES (WTF?)

I tried making the zcmds COMMAND:ftl and such, but that told me ftl was never used, along with any of my timer functions.

I also know theres lots else wrong with that code, so if someone could help me fix it up, it would go greatly appreciated
Reply


Messages In This Thread
Command issues (ZCMD) - by biltong - 11.02.2010, 18:04
Re: Command issues (ZCMD) - by Joe Staff - 11.02.2010, 18:14
Re: Command issues (ZCMD) - by biltong - 11.02.2010, 18:19

Forum Jump:


Users browsing this thread: 1 Guest(s)