grable, this was really handy! But I ran into problems with my particle system while deserializing -- most values were read in correctly, but it broke on the first float and exited early, then after fixing that, it broke on the first negative number. So here are two minor fixes to this serializer to get it to load floats and negative numbers.
In Codecs.bmx, change line 231 to this:
which removes "c =Asc("-")" so that tokens starting with - are read as numbers once you also change line 242 to
Finally, there was code in there to handle floats, but it was in a while loop that would never parse a period. Change line 246 to
Works great now, thanks!
In Codecs.bmx, change line 231 to this:
ElseIf (c >= Asc("a") And c <= Asc("z")) Or (c >= Asc("A") And c <= Asc("Z")) Or c = Asc("_") Then
which removes "c =Asc("-")" so that tokens starting with - are read as numbers once you also change line 242 to
ElseIf (c >= Asc("0") And c <= Asc("9")) Or c = Asc("-") Then
Finally, there was code in there to handle floats, but it was in a while loop that would never parse a period. Change line 246 to
While (c >= Asc("0") And c <= Asc("9")) Or c = Asc(".")
Works great now, thanks!