26.03.2014, 22:44
I need CMD for restart server all 5 mintues and Its respawn the cars and player spawn with textdraw for a second on the game.
Thanks for helpers !
Thanks for helpers !
CMD:respawncars(playerid,params[])
{
for(new i=0; i<MAX_VEHICLES; i++)
{
if(UnoccupiedVehicle(i))
{
SetVehicleToRespawn(i);
}
}
return SendClientMessage(playerid,yellow,"You have respawned all vehicles!");
}
//OnGameModeInIt
SetTimer("reSpawn",300000,true);
forward reSpawn();
public reSpawn()
{
for(new i=0; i<MAX_VEHICLES; i++)
{
if(UnoccupiedVehicle(i))
{
SetVehicleToRespawn(i);
}
}
return 1;
}
undefined symbol "UnoccupiedVehicle" |
forward reSpawn();
public reSpawn()
{
for(new v =0; v<MAX_VEHICLES; v++)
{
for(new i=0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerInVehicle(i, v))
{
SetVehicleToRespawn(i);
}
}
}
return 1;
}
forward reSpawn();
public reSpawn()
{
for(new v =0; v<MAX_VEHICLES; v++)
{
for(new i=0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerInVehicle(i, v))
{
SetVehicleToRespawn(v);
}
}
}
return 1;
}