Bug with long lengths
GitMeep opened this issue · 4 comments
GitMeep commented
longs can be 9 bytes (72 bits) long, Notch specified 8 bytes () only in his specification at: http://web.archive.org/web/20110723210920/http://www.minecraft.net/docs/NBT.txt
jaquadro commented
Where are you getting 9 bytes from?
GitMeep commented
jaquadro commented
Your understanding of bytes is incorrect.
64-bit (long) integers have a decimal range of −9,223,372,036,854,775,808 to 9,223,372,036,854,775,807. Up to 19 digits in a text field. If it were converted to hex, it would take up 16 digits in a text field, which is maybe what you were expecting.
It's being handled correctly; there is no bug here.
GitMeep commented
Ah, yeah sorry, i did actiually know that, i dont know what i was thinking. Really usefull program btw. :)