Question for someone who uses "y_ini"
#1

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.
Reply
#2

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.
Reply
#3

Thx. But how about create the .ini file on y_ini system?
Reply
#4

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)

pawn Код:
dini_Create("test.ini");
This will create an 'test.ini' in your scriptfiles folder. (INI file)
Reply
#5

Use fwrite(File: Handle, string);
Reply
#6

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.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)