NEED ERGENT HELP PLEASE
#2

Just put

pawn Код:
ManualVehicleEngineAndLights();
in Gamemodeinit for turning the engines and lights manually and on OnPlayerStateChange you cna put the following so it will automatically starts the engine once it checks if you are in a right vehicle id (your car group).

pawn Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
    if(oldstate == PLAYER_STATE_ONFOOT && newstate == PLAYER_STATE_DRIVER) // Player entered a vehicle as a driver
    {
        if( YOUR_CARGROUP_VAR ) // might be a bool or maybe your own global var but replace it with yours.
        {
            new vehicleid, engine, lights, alarm, doors, bonnet, boot, objective;
            vehicleid = GetPlayerVehicleID( playerid );
            GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
            SetVehicleParamsEx(vehicleid, 1, lights, alarm, doors, bonnet, boot, objective);
        }
    }
    return 1;
}
Reply


Messages In This Thread
NEED ERGENT HELP PLEASE - by Geniuss - 04.06.2012, 02:00
Re: NEED ERGENT HELP PLEASE - by FalconX - 04.06.2012, 02:05
Re: NEED ERGENT HELP PLEASE - by Geniuss - 04.06.2012, 02:08
Re: NEED ERGENT HELP PLEASE - by FalconX - 04.06.2012, 02:13

Forum Jump:


Users browsing this thread: 1 Guest(s)