From 6514b188fe91e6805946ae855a6a58b43ccdfe71 Mon Sep 17 00:00:00 2001 From: themode Date: Mon, 15 Mar 2021 23:07:43 +0100 Subject: [PATCH] ChunkDataPacket remove unnecessary operations --- .../server/network/packet/server/play/ChunkDataPacket.java | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/main/java/net/minestom/server/network/packet/server/play/ChunkDataPacket.java b/src/main/java/net/minestom/server/network/packet/server/play/ChunkDataPacket.java index ef84b8fa6..9b25a5df2 100644 --- a/src/main/java/net/minestom/server/network/packet/server/play/ChunkDataPacket.java +++ b/src/main/java/net/minestom/server/network/packet/server/play/ChunkDataPacket.java @@ -23,6 +23,7 @@ import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import org.jglrxavpok.hephaistos.nbt.NBTCompound; +import java.util.Arrays; import java.util.UUID; public class ChunkDataPacket implements ServerPacket, CacheablePacket { @@ -69,11 +70,7 @@ public class ChunkDataPacket implements ServerPacket, CacheablePacket { if (section.length > 0) { // section contains at least one block mask |= 1 << i; Utils.writeBlocks(blocks, paletteStorage.getPalette(i), section, paletteStorage.getBitsPerEntry()); - } else { - mask |= 0; } - } else { - mask |= 0; } }