Closed doubleday closed 10 years ago
merged from your PR.
BTW: I just saw that the code is derived from https://github.com/animetrics/PlistCS.
They actually always parse double precision.
Also: I came across this because I tried using a plist from particle designer which initially failed. After the patch it worked
A cool :-) thanks
Tried to open a new pull request for this but failed miserably because i already have one for the same file.
Whatever here's my commit: https://github.com/wooga/cocos2d-xna/commit/b8c7e34f1e690cdb3e6825f22070a550b4de339c
Problem is that PlistDocument tries to parse floats even when real values are encoded as 8 byte double precision values.
For the reference implementation check: http://opensource.apple.com/source/CF/CF-550/CFBinaryPList.c and search for kCFBinaryPlistMarkerReal.
I am actually not sure where the need for RegulateNullBytes in the C# code is coming from so I just can assume it makes sense. The C++ code from apple does not seem to produce something that would make this necessary. But maybe some third party libs ...