diff options
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/kr/syeyoung/dungeonsguide/EventListener.java | 3 | ||||
-rw-r--r-- | src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/icefill/RoomProcessorIcePath2.java | 3 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/main/java/kr/syeyoung/dungeonsguide/EventListener.java b/src/main/java/kr/syeyoung/dungeonsguide/EventListener.java index d1daa7d6..5f37ea82 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/EventListener.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/EventListener.java @@ -126,17 +126,20 @@ public class EventListener { EntityPlayerSP thePlayer = Minecraft.getMinecraft().thePlayer; Point roomPt = context.getMapProcessor().worldPointToRoomPoint(thePlayer.getPosition()); + RoomProcessor roomProcessor = null; try { DungeonRoom dungeonRoom = context.getRoomMapper().get(roomPt); if (dungeonRoom != null) { if (dungeonRoom.getRoomProcessor() != null) { dungeonRoom.getRoomProcessor().chatReceived(clientChatReceivedEvent.message); + roomProcessor = dungeonRoom.getRoomProcessor(); } } } catch (Throwable t) { t.printStackTrace(); } for (RoomProcessor globalRoomProcessor : context.getGlobalRoomProcessors()) { + if (globalRoomProcessor == roomProcessor) continue;; try { globalRoomProcessor.chatReceived(clientChatReceivedEvent.message); } catch (Throwable t) { diff --git a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/icefill/RoomProcessorIcePath2.java b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/icefill/RoomProcessorIcePath2.java index 7671cc80..c0cf99a5 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/icefill/RoomProcessorIcePath2.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/icefill/RoomProcessorIcePath2.java @@ -8,6 +8,7 @@ import kr.syeyoung.dungeonsguide.utils.RenderUtils; import net.minecraft.client.Minecraft; import net.minecraft.init.Blocks; import net.minecraft.util.BlockPos; +import net.minecraft.util.ChatComponentText; import java.awt.*; import java.util.ArrayList; @@ -80,7 +81,7 @@ public class RoomProcessorIcePath2 extends GeneralRoomProcessor { public void tick() { super.tick(); while (!messageQueue.isEmpty()){ - Minecraft.getMinecraft().thePlayer.sendChatMessage(messageQueue.poll()); + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(messageQueue.poll())); } } |