attempt improve lighting thing
This commit is contained in:
@@ -103,19 +103,22 @@ public class VoxelIngestService {
|
|||||||
//if (section.isEmpty()) continue;
|
//if (section.isEmpty()) continue;
|
||||||
var pos = ChunkSectionPos.from(chunk.getPos(), i);
|
var pos = ChunkSectionPos.from(chunk.getPos(), i);
|
||||||
var bl = blp.getLightSection(pos);
|
var bl = blp.getLightSection(pos);
|
||||||
|
boolean blNull = bl == null;
|
||||||
if (!(bl == null || bl.isUninitialized())) {
|
if (!(bl == null || bl.isUninitialized())) {
|
||||||
bl = bl.copy();
|
bl = bl.copy();
|
||||||
} else {
|
} else {
|
||||||
bl = null;
|
bl = null;
|
||||||
}
|
}
|
||||||
var sl = slp.getLightSection(pos);
|
var sl = slp.getLightSection(pos);
|
||||||
|
boolean slNull = sl == null;
|
||||||
if (!(sl == null || sl.isUninitialized())) {
|
if (!(sl == null || sl.isUninitialized())) {
|
||||||
sl = sl.copy();
|
sl = sl.copy();
|
||||||
} else {
|
} else {
|
||||||
sl = null;
|
sl = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((bl == null && sl == null) && section.isEmpty()) {
|
//If its null for either, assume failure to obtain lighting and ignore section
|
||||||
|
if (blNull || slNull) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user