You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
VarInts are not great for negative twos-complement ints. It would generally be an improvement to zig zag encode those, though it will be a minor difference.
For example, saving 4 chunks around 0-0, there would be 64 coordinates saved. Using ints this would be 32*4 = 128 bytes. Using VarInts the positive ones would be 1 byte, negative ones would be 5 bytes, so 16*1 + 16*5 = 81 bytes. Using zig zag encoding + var ints it would be 1 byte for each value, so 32 bytes.
The text was updated successfully, but these errors were encountered:
VarInts are not great for negative twos-complement ints. It would generally be an improvement to zig zag encode those, though it will be a minor difference.
For example, saving 4 chunks around 0-0, there would be 64 coordinates saved. Using ints this would be
32*4 = 128 bytes
. Using VarInts the positive ones would be 1 byte, negative ones would be 5 bytes, so16*1 + 16*5 = 81 bytes
. Using zig zag encoding + var ints it would be 1 byte for each value, so 32 bytes.The text was updated successfully, but these errors were encountered: