02.10.2012, 17:52
Quote:
Aww yeah! It works! What happens if a user gets back in the car in that minute? Will the car still disappear?
--EDIT-- Tested, car will disappear, can you also build in that that doesn't happen? Would be greatly apriciatied! |
E.g.
pawn Код:
new myTimer;
public OnPlayerExitVehicle(playerid, vehicleid)
{
myTimer = SetTimerEx("ResetCar", 60000, 0,"d", vehicleid);
}
forward ResetCar(vehicleid);
public ResetCar(vehicleid)
{
DestroyVehicle(vehicleid);
return 1;
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
KillTimer(myTimer);
return 1;
}