How to not respawn created cars ingame
#1

Hey,
I made a car-respawn script and now a car spawn script so i can spawn some vehicles at a flexible position.
But now i dont want to respawn them with my respawncar script when the cars get destroyed.
Maybe you can help?

Here my codes:

spawn script:
pawn Код:
CMD:spawn(playerid, params[])
{
    if (IsPlayerAdmin(playerid) == 1)
    {
        new Float:x;
        new Float:y;
        new Float:z;
        new Float:a;
       
        if (sscanf(params, "s", params[0]))
        {
            SendClientMessage(playerid, RED, "USAGE: /spawn [object]");
        }
        else if (!strcmp(params[0], gObjects[0], true))
        {
            GetPlayerPos(playerid, x, y, z);
            GetPlayerFacingAngle(playerid, a);
           
            CreateVehicle(522, x-3, y, z+5, a, 0, 0, -1);
        }
        else if (!strcmp(params[0], gObjects[1], true))
        {
            GetPlayerPos(playerid, x, y, z);
            GetPlayerFacingAngle(playerid, a);
           
            CreateVehicle(451, x-3, y, z+5, a, 0, 0, -1);
        }
        else if (!strcmp(params[0], gObjects[2], true))
        {
            GetPlayerPos(playerid, x, y, z);
            GetPlayerFacingAngle(playerid, a);
           
            CreateVehicle(425, x-5, y, z+5, a, 0, 0, -1);
        }
        else if (!strcmp(params, gObjects[3], true))
        {
            GetPlayerPos(playerid, x, y, z);
            GetPlayerFacingAngle(playerid, a);
           
            CreateVehicle(520, x-3, y, z+5, a, 0, 0, -1);
        }
        else
        {
            SendClientMessage(playerid, RED, "SERVER: Fahrzeug existiert nicht");
        }
    }
    else
    {
        SendClientMessage(playerid, RED, "SERVER: Du bist nicht als Admin eingeloggt");
    }
    return 1;
}
respawner:

pawn Код:
CMD:respawn(playerid, params[])
{
    if (IsPlayerAdmin(playerid) == 1)
    {
        new command[64];
       
        if (sscanf(params, "s", command))
        {
            SendClientMessage(playerid, RED, "USAGE: /respawn [befehl]");
        }      
        else if (!strcmp(command, "autos", true))
        {
            new pname[256];
            new string[256];
            GetPlayerName(playerid, pname, sizeof(pname));
            format(string, sizeof(string), "*** %s hat die Autos respawnt.", pname);
            SendClientMessageToAll(ORANGE, string);
           
            for (new cars=0; cars<MAX_VEHICLES; cars++)
            {
            SetVehicleToRespawn(cars);
            }
        }
    }
   
    else
    {
        SendClientMessage(playerid, RED, "SERVER: Du bist nicht als Admin eingeloggt");
    }
    return 1;
}
Reply
#2

Sorry for doublepost...

BUMP
Reply
#3

Nobody can help?
Reply
#4

Why nobody answeres? i told everything you need to know didnt i?
if u dont understand my question please tell me but i really need this
Reply
#5

Stop BUMPING your topic.. Only in 12 hours.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)