VehicleName error
#1

Hello again guys ! I just downloaded a gamemode and i try to compile it , but i get these errors ! :
pawn Код:
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\RO.pwn(1347) : error 017: undefined symbol "VehicleName"
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\RO.pwn(1347) : warning 215: expression has no effect
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\RO.pwn(1347) : error 001: expected token: ";", but found "]"
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\RO.pwn(1347) : error 029: invalid expression, assumed zero
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\RO.pwn(1347) : fatal error 107: too many error messages on one line
Line 1347 :
pawn Код:
format(string, sizeof(string), "Acum tu tractezi un %s",VehicleName[GetVehicleModel(GetPlayerVehicleID(playerid))-400]);
Help ? Thanks
Reply
#2

You are missing the VehicleName array. If it exists in your script, it's on the wrong level.
To avoid this problem, put that array before Any public functions or stocks.
Reply
#3

Umm .. what you mean is that , the VehicleName array is missing ?In script , that array dosen't exist.
Reply
#4

Press Ctrl + F and type on the box "VehicleName" (without " ") and see if you have any variable.
Reply
#5

Soo .. can someone , make me that command ? , Actual Command :
pawn Код:
if ( strcmp ( cmdtext , "/tow", true)==0){

    new Float:pX,Float:pY,Float:pZ;
    GetPlayerPos(playerid,pX,pY,pZ);
    new Float:vX,Float:vY,Float:vZ;
    new Found=0;
    new vid=0;
    while((vid<MAX_VEHICLES)&&(!Found))
    {
    vid++;
    GetVehiclePos(vid,vX,vY,vZ);
    if  ((floatabs(pX-vX)<7.0)&&(floatabs(pY-vY)<7.0)&&(floatabs(pZ-vZ)<7.0)&&(vid!=GetPlayerVehicleID(playerid)))
    {
    Found=1;
    if(IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid)))
    {
    DetachTrailerFromVehicle(GetPlayerVehicleID(playerid));
    SendClientMessage(playerid,0xFFFF00AA,"Ai deatasat masina");
    }else
    {
    AttachTrailerToVehicle(vid,GetPlayerVehicleID(playerid));
    format(string, sizeof(string), "Acum tu tractezi un %s",VehicleName[GetVehicleModel(GetPlayerVehicleID(playerid))-400]);
    SendClientMessageToAll(0xFFFF00AA, string);
    }
    }
    }
    if  (!Found)
    {
    SendClientMessage(playerid,0xFFFF00AA,"Nu am gasit nici un vehicul,mergeti mai aproape de masina.");
    }
    return 1;
    }
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)