fix
This commit is contained in:
parent
37244d7f69
commit
7d853c2180
@ -149,7 +149,7 @@ func (r *MapBlockRenderer) Render(pos1, pos2 *types.MapBlockCoords) (*image.NRGB
|
|||||||
|
|
||||||
for x := 0; x < 16; x++ {
|
for x := 0; x < 16; x++ {
|
||||||
for z := 0; z < 16; z++ {
|
for z := 0; z < 16; z++ {
|
||||||
var colors_stack [15]color.RGBA
|
var colors_stack [16]color.RGBA
|
||||||
var visible_nodes_count uint8 = 0
|
var visible_nodes_count uint8 = 0
|
||||||
for y := 15; y >= 0; y-- {
|
for y := 15; y >= 0; y-- {
|
||||||
if xzOccupationMap[x][z] {
|
if xzOccupationMap[x][z] {
|
||||||
@ -243,6 +243,10 @@ func (r *MapBlockRenderer) Render(pos1, pos2 *types.MapBlockCoords) (*image.NRGB
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if visible_nodes_count == 0 {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
visible_nodes_count--
|
visible_nodes_count--
|
||||||
result_color := colors_stack[visible_nodes_count]
|
result_color := colors_stack[visible_nodes_count]
|
||||||
if visible_nodes_count > 0 {
|
if visible_nodes_count > 0 {
|
||||||
|
Loading…
Reference in New Issue
Block a user