Question for someone who uses "y_ini" - 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: Question for someone who uses "y_ini" (
/showthread.php?tid=206820)
Question for someone who uses "y_ini" -
blackwave - 04.01.2011
If you do use the system "y_ini", can you tell me how to do it?
Quote:
On dini, we used to use for check if a file exists:
if(dini_Exists(file)) ...
But on y_ini, how do we do it?
On dini we used to use create a file:
dini_Create(file);
|
How are these functions above on y_ini? I'm really confused. The rest I can take over, and I'm just confused on this part =S. Thx.
Re: Question for someone who uses "y_ini" -
Kwarde - 04.01.2011
Use
fexist then.
It's the standard function in samp. Here's a little example:
pawn Код:
if(fexist("TEST.txt"))
print("<> scriptfiles/TEST.txt exists!");
else
print("<> scriptfiles/TEXT.txt does not exist!");
You can also use formatted strings of course.
Re: Question for someone who uses "y_ini" -
blackwave - 04.01.2011
Thx. But how about create the .ini file on y_ini system?
Re: Question for someone who uses "y_ini" -
Kwarde - 04.01.2011
Ask it on the topic of ******. I don't use Y_INI.
Or ask it to ****** himself. He knows it as the best :')
But aint it like this:
CreateFile (idk the name of the function) and as excention .ini
Example (of Dini)
This will create an 'test.ini' in your scriptfiles folder. (INI file)
Re: Question for someone who uses "y_ini" -
Patrik356b - 04.01.2011
Use fwrite(File: Handle, string);
Re: Question for someone who uses "y_ini" -
Kwarde - 04.01.2011
Quote:
Originally Posted by Patrik356b
Use fwrite(File: Handle, string);
|
He's using
y_ini. If you use fwrite, the y_ini used file will get stuck, probably. Whatever it won't work good anymore, probably.