mirror of
https://github.com/mat-1/azalea.git
synced 2025-08-02 06:16:04 +00:00
add todo about wrong calculated_bits_per_entry code
This commit is contained in:
parent
858bec2081
commit
6020a2297f
1 changed files with 3 additions and 0 deletions
|
@ -55,6 +55,9 @@ impl PalettedContainer {
|
|||
// that it'd be global. if it's not global, then we have to calculate it
|
||||
// ourselves.
|
||||
// this almost never matters, except on some custom servers like hypixel limbo
|
||||
// TODO: this is incorrect. we should be getting the log2 of the max blockstate
|
||||
// or biome instead of data.len(). this code might be causing wrong data to be
|
||||
// read. ¯\_(ツ)_/¯
|
||||
let calculated_bits_per_entry = math::ceil_log2(data.len() as u32) as u8;
|
||||
let calculated_bits_per_entry_palette_kind =
|
||||
PaletteKind::from_bits_and_type(calculated_bits_per_entry, container_type);
|
||||
|
|
Loading…
Add table
Reference in a new issue