diff --git a/src/main/java/com/minelittlepony/api/events/Channel.java b/src/main/java/com/minelittlepony/api/events/Channel.java index 1e3d29a2..ce1ac4b8 100644 --- a/src/main/java/com/minelittlepony/api/events/Channel.java +++ b/src/main/java/com/minelittlepony/api/events/Channel.java @@ -54,18 +54,18 @@ public class Channel { }); } + public static boolean isRegistered() { + return registered; + } + public static boolean broadcastPonyData(PonyData packet) { + 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"); - } - ClientPlayNetworking.send(CLIENT_PONY_DATA, MsgPonyData.write(packet, 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 da0a8579..dae39170 100644 --- a/src/main/java/com/minelittlepony/client/render/EquineRenderManager.java +++ b/src/main/java/com/minelittlepony/client/render/EquineRenderManager.java @@ -197,7 +197,7 @@ public class EquineRenderManager