y_INI help with reading - 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: y_INI help with reading (
/showthread.php?tid=402189)
y_INI help with reading -
PDChaseOfficial - 25.12.2012
Hello,
I'm creating my own house system. I got over the y_ini tutorial but I got quite confused. I took out part of the code and I tried it out but I can't find out why it gives me the errors it does.
Код:
CMD:enter(playerid,params[])
441{
442 for(new i=0;i<MAX_HOUSES;i++)
443 {
444 if(fexist(HousePath(i)))
445 {
446 new INI:File=INI_Open(HousePath(i));
447 new Float:x,Float:y,Float:z;
448 INI_Float("Enterx",x);
449 INI_Float("Entery",y);
450 INI_Float("Enterz",z);
451 if(IsPlayerInRangeOfPoint(playerid,5,x,y,z))
452 {
453 SendClientMessage(playerid,COLOR_GREEN,"You are in range.");
454 }
455 }
456 }
457 INI_Close(File);
458 return 1;
459}
Код:
(449) : error 017: undefined symbol "name"
(449) : error 017: undefined symbol "value"
(450) : error 017: undefined symbol "name"
(450) : error 017: undefined symbol "value"
(451) : error 017: undefined symbol "name"
(451) : error 017: undefined symbol "value"
(447) : warning 204: symbol is assigned a value that is never used: "File"
(458) : error 017: undefined symbol "File"
Re: y_INI help with reading -
PDChaseOfficial - 25.12.2012
Ok, I fixed it by using
Код:
x=HouseInfo[houseid][hEnterx]...
now, I have a different problem.
Код:
forward LoadHouse_data(houseid,name[],value[]);
on this line:
Код:
INI_Float("Enterx",HouseInfo[houseid][hEnterx],5);
I get this error:
Код:
(330) : fatal error 103: insufficient memory
The 5 is there to round up to 5 decimal places.
How do I solve this please?