y_ini beginner prob! - 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: y_ini beginner prob! (
/showthread.php?tid=269261)
y_ini beginner prob! -
Seven_of_Nine - 15.07.2011
Hello all,
I've just started to use y_ini and it's a lil' complicated after dini..
So that's what I got:
pawn Код:
new INI:iFile = INI_Open(PlayerPath(playerid));
INI_SetTag(iFile,"data");
INI_WriteInt(iFile,"Pass",-1);
INI_WriteInt(iFile,"Admin",0);
INI_WriteInt(iFile,"Score",0);
INI_WriteInt(iFile,"Banned",0);
INI_Close(iFile);
PlayerPath:
pawn Код:
stock PlayerPath(playerid) {
new iStr[256],name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(iStr,sizeof(iStr),PATH,name);
return iStr;
}
PATH is "/Users/%.ini"
It worked fine with dini reading and etc. but now it just creates a file named "91ni"
Can you help me?
Re: y_ini beginner prob! -
Jeffry - 15.07.2011
Path should be:
Forgot the 's'
Jeffry
Re: y_ini beginner prob! -
Seven_of_Nine - 15.07.2011
Quote:
Originally Posted by Jeffry
Path should be:
Forgot the 's'
Jeffry
|
Lol Jeffry thanks!