SA-MP Forums Archive
Help Me For maps - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help Me For maps (/showthread.php?tid=571122)



Help Me For maps - matej13 - 16.04.2015

Good day to put the map as filterscripts please ??
For answers will be grateful!
Thank you!


Re: Help Me For maps - Azula - 16.04.2015

to put FS map
PHP код:
new.pwn
public OnFilterScriptInit()
{
    
//your map 
    
return 1;
}
server.cfg 
filterscripts 
new 
or to put map as include


PHP код:
#include <map>
public OnGameModeInit()
{
    
// 
        
mapload();
    return 
1;
}
create map.inc file and put 
mapload
() 

 
//// your mapping 




Re: Help Me For maps - matej13 - 16.04.2015

Thank you!


Re: Help Me For maps - matej13 - 16.04.2015

And another way?


Re: Help Me For maps - ATGOggy - 16.04.2015

Making filterscripts is the best way. Also, create a function called AddMap(mapname[], MapFilterScriptName[], ................);

And in the filterscript, Add this:
PHP код:
public OnFilterscriptInit()
{
   
//objects
}
public 
OnFilterscriptExit()
{
    for(new 
i=0i<MAX_OBJECTSi++)
    {
         
DestroyObject(i);
    }
    return 
1;

But you can load only 16 filterscripts at a time. To fix this, unload the current filterscript and load the new when the map changes.


Re: Help Me For maps - matej13 - 10.05.2015

And RemoveBuilding.


Re: Help Me For maps - SoFahim - 10.05.2015

You can add your Maps code in the Gamemode ( laggy)
in public OnGameModeInit() // in this line