From 222391f809823641844cdd0fa15ad9babdc5deab Mon Sep 17 00:00:00 2001
From: Owen <23108066+Owen1212055@users.noreply.github.com>
Date: Wed, 8 Jun 2022 12:32:49 -0400
Subject: [PATCH] Check if is light status or above / isLightOn / starlight
 version fits (#7888)

---
 patches/server/0789-Rewrite-the-light-engine.patch | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/patches/server/0789-Rewrite-the-light-engine.patch b/patches/server/0789-Rewrite-the-light-engine.patch
index a662eea7ff..0bb5f529f9 100644
--- a/patches/server/0789-Rewrite-the-light-engine.patch
+++ b/patches/server/0789-Rewrite-the-light-engine.patch
@@ -5040,7 +5040,7 @@ index 5ce6a2b83546f4dbc3183a386f51b4bacc173744..a7231ceda4f3e96c0e0c11eee953f129
          this.fluidTicks = fluidTickScheduler;
      }
 diff --git a/src/main/java/net/minecraft/world/level/chunk/storage/ChunkSerializer.java b/src/main/java/net/minecraft/world/level/chunk/storage/ChunkSerializer.java
-index be9c15fe141ede1132dbe07ba4bfcf22036ab194..3c220d833ca6bb9409bc71d6f61e61783dba236b 100644
+index be9c15fe141ede1132dbe07ba4bfcf22036ab194..3a2d6200d41c9758763d7a975d62e6e6842da3e2 100644
 --- a/src/main/java/net/minecraft/world/level/chunk/storage/ChunkSerializer.java
 +++ b/src/main/java/net/minecraft/world/level/chunk/storage/ChunkSerializer.java
 @@ -94,6 +94,14 @@ public class ChunkSerializer {
@@ -5096,7 +5096,7 @@ index be9c15fe141ede1132dbe07ba4bfcf22036ab194..3c220d833ca6bb9409bc71d6f61e6178
 -            if (flag3 || flag4) {
 -                if (!flag2) {
 +            // Paper start - rewrite the light engine
-+            if (true || flag3 || flag4) {
++            if (flag) {
 +                if ((flag3 || flag4) && !flag2) {
                      tasksToExecuteOnMain.add(() -> { // Paper - delay this task since we're executing off-main
                      lightengine.retainData(chunkPos, true);