SA-MP Forums Archive
[Tutorial] Simple Save Lines In Your Gamemode (Stunt Server Mainly) - 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)
+---- Forum: Tutorials (https://sampforum.blast.hk/forumdisplay.php?fid=70)
+---- Thread: [Tutorial] Simple Save Lines In Your Gamemode (Stunt Server Mainly) (/showthread.php?tid=433263)



Simple Save Lines In Your Gamemode (Stunt Server Mainly) - RandomDude - 26.04.2013

What is this?
Basically all it is , is to save some space in your Gamemode so it is not clogged up with
pawn Код:
CreateDynamicObject
How?
Well here we go.

First Open Notepad.
Then Goto Pawno>Include Save it as Objects.inc
Now at the top of the notepad paste this
pawn Код:
public LoadServerObjects()
{
Then goto your gamemode and paste this
pawn Код:
forward LoadServerObjects();
So when you give the command it forwards it
And under
pawn Код:
public OnGameModeInit()
{
Paste
pawn Код:
LoadServerObjects();
This will load all the server objects how does it work you might be wondering.
We called it
pawn Код:
public LoadServerObjects();
LoadSeverObjects it will forward as its a command given.

Okay now go back to the notepad and paste all the dynamic objects or whatever cars etc..
and under all that paste this
pawn Код:
return true;
}
So when the Gamemode loads basically it will load all the objects and this will save lines in your Gamemode so you won't be having to scroll through CreateDynamicObject!