A way to delete carz PERMANENTLY?
#1

Is there a way I can delete all the carz from my server PERMANENTLY?
Reply
#2

Код:
for(new i = 0; i < MAX_VEHICLES; i++)
{
        if(IsValidVehicle(i))
                  DestroyVehicle(i);
}
Reply
#3

https://sampwiki.blast.hk/wiki/DestroyVehicle
Reply
#4

Please I am newbie I am not sure how to do it?
Which part in Gamemode?
Reply
#5

Please help me!
Reply
#6

You asked for a way, and it was given..

Anyways, you can understand what part you should get:
pawn Код:
#include < a_samp >

native IsValidVehicle( vehicleid );

public OnPlayerCommandText( playerid, cmdtext[ ] )
{
    if( !strcmp( "/delallveh", cmdtext, true ) )
    {
        for( new i = 0; i < MAX_VEHICLES; i++ )
        {
            if( IsValidVehicle( i ) ) DestroyVehicle( i );
        }
        return 1;
    }
    return 0;
}
Reply
#7

Remove the AddStaticVehicle/AddStaticVehicleEx/CreateVehicle lines from your game mode?

If you don't want it then do this in your game mode:

pawn Код:
public OnVehicleSpawn(vehicleid)
{
    DestroyVehicle(vehicleid);
    return 1;
}
Reply
#8

Please I am not sure but can you help me?
http://pastebin.com/nXuk2Aff
Here is my gamemode Please help!
Reply
#9

Dude it's not rocket science. There are a few ways for people to make cars. They can either use AddStaticVehicle, AddStaticVehicleEx and CreateVehicle. Press CTRL + F to load up the search box, and find all of these and delete the lines. The lines would look something like this:

CreateVehicle(401,342.848,159.493,583.148,45.3,,0, 0,1200);
AddStaticVehicleEx(401,348.573,582.485,284.472,54. 1,0,0,1200);
AddStaticVehicle(401,3481.583,2959.471,582.5821,31 .4,0,0);

The numbers will all be different, but the first words and then open bracket will be the same. Search for them and then simply delete them.
Reply
#10

Remove line 2228 all the way to 2487
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)