30.12.2011, 12:30
(
Последний раз редактировалось XxCozzaxX; 30.12.2011 в 12:34.
Причина: Fixed indentation
)
Код:
public VehicleCheck()
{
new empty = false;
new currentveh;
for(new i =0; i != MAX_VEHICLES; ++i)
{
for (new x = 0; x != MAX_PLAYERS; ++x)
{
if(GetPlayerVehicleID(x) != i)
{
empty = true;
currentveh = i;
}
}
}
if(empty)
{
DestroyVehicle(currentveh);
}
}
I called it using a timer that runs every 1 second (1000ms) and it doesn't seem to clear up any vehicles that have no one in them. Any ideas?

