About vehicle damage
#4

Quote:
Originally Posted by Mike_Peterson
Посмотреть сообщение
This is what i found after 20 second of googling
Use a timer that repeats by the way,

pawn Код:
forward carhealthcheck();
public carhealthcheck()
{
    new Float:vhp;
    for(new vehicleid; vehicleid<MAX_VEHICLES;vehicleid++)
    {
        if(GetVehicleModel(vehicleid)==0)continue;
        GetVehicleHealth(vehicleid,vhp);
        if(vhp<500.0)
        {
            SetVehicleHealth(vehicleid,350)
            new engine,lights,alarm,doors,bonnet,boot,objective;
            GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
            SetVehicleParamsEx(vehicleid,0,lights,alarm,doors,bonnet,boot,objective);
        }
    }
}
Recommended timer? cuz i setted 20 and not working :/
Reply


Messages In This Thread
About vehicle damage - by Dusan01 - 18.12.2012, 15:29
Re: About vehicle damage - by Mike_Peterson - 18.12.2012, 15:33
Re: About vehicle damage - by mineralo - 18.12.2012, 15:33
Re: About vehicle damage - by Dusan01 - 18.12.2012, 17:15
Re: About vehicle damage - by Mike_Peterson - 18.12.2012, 18:04

Forum Jump:


Users browsing this thread: 2 Guest(s)