How to make a Filterscript ?
#1

Like the title said. How can you make a Filterscript ?
Reply
#2

pawn Code:
#define FILTERSCRIPT
Or remove the whole #if statement.
Reply
#3

Well you code it exactly the same as the main script BUT you then add it to the .cfg so that it is included on your server.

Here is the standard empty Filterscript source.

pawn Code:
#include <a_samp>

#define FILTERSCRIPT

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Blank Filterscript by your name here");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

#else

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

#endif
Reply
#4

How do I put this as a filterscript:

Quote:

AddStaticVehicleEx(446,-937.04980469,2651.60742188,42.20914459,135.9997558 6,-1,-1,15); //Squalo
AddStaticVehicleEx(560,-897.45996094,2685.41796875,42.17216110,43.99475098 ,-1,-1,15); //Sultan
AddStaticVehicleEx(560,-899.51660156,2683.35351562,42.17523575,45.99975586 ,-1,-1,15); //Sultan
AddStaticVehicleEx(468,-902.74938965,2690.75415039,42.12718582,155.9998779 3,-1,-1,15); //Sanchez
AddStaticVehicleEx(468,-901.71063232,2689.78906250,42.13026047,159.9998779 3,-1,-1,15); //Sanchez
CreateObject(2921,-907.74511719,2689.08447266,44.32780457,0.00000000, 0.00000000,309.25000000); //object(kmb_cam) (1)
CreateObject(2922,-909.75433350,2686.62695312,42.45322037,0.00000000, 0.00000000,42.75000000); //object(kmb_keypad) (1)
CreateObject(2921,-916.16485596,2668.90966797,44.54096603,0.00000000, 0.00000000,96.50000000); //object(kmb_cam) (2)
CreateObject(2922,-899.75476074,2696.66455078,42.53889084,0.00000000, 0.00000000,42.75000000); //object(kmb_keypad) (2)

Reply
#5

onfilterscriptinit
Reply
#6

pawn Code:
public OnFilterScriptInit()
{
    AddStaticVehicleEx(446,-937.04980469,2651.60742188,42.20914459,135.9997558 6,-1,-1,15); //Squalo
    AddStaticVehicleEx(560,-897.45996094,2685.41796875,42.17216110,43.99475098 ,-1,-1,15); //Sultan
    AddStaticVehicleEx(560,-899.51660156,2683.35351562,42.17523575,45.99975586 ,-1,-1,15); //Sultan
    AddStaticVehicleEx(468,-902.74938965,2690.75415039,42.12718582,155.9998779 3,-1,-1,15); //Sanchez
    AddStaticVehicleEx(468,-901.71063232,2689.78906250,42.13026047,159.9998779 3,-1,-1,15); //Sanchez
    CreateObject(2921,-907.74511719,2689.08447266,44.32780457,0.00000000, 0.00000000,309.25000000); //object(kmb_cam) (1)
    CreateObject(2922,-909.75433350,2686.62695312,42.45322037,0.00000000, 0.00000000,42.75000000); //object(kmb_keypad) (1)
    CreateObject(2921,-916.16485596,2668.90966797,44.54096603,0.00000000, 0.00000000,96.50000000); //object(kmb_cam) (2)
    CreateObject(2922,-899.75476074,2696.66455078,42.53889084,0.00000000, 0.00000000,42.75000000); //object(kmb_keypad) (2)
    return 1;
}
Reply
#7

honestly, i think someone should create a whole new scripting tutorial, thats EASIER TO UNDERSTAND, oops, wrong topic....sorry.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)