Fix transparent check for block ids > 255. (getArrayByte3D -> getArrayShort3D)
This commit is contained in:
@@ -61,9 +61,9 @@ base_occluded(void *data, RenderState *state, int x, int y, int z) {
|
||||
!render_mode_hidden(state->rendermode, x-1, y, z) &&
|
||||
!render_mode_hidden(state->rendermode, x, y, z+1) &&
|
||||
!render_mode_hidden(state->rendermode, x, y+1, z) &&
|
||||
!is_transparent(getArrayByte3D(state->blocks, x-1, y, z)) &&
|
||||
!is_transparent(getArrayByte3D(state->blocks, x, y, z+1)) &&
|
||||
!is_transparent(getArrayByte3D(state->blocks, x, y+1, z))) {
|
||||
!is_transparent(getArrayShort3D(state->blocks, x-1, y, z)) &&
|
||||
!is_transparent(getArrayShort3D(state->blocks, x, y, z+1)) &&
|
||||
!is_transparent(getArrayShort3D(state->blocks, x, y+1, z))) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
@@ -23,9 +23,9 @@ clear_base_occluded(void *data, RenderState *state, int x, int y, int z) {
|
||||
!render_mode_hidden(state->rendermode, x-1, y, z) &&
|
||||
!render_mode_hidden(state->rendermode, x, y, z+1) &&
|
||||
!render_mode_hidden(state->rendermode, x, y+1, z) &&
|
||||
!is_transparent(getArrayByte3D(state->blocks, x-1, y, z)) &&
|
||||
!is_transparent(getArrayByte3D(state->blocks, x, y, z+1)) &&
|
||||
!is_transparent(getArrayByte3D(state->blocks, x, y+1, z))) {
|
||||
!is_transparent(getArrayShort3D(state->blocks, x-1, y, z)) &&
|
||||
!is_transparent(getArrayShort3D(state->blocks, x, y, z+1)) &&
|
||||
!is_transparent(getArrayShort3D(state->blocks, x, y+1, z))) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user