diff options
author | makamys <makamys@outlook.com> | 2022-07-15 17:03:39 +0200 |
---|---|---|
committer | makamys <makamys@outlook.com> | 2022-07-15 17:03:59 +0200 |
commit | 1300761b7a7eaa07868d16639135849e691360d1 (patch) | |
tree | 42bdc205ff7d2d3994c574006e40fa1c084bb5d8 /src | |
parent | f7fd77bcd5c2bbfd1176a761eb3f2af067526015 (diff) | |
download | Neodymium-1300761b7a7eaa07868d16639135849e691360d1.tar.gz Neodymium-1300761b7a7eaa07868d16639135849e691360d1.tar.bz2 Neodymium-1300761b7a7eaa07868d16639135849e691360d1.zip |
Warn if chunk mesh uses normals and GL lighting is enabled
(cc #5)
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/makamys/neodymium/renderer/ChunkMesh.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main/java/makamys/neodymium/renderer/ChunkMesh.java b/src/main/java/makamys/neodymium/renderer/ChunkMesh.java index f28b390..93d71b3 100644 --- a/src/main/java/makamys/neodymium/renderer/ChunkMesh.java +++ b/src/main/java/makamys/neodymium/renderer/ChunkMesh.java @@ -86,10 +86,13 @@ public class ChunkMesh extends Mesh { LOGGER.error("Error in chunk " + tessellatorToString(t) + ": Unsupported draw mode: " + t.drawMode); errors = true; } - if(!t.hasTexture || !t.hasBrightness || !t.hasColor /*|| t.hasNormals*/) { + if(!t.hasTexture || !t.hasBrightness || !t.hasColor) { LOGGER.error("Error in chunk " + tessellatorToString(t) + ": Unsupported tessellator flags"); errors = true; } + if(t.hasNormals && GL11.glIsEnabled(GL11.GL_LIGHTING)) { + LOGGER.warn("Warning in chunk " + tessellatorToString(t) + ": Chunk uses GL lighting, this is not implemented."); + } if(errors) { LOGGER.error("Skipping chunk due to errors."); return; @@ -378,6 +381,6 @@ public class ChunkMesh extends Mesh { } } - + } |