PD cars and car that is in the impound spawnrandomly somewhere else!?
#6

I use this command to respawn ALL cars, shouldnt that destroy the PD cars too?
pawn Код:
if(strcmp(cmd, "/respawnallcars", true) == 0 || strcmp(cmd, "/carreset", true) == 0) // by LordMan
    {
        if(IsPlayerConnected(playerid))
        {
            if(PlayerInfo[playerid][pAdmin] < 4)
            {
                SendClientMessage(playerid, COLOR_GRAD1, "** you are not authorized to use that command!");
                return 1;
            }
            new bool:unwanted[MAX_VEHICLES];
            for(new player=0; player<MAX_PLAYERS; player++)
            {
                if(IsPlayerInAnyVehicle(player)) { unwanted[GetPlayerVehicleID(player)]=true; }
            }
            for(new car = 1; car <= 1850; car++)
            {
                if(!unwanted[car]) SetVehicleToRespawn(car);
            }
            format(string, sizeof(string), "SERVER: All unused cars respawned by %s.", sendername);
            BroadCast(COLOR_WHITE,string);
            format(string, sizeof(string), "[ADMIN]: %s has Respawned All Cars.", sendername);
            ABroadCast(COLOR_LIGHTRED,string, 5);
            GameTextForAll("~w~Every Unused Car ~n~~g~Respawned!",5000,1);
            new y, m, d;
            new h,mi,s;
            getdate(y,m,d);
            gettime(h,mi,s);
            format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s Has Respawned All Unused Cars",d,m,y,h,mi,s,sendername);
            AdminLog(string);
        }
        return 1;
    }
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)