Yini create function
#1

What function i can use to make a file using Y_ini ?

i know for dini:

PHP код:
dini_Create(file); 
i can't convert that to y_ini, because i don't understand some functions.
Reply
#2

All you have to do is open and close the file. You can also do something like:
pawn Код:
// global:
new INI: __ini_handle__;

#define INI_Create(%0) __ini_handle__ = INI_Open(%0);INI_Close(__ini_handle__)
and:
pawn Код:
new file_name[] = "myfirstfile.ini";
   
INI_Create("mysecondfile.ini");
INI_Create(file_name);
Reply
#3

I also find this example

PHP код:
new banfile[64];
        
format(banfile,64,BAN_FOLDER,GetName(pplayerid));
        new 
File:ban fopen(banfileio_write);
        
fwrite(ban"|---Banned---|\n");
        new var[
64];
         
format(var,64,"5/5 Warns");
        
fwrite(ban,var);
        
fclose(ban); 
Reply
#4

@bigboy81, YINI is system and this:

Quote:
Originally Posted by bigboy81
Посмотреть сообщение
I also find this example

PHP код:
new banfile[64];
        
format(banfile,64,BAN_FOLDER,GetName(pplayerid));
        new 
File:ban fopen(banfileio_write);
        
fwrite(ban"|---Banned---|\n");
        new var[
64];
         
format(var,64,"5/5 Warns");
        
fwrite(ban,var);
        
fclose(ban); 
is another system but YINI is faster
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)