Need help reading files with ParseFile (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)
+--- Thread: Need help reading files with ParseFile (Y_INI) (
/showthread.php?tid=506535)
Need help reading files with ParseFile (Y_INI) -
mrkiller90 - 13.04.2014
So, basically I am doing a roleplay gamemode from scretch and Im trying to make a house system using Y_ini , I can save correctly the problem is that when I run the server it doesn't load the files.ini , I don't know if ParseFile is reading the floats I hope get some help.
Here is the code:
pawn Код:
forward LoadHouse_data(name[],value[]);
public LoadHouse_data(name[],value[])
{
for(new i = 0; i < MAX_HOUSES; i++)
{
INI_Int("ID",HouseInfo[i][hID]);
INI_Int("Name",HouseInfo[i][hName]);
INI_Float("EntX",HouseInfo[i][hEntX]);
INI_Float("EntY",HouseInfo[i][hEntY]);
INI_Float("EntZ",HouseInfo[i][hEntZ]);
INI_Int("Locked",HouseInfo[i][hLocked]);
INI_Int("Int",HouseInfo[i][hInt]);
INI_Int("Price",HouseInfo[i][hPrice]);
}
return 1;
}
stock LoadHouses()
{
for(new i = 0; i < MAX_HOUSES; i++)
{
if(fexist(HousePath(i)))
{
INI_ParseFile(HousePath(i),"LoadHouse_%d");
CreatePickup(1273,1,HouseInfo[i][hEntX],HouseInfo[i][hEntY],HouseInfo[i][hEntZ],-1);
printf("House %d Loaded", i);
}
}
}
When I join the server the pickup is not created please help me I have tried so many things I've read lots of tutorials and I cant understand whats wrong :S (it prints correctly "House 0 Loaded" "House 1 Loaded"...)
Re: Need help reading files with ParseFile (Y_INI) -
mrkiller90 - 13.04.2014
Please I need some answer )):
Re: Need help reading files with ParseFile (Y_INI) -
mrkiller90 - 14.04.2014
Anyone today? S:
Re: Need help reading files with ParseFile (Y_INI) -
mrkiller90 - 15.04.2014
maybe today? ):
Re: Need help reading files with ParseFile (Y_INI) -
mrkiller90 - 17.04.2014
Is that Yini so bad to anyone help me with that?
Re: Need help reading files with ParseFile (Y_INI) -
mjay768 - 31.07.2014
I have the same problem. cant load integers.