XML Float reading bug? - 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: XML Float reading bug? (
/showthread.php?tid=541001)
XML Float reading bug? -
ranme15 - 08.10.2014
Hello, I am using this XML Plugin:
https://sampforum.blast.hk/showthread.php?tid=425175
For some reason, xml_pointer_getvalue_float retrieves only the first numbers before the dot.
e.g:
PHP код:
new Float: X, Float: Y, string[64];
xml_pointer_childattr(pointer, "posX");
X = xml_pointer_getvalue_float(pointer);
xml_pointer_nextattr(pointer, "posY");
Y = xml_pointer_getvalue_float(pointer);
format(string, 64, "Object -> X: %f | Y: %f", X, Y);
SendClientMessage(playerid, -1, string);
Output:
XML File:
Код:
posX="4202.7002" posY="399.39941"
Am I doing anything wrong? or its just the plugin.