From 01822672a550ead357b95d3d6655de4e814c9906 Mon Sep 17 00:00:00 2001 From: Camotoy <20743703+Camotoy@users.noreply.github.com> Date: Tue, 8 Jun 2021 08:57:03 -0400 Subject: [PATCH] Remove debug elements --- connector/pom.xml | 3 --- .../geysermc/connector/network/session/GeyserSession.java | 7 ++++--- .../network/translators/world/block/BlockTranslator.java | 5 +---- 3 files changed, 5 insertions(+), 10 deletions(-) diff --git a/connector/pom.xml b/connector/pom.xml index 8b7b111de..30fec659c 100644 --- a/connector/pom.xml +++ b/connector/pom.xml @@ -155,9 +155,6 @@ com.github.GeyserMC MCProtocolLib e316986 - - - compile diff --git a/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java b/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java index 90b5e5929..73dad7220 100644 --- a/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java +++ b/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java @@ -58,14 +58,15 @@ import com.nukkitx.protocol.bedrock.data.command.CommandPermission; import com.nukkitx.protocol.bedrock.data.entity.EntityData; import com.nukkitx.protocol.bedrock.data.entity.EntityFlag; import com.nukkitx.protocol.bedrock.packet.*; -import com.nukkitx.protocol.bedrock.v431.Bedrock_v431; import it.unimi.dsi.fastutil.ints.Int2ObjectMap; import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; import it.unimi.dsi.fastutil.ints.IntList; import it.unimi.dsi.fastutil.longs.Long2ObjectMap; import it.unimi.dsi.fastutil.longs.Long2ObjectMaps; import it.unimi.dsi.fastutil.longs.Long2ObjectOpenHashMap; -import it.unimi.dsi.fastutil.objects.*; +import it.unimi.dsi.fastutil.objects.Object2ObjectOpenHashMap; +import it.unimi.dsi.fastutil.objects.ObjectIterator; +import it.unimi.dsi.fastutil.objects.ObjectOpenHashSet; import lombok.AccessLevel; import lombok.Getter; import lombok.NonNull; @@ -806,7 +807,7 @@ public class GeyserSession implements CommandSender { @Override public void packetError(PacketErrorEvent event) { connector.getLogger().warning(LanguageUtils.getLocaleStringLog("geyser.network.downstream_error", event.getCause().getMessage())); - //if (connector.getConfig().isDebugMode()) //TODO don't leave this uncommented + if (connector.getConfig().isDebugMode()) event.getCause().printStackTrace(); event.setSuppress(true); } diff --git a/connector/src/main/java/org/geysermc/connector/network/translators/world/block/BlockTranslator.java b/connector/src/main/java/org/geysermc/connector/network/translators/world/block/BlockTranslator.java index 43bd9d934..ed7818924 100644 --- a/connector/src/main/java/org/geysermc/connector/network/translators/world/block/BlockTranslator.java +++ b/connector/src/main/java/org/geysermc/connector/network/translators/world/block/BlockTranslator.java @@ -270,10 +270,7 @@ public abstract class BlockTranslator { NbtMap blockTag = buildBedrockState(entry.getValue()); int bedrockRuntimeId = blockStateOrderedMap.getOrDefault(blockTag, -1); if (bedrockRuntimeId == -1) { - //TODO REMOVE THIS COMMENT BEFORE RELEASE!!!! :) - //throw new RuntimeException("Unable to find " + javaId + " Bedrock runtime ID! Built compound tag: \n" + blockTag); - bedrockRuntimeId = 0; - GeyserConnector.getInstance().getLogger().warning("Unable to find " + javaId + " Bedrock runtime ID!"); + throw new RuntimeException("Unable to find " + javaId + " Bedrock runtime ID! Built compound tag: \n" + blockTag); } switch (javaId) {