/nos command, 3 errors.
#1

Hello, I have 3 errors with my cmd /nos. I tried writing this from scratch, but obviously something went wrong.
pawn Код:
Dangerous TDM V0.2\gamemodes\ExplosionDMV0.2.pwn(345) : error 033: array must be indexed (variable "carid")
Dangerous TDM V0.2\gamemodes\ExplosionDMV0.2.pwn(346) : error 033: array must be indexed (variable "carid")
Dangerous TDM V0.2\gamemodes\ExplosionDMV0.2.pwn(350) : error 035: argument type mismatch (argument 1)
Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase
These are my errors, I tried solving these but couldn't do it. I am adding my CMD -
pawn Код:
CMD:nos(playerid, params[])
{
    new carid[32];
    carid = GetPlayerVehicleID(playerid); // LINE 345
    if(carid < 0) // LINE 346
    {
    SendClientMessage(playerid, COL_BRIGHTRED, "ERROR: Sa ei ole autos sees!");
    }else{
    AddVehicleComponent(carid, 1010); // LINE 350
    }
    return 1;
}
Reply
#2

pawn Код:
CMD:nos(playerid, params[])
{
    new carid;
    carid = GetPlayerVehicleID(playerid);
    if(carid < 0)
    {
        SendClientMessage(playerid, COL_BRIGHTRED, "ERROR: Sa ei ole autos sees!");
    }
    else
    {
        AddVehicleComponent(carid, 1010);
    }
    return 1;
}
it should be an integer
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)