From 252dedff670a8a456ae557b8ac7f1727bb7fd1b1 Mon Sep 17 00:00:00 2001 From: RoseGoldIsntGay Date: Sat, 15 Jan 2022 00:19:33 +0200 Subject: 2.5.2-pre1 --- src/main/java/rosegoldaddons/utils/ChatUtils.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/main/java/rosegoldaddons/utils/ChatUtils.java') diff --git a/src/main/java/rosegoldaddons/utils/ChatUtils.java b/src/main/java/rosegoldaddons/utils/ChatUtils.java index 4295c77..43107eb 100644 --- a/src/main/java/rosegoldaddons/utils/ChatUtils.java +++ b/src/main/java/rosegoldaddons/utils/ChatUtils.java @@ -18,7 +18,9 @@ public class ChatUtils { /* § */ public static void sendMessage(String message) { - Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("§f[§aRoseGoldAddons§f] "+message)); + if (Minecraft.getMinecraft().thePlayer != null) { + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("§f[§aRoseGoldAddons§f] " + message)); + } } public static ChatStyle createClickStyle(ClickEvent.Action action, String value) { -- cgit