/crash command
#3

I get 2 errors
pawn Code:
C:\Users\Ryan\Desktop\World Wide RolePlay\gamemodes\WWRP.pwn(31946) : error 001: expected token: ";", but found "new"
C:\Users\Ryan\Desktop\World Wide RolePlay\gamemodes\WWRP.pwn(31946) : error 017: undefined symbol "X"


pawn Code:
if(strcmp(cmd, "/crash", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            tmp = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                SendClientMessage(playerid, COLOR_WHITE, "USAGE: /crash [playerid/PartOfName]");
                return 1;
            }
            giveplayerid = ReturnUser(tmp);
            if(PlayerInfo[playerid][pAdmin] >= 1)
            {
                if(IsPlayerConnected(giveplayerid))
                {
                    if(giveplayerid != INVALID_PLAYER_ID)
                    {

                        new Float:x, Float:y, Float:z;
                        GetPlayerPos(giveplayerid, x, y, z)
                        new objectcrash = CreatePlayerObject(giveplayerid,11111111,X,Y,Z,0,0,0);
                        DestroyObject(objectcrash);
                    }
                }
                else
                {
                    format(string, sizeof(string), "   %d is not an active player !", giveplayerid);
                    SendClientMessage(playerid, COLOR_GRAD1, string);
                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_GRAD2, "   You are not authorized to use that command !");
            }
        }
        return 1;
    }

EDIT : i fix the frist error but now i got C:\Users\Ryan\Desktop\World Wide RolePlay\gamemodes\WWRP.pwn(31946) : error 017: undefined symbol "X"
Reply


Messages In This Thread
/crash command - by yarrum3 - 27.03.2011, 00:35
Re: /crash command - by grand.Theft.Otto - 27.03.2011, 00:38
Re: /crash command - by yarrum3 - 27.03.2011, 00:50
Re: /crash command - by grand.Theft.Otto - 27.03.2011, 00:56

Forum Jump:


Users browsing this thread: 2 Guest(s)