Modular scripting - 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: Modular scripting (
/showthread.php?tid=455934)
Modular scripting -
Marricio - 03.08.2013
I'm starting a new gamemode, so I want to make it a modular gamemode (divided in files) to keep it organized. Though, I also have a problem; only the first file I #include is included.
pawn Code:
// Scripts
#include "../scriptfiles/GAMEMODE/SCRIPTS/Script1.pwn" // This one loads.
#include "../scriptfiles/GAMEMODE/SCRIPTS/Script2.pwn" // This one doesn't loads.
However, if I do this:
pawn Code:
// Scripts
#include "../scriptfiles/OUTBREAK/SCRIPTS/Script2.pwn" // This one loads.
#include "../scriptfiles/OUTBREAK/SCRIPTS/Script1.pwn" // This one doesn't loads.
That part is at the top of the script, I have tried at the bottom of the script but it's the same thing.
Anyone got an idea, please?