Does anyone know how to.......
#2

Command:
Quote:

if (strcmp("/respawnallvehicles", cmdtext, true, 10) == 0)
{
for(new cars=0; cars<MAX_VEHICLES; cars++)
{
if(!VehicleOccupied(cars))
{
SetVehicleToRespawn(cars);
RepairVehicle(cars);
}
}
return 1;
}

Somewhere in your gamemode
Quote:

forward VehicleOccupied(vehicleid);
public VehicleOccupied(vehicleid)
{
for(new i=0;i<MAX_PLAYERS;i++)
{
if(IsPlayerInVehicle(i,vehicleid)) return 1;
}
return 0;
}

Reply


Messages In This Thread
Does anyone know how to....... - by Jack_Rocker - 24.04.2011, 23:52
Re: Does anyone know how to....... - by sMog. - 25.04.2011, 00:06

Forum Jump:


Users browsing this thread: 1 Guest(s)