diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperConfig.java b/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperConfig.java index cf2a86d0bf..c5bc6f990c 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperConfig.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperConfig.java @@ -90,4 +90,15 @@ public interface WorldHopperConfig extends Config { return true; } + + @ConfigItem( + keyName = "showMessage", + name = "Show world hop message in chat", + description = "Shows what world is being hopped to in the chat", + position = 5 + ) + default boolean showWorldHopMessage() + { + return true; + } } diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperPlugin.java b/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperPlugin.java index 83a7b0cc11..07f4d727a5 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperPlugin.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/worldhopper/WorldHopperPlugin.java @@ -616,20 +616,23 @@ public class WorldHopperPlugin extends Plugin return; } - String chatMessage = new ChatMessageBuilder() - .append(ChatColorType.NORMAL) - .append("Quick-hopping to World ") - .append(ChatColorType.HIGHLIGHT) - .append(Integer.toString(world.getId())) - .append(ChatColorType.NORMAL) - .append("..") - .build(); + if (config.showWorldHopMessage()) + { + String chatMessage = new ChatMessageBuilder() + .append(ChatColorType.NORMAL) + .append("Quick-hopping to World ") + .append(ChatColorType.HIGHLIGHT) + .append(Integer.toString(world.getId())) + .append(ChatColorType.NORMAL) + .append("..") + .build(); - chatMessageManager - .queue(QueuedMessage.builder() - .type(ChatMessageType.GAME) - .runeLiteFormattedMessage(chatMessage) - .build()); + chatMessageManager + .queue(QueuedMessage.builder() + .type(ChatMessageType.GAME) + .runeLiteFormattedMessage(chatMessage) + .build()); + } quickHopTargetWorld = rsWorld; displaySwitcherAttempts = 0;