OnPlayerExitVehicle Help
#1

Hello, I v searched about many functions which destroy player vehicle when they leave his car by setting an timer but i wondered that if you set a timer it's will lag the server if you dont kill it how to get function which kill the timer or reduce lags iv already this in my script:

Код:
public OnPlayerExitVehicle(playerid, vehicleid)
{
    SetTimerEx("DesVeh", 6000, 0, "i", vehicleid);
    return 1;
}

forward DesVeh(vehid);
public DesVeh(vehid)
{
    for(new i;i<MAX_PLAYERS;i++)
    {
        if(IsPlayerConnected(i))
        {
            if(IsPlayerInVehicle(i, vehid)) return 1;
        }
    }
    return SetVehicleToRespawn(vehid);
}
Reply


Messages In This Thread
OnPlayerExitVehicle Help - by MahdiGames - 28.01.2014, 20:36
Re: OnPlayerExitVehicle Help - by Scottas - 28.01.2014, 20:52
Re: OnPlayerExitVehicle Help - by MahdiGames - 28.01.2014, 20:59
Re: OnPlayerExitVehicle Help - by Syncro - 28.01.2014, 21:03
Re: OnPlayerExitVehicle Help - by [KHK]Khalid - 28.01.2014, 22:25

Forum Jump:


Users browsing this thread: 1 Guest(s)