diff --git a/src/main/java/com/minelittlepony/api/pony/network/fabric/Channel.java b/src/main/java/com/minelittlepony/api/pony/network/fabric/Channel.java index d787d8be..2c719950 100644 --- a/src/main/java/com/minelittlepony/api/pony/network/fabric/Channel.java +++ b/src/main/java/com/minelittlepony/api/pony/network/fabric/Channel.java @@ -55,18 +55,19 @@ public class Channel { }); } + public static boolean isRegistered() { + return registered; + } + public static boolean broadcastPonyData(IPonyData packet, boolean noSkin) { + if (!isRegistered()) { + return false; + } if (FabricLoader.getInstance().getEnvironmentType() != EnvType.CLIENT) { throw new RuntimeException("Client packet send called by the server"); } - if (!registered) { - LOGGER.info("Skipping network packet as the server has not consented"); - return false; - } else { - LOGGER.info("Sending pony data to server for player"); - } - + LOGGER.info("Sending pony data to server for player"); ClientPlayNetworking.send(CLIENT_PONY_DATA, new MsgPonyData(packet, noSkin).toBuffer(PacketByteBufs.create())); return true; } diff --git a/src/main/java/com/minelittlepony/client/render/EquineRenderManager.java b/src/main/java/com/minelittlepony/client/render/EquineRenderManager.java index c72f06d6..5c8e6309 100644 --- a/src/main/java/com/minelittlepony/client/render/EquineRenderManager.java +++ b/src/main/java/com/minelittlepony/client/render/EquineRenderManager.java @@ -140,7 +140,7 @@ public class EquineRenderManager