simple engine command.
#4

Quote:
Originally Posted by Pharrel
Посмотреть сообщение
pawn Код:
//ongamemodeinit
ManualVehicleEngineAndLights();


CMD:engine(playerid)//or if(!strcmp(cmd, "/engine", true))
{
    new engine, lights, alarm, doors, bonnet, boot, objective;
    GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
    if(engine == 1)
        SetVehicleParamsEx(vehicleid, 0, lights, alarm, doors, bonnet, boot, objective);
    else SetVehicleParamsEx(vehicleid, 1, lights, alarm, doors, bonnet, boot, objective);
}
Hey thanks man.. It helped to me too a lot..
but can you please or someone else just expalin what each of this big mess saying?
thanks


Quote:
Originally Posted by Jordiee
Посмотреть сообщение
Код:
C:\Users\Jordan\Desktop\Windows\gamemodes\vx-rp.pwn(542) : warning 217: loose indentation
C:\Users\Jordan\Desktop\Windows\gamemodes\vx-rp.pwn(14894) : error 017: undefined symbol "vehicleid"
C:\Users\Jordan\Desktop\Windows\gamemodes\vx-rp.pwn(14896) : error 017: undefined symbol "vehicleid"
C:\Users\Jordan\Desktop\Windows\gamemodes\vx-rp.pwn(14897) : error 017: undefined symbol "vehicleid"
C:\Users\Jordan\Desktop\Windows\gamemodes\vx-rp.pwn(14899) : error 010: invalid function or declaration
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Just do this:

pawn Код:
if(!strcmp(cmd, "/engine", true))
    {
        new vehicleid = GetPlayerVehicleID(playerid);
        new engine, lights, alarm, doors, bonnet, boot, objective;
        GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
        if(engine == 1)
        SetVehicleParamsEx(vehicleid, 0, lights, alarm, doors, bonnet, boot, objective);
        else SetVehicleParamsEx(vehicleid, 1, lights, alarm, doors, bonnet, boot, objective);
    }
Reply


Messages In This Thread
simple engine command. - by Jordiee - 15.11.2011, 16:12
Re: simple engine command. - by Pharrel - 15.11.2011, 16:16
Re: simple engine command. - by Jordiee - 15.11.2011, 16:26
Re: simple engine command. - by Qur - 15.11.2011, 16:27
Re: simple engine command. - by Jordiee - 15.11.2011, 16:29
Re: simple engine command. - by Pharrel - 15.11.2011, 16:32
Re: simple engine command. - by Jordiee - 15.11.2011, 16:35
Re: simple engine command. - by park4bmx - 15.11.2011, 16:35
Re: simple engine command. - by Jordiee - 15.11.2011, 16:37
Re: simple engine command. - by Devilxz97 - 12.05.2012, 14:16

Forum Jump:


Users browsing this thread: 1 Guest(s)