BenWoodworth / knbt

Kotlin NBT library for kotlinx.serialization
GNU Lesser General Public License v3.0
79 stars 3 forks source link

Investigate `NaN` and infinity values for SNBT #33

Open BenWoodworth opened 1 year ago

BenWoodworth commented 1 year ago

Currently the encoder is happy to print out NaNd, -Infinityd, etc. but there's nothing in the decoder to pick those up. It gets read in as NbtStrings.

And interestingly, Java Minecraft seems to have the same behavior

BenWoodworth commented 6 months ago

See allowSpecialFloatingPointValues in the JsonConfiguration