render3d: gd_fill tests a deflated tile's top bit as written, (b & 0x80000000) != 0, now that the compiler emits the literal (lang/hex-literal, reseeded) - the b < 0 stand-in goes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Orkun ÇAKILKAYA 2026-09-29 22:20:20 +03:00
parent edc94e49e8
commit cebb78c2c3

View file

@ -130,7 +130,7 @@ function gd_fill(render3d_st: mut Render3dState, l: int, key: int, s: int) -> vo
} }
let n = b & 0x7FFFFFFF let n = b & 0x7FFFFFFF
file_seek(render3d_st.gd_file, render3d_st.gd_base + a, 0) file_seek(render3d_st.gd_file, render3d_st.gd_base + a, 0)
if b < 0 { if (b & 0x80000000) != 0 { # the top bit: the tile is deflated
file_read(render3d_st.gd_file, data_of(render3d_st.gd_zbuf), min(n, len(render3d_st.gd_zbuf))) file_read(render3d_st.gd_file, data_of(render3d_st.gd_zbuf), min(n, len(render3d_st.gd_zbuf)))
z_inflate(data_of(render3d_st.gd_zbuf), n, mem_off(data_of(pool), o), tb) z_inflate(data_of(render3d_st.gd_zbuf), n, mem_off(data_of(pool), o), tb)
} else { } else {