SA-MP Forums Archive
define from a file? - 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: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: define from a file? (/showthread.php?tid=249449)



define from a file? - sciman001 - 18.04.2011

Hi all. I am making a config.ini file for my admin scrpt. I need to know if its possible to do this or something like it:
pawn Код:
#define KDT dini_Int(file, "KDT");
Ig thats not how you do it, how would you do it? THANKS IN ADVANCE.


Re: define from a file? - Steven82 - 18.04.2011

I've never tried this or tested this before but maybe try to do this and see what comes up.
pawn Код:
#define KDT "dini_Int(file, "KDT");"
I added " " marks

P.S. Sorry don't know if this works or not


Re: define from a file? - admantis - 18.04.2011

^There's no need for the brackets because the compiler will read it with the brackets (a.k.a as a string)
So the correct usage is sciman001's.


Re: define from a file? - sciman001 - 18.04.2011

ok.. i had to restart my pc because pawno is actin up... anyway, yeah. so i'll just edit this post saying whether it worked or not.


Re: define from a file? - sciman001 - 18.04.2011

works


Re: define from a file? - admantis - 18.04.2011

Good to hear.


Re: define from a file? - sciman001 - 19.04.2011

i had to remove the ; mark though. :/ idk y.