Changing a script from an empty GM into FS? -
Da' J' - 04.10.2012
So, I really don't remember how/if you could translate a script from gamemode into a FS...
I have two scripts in a empty gamemode, which I want to change in FS's.... But, how did I do it? Could someone do it, or was it even possible? >.>
http://pastebin.com/Tyr1kAxp
Re: Changing a script from an empty GM into FS? -
SwisherSweet - 04.10.2012
http://pastebin.com/giKC79Vb
Here you go!
Re: Changing a script from an empty GM into FS? -
Da' J' - 04.10.2012
Oh, that fast... Thanks xD
Re: Changing a script from an empty GM into FS? -
Alcatraz Gaming - 04.10.2012
Just to help you when you want to convert other GM into a filterscript
After #include <a.samp>
place
#define FILTERSCRIPT
So, it will define as a filterscript
like
#include <a.samp>
#define FILTERSCRIPT
So, under #define FILTERSCRIPT, you have to initiate the script, so
public OnFilterScriptInit( )
{
SetGameModeText("Blank Script");
AddPlayerClass(0, 0, 0, 0, 0.0, 0, 0, 0, 0, 0, 0); ( You can change the 0, 0, 0's, sinc they work to the player classes )
return 1;
}
Re: Changing a script from an empty GM into FS? -
SwisherSweet - 04.10.2012
WRONGGGG!!!!!
You gotta do
Then under that define
then change these
pawn Код:
public OnGameModeInit( )
to
public OnFilterScriptInit( )
And
pawn Код:
public OnGameModeExit( )
To
public OnFilterScriptExit( )
and done xD.
Re: Changing a script from an empty GM into FS? -
Alcatraz Gaming - 04.10.2012
Sorry,forgot to get the pawn code BB!
Re: Changing a script from an empty GM into FS? -
CmZxC - 04.10.2012
Amateurs.
#define FILTERSCRIPT is useful ONLY if used aswell with "#if defined FILTERSCRIPT" as seen in the blank script.
pawn Код:
#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
To translate a gamemode into FS I think only think you need to do is rename "OnGameModeInit" to "OnFilterScriptInit", "OnGameModeExit" to "OnFilterScriptExit", and move all from "main()" to OnFilterScriptInit, and then remove main() function.
Please, do not post if you have no idea what you are talking about.