0

Fix transparent check for block ids > 255. (getArrayByte3D -> getArrayShort3D)

This commit is contained in:
Matti Ruohonen
2013-10-14 16:48:41 +03:00
parent a147ca4a36
commit 51e5f3f2b6
2 changed files with 6 additions and 6 deletions

View File

@@ -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;
}

View File

@@ -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;
}