SaveIn problem - 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: SaveIn problem (
/showthread.php?tid=248518)
SaveIn problem -
Seven_of_Nine - 14.04.2011
Hi all
I wrote a SaveIn script for myself, but when I want to use it, my pawn says "undefined symbol 'kick'".
the code:
pawn Код:
stock SaveIn(logname,text) {
new
text1[128],
name[30],
File:file;
format(text1,sizeof(text1),"%s",text);
format(name,sizeof(name),"Logs/%s.txt",logname);
file = fopen(name,io_append);
fwrite(file,text1);
fclose(file);
}
the way I used it:
please help
note: when I use like this: "SaveIn("kicks",text);" then it says argument type mismatch.
another note: please
correct, not rewrite the code :]
Re: SaveIn problem -
iJumbo - 14.04.2011
argument type mismatch means you have to put stock SaveIn(logname[],text[]) the [] if u have 2 put thing in a text like "ban"
Re: SaveIn problem -
Seven_of_Nine - 14.04.2011
Thanks, solved! :]
Re: SaveIn problem -
iJumbo - 14.04.2011
np
Re: SaveIn problem -
Seven_of_Nine - 14.04.2011
1 more thing:
if I fread this, then how do I show
only 6 lines?
SaveIn problem - 6 lines only -
Seven_of_Nine - 14.04.2011
So how do I do that? Anyone?