Stop cars setting on fire
#3

Quote:
Originally Posted by new121
Посмотреть сообщение
PHP код:
SetTimer("carcheck"1000true); // sets a 1 second timer on repeat put this under OnGameModeInit
forward carcheck()
public 
carcheck()
{
    for(new 
i=0i<MAX_PLAYERSi++)
    {
           new 
vehicleFloat:health;
           
vehicle GetPlayerVehicleID(playerid);
           
GetVehicleHealth(vehiclehealth);
           if(
health 300)
           {
                 
RemovePlayerFromVehicle(i);
           }
     }
     return 
1;

PHP код:
SetTimer("carcheck"1000true); // sets a 1 second timer on repeat put this under OnGameModeInit
forward carcheck()
public 
carcheck()
{
    for(new 
i=0i<MAX_PLAYERSi++)
    {
           new 
vehicleFloat:health;
           
vehicle GetPlayerVehicleID(playerid);
           
GetVehicleHealth(vehiclehealth);
           if(
health 300)
           {
                 
SetVehicleHealth(vehicleid300.0); //it's about destroying
   
SendCientMessage(playerid0xFFFFFF"text");
           }
     }
     return 
1;

Reply


Messages In This Thread
Stop cars setting on fire - by [LHT]Bally - 22.03.2012, 23:17
Re: Stop cars setting on fire - by new121 - 23.03.2012, 00:27
Re: Stop cars setting on fire - by ikkentim - 23.03.2012, 00:56
Re: Stop cars setting on fire - by new121 - 23.03.2012, 01:24
Re: Stop cars setting on fire - by [LHT]Bally - 23.03.2012, 01:34
Re: Stop cars setting on fire - by new121 - 23.03.2012, 01:39
Re: Stop cars setting on fire - by Skribblez - 23.03.2012, 01:40
Re: Stop cars setting on fire - by [LHT]Bally - 23.03.2012, 01:46
Re: Stop cars setting on fire - by Reklez - 23.03.2012, 02:00
Re: Stop cars setting on fire - by [LHT]Bally - 23.03.2012, 02:04

Forum Jump:


Users browsing this thread: 1 Guest(s)