17.04.2015, 11:23
(
Последний раз редактировалось Ahmad45123; 17.04.2015 в 12:04.
)
y_ini is bugged, Whenever you save an empty item, It keeps making a new line in the INI file.
So if you did:
It'd be:
And actually I fixed it.
You have to open the file YSI_Storage/y_ini/writing.inc and edit the line 883 which should crosspond to:
if (!deleted) fwrite(buffer, sLine);
And change it to:
if (!deleted) fwrite(buffer, "");
This will create a new line in the file but atleast the newline wont repeat...
So running the same code above will output:
I am not free at the moment to create a pull request but if someone else can do it... No problem.
E: Okay.. I will create one now.
So if you did:
pawn Код:
public OnGameModeInit()
{
for(new i; i <= 50; i++)
{
new INI:iniFile = INI_Open("testFile.ini");
INI_SetTag(iniFile, "examples");
INI_WriteString(iniFile, "Test", "");
INI_WriteString(iniFile, "Test2", "");
INI_Close(iniFile);
}
return 1;
}
Код:
[examples] Test2 = Test =
You have to open the file YSI_Storage/y_ini/writing.inc and edit the line 883 which should crosspond to:
if (!deleted) fwrite(buffer, sLine);
And change it to:
if (!deleted) fwrite(buffer, "");
This will create a new line in the file but atleast the newline wont repeat...
So running the same code above will output:
Код:
[examples] Test2 = Test =
E: Okay.. I will create one now.