From 7d86ae4873f105c7c09a945998c747c88ad80808 Mon Sep 17 00:00:00 2001 From: trimbe Date: Tue, 2 Oct 2018 04:17:03 -0400 Subject: [PATCH] Chat Commands: Add hints to config description (#5747) Adds usage hints to the config description for each of the chat commands. Closes #4298 --- .../plugins/chatcommands/ChatCommandsConfig.java | 8 ++++---- .../plugins/chatcommands/ChatCommandsPlugin.java | 12 ++++++------ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsConfig.java b/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsConfig.java index 1aba2b1d54..48c5c39b7d 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsConfig.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsConfig.java @@ -35,7 +35,7 @@ public interface ChatCommandsConfig extends Config position = 0, keyName = "price", name = "Price Command", - description = "Configures whether the Price command is enabled" + description = "Configures whether the Price command is enabled
!price [item]" ) default boolean price() { @@ -46,7 +46,7 @@ public interface ChatCommandsConfig extends Config position = 1, keyName = "lvl", name = "Level Command", - description = "Configures whether the Level command is enabled" + description = "Configures whether the Level command is enabled
!lvl [skill]" ) default boolean lvl() { @@ -57,7 +57,7 @@ public interface ChatCommandsConfig extends Config position = 2, keyName = "clue", name = "Clue Command", - description = "Configures whether the Clue command is enabled" + description = "Configures whether the Clue command is enabled
!clues" ) default boolean clue() { @@ -68,7 +68,7 @@ public interface ChatCommandsConfig extends Config position = 3, keyName = "killcount", name = "Killcount Command", - description = "Configures whether the Killcount command is enabled" + description = "Configures whether the Killcount command is enabled
!kc [boss]" ) default boolean killcount() { diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsPlugin.java b/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsPlugin.java index 9ed0520293..7de9f99cd0 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsPlugin.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/chatcommands/ChatCommandsPlugin.java @@ -82,10 +82,10 @@ import net.runelite.http.api.kc.KillCountClient; public class ChatCommandsPlugin extends Plugin implements ChatboxInputListener { private static final float HIGH_ALCHEMY_CONSTANT = 0.6f; - private static final Pattern KILLCOUNT_PATERN = Pattern.compile("Your (.+) kill count is: (\\d+)."); + private static final Pattern KILLCOUNT_PATTERN = Pattern.compile("Your (.+) kill count is: (\\d+)."); private static final Pattern RAIDS_PATTERN = Pattern.compile("Your completed (.+) count is: (\\d+)."); - private static final Pattern WINTERTODT_PATERN = Pattern.compile("Your subdued Wintertodt count is: (\\d+)."); - private static final Pattern BARROWS_PATERN = Pattern.compile("Your Barrows chest count is: (\\d+)."); + private static final Pattern WINTERTODT_PATTERN = Pattern.compile("Your subdued Wintertodt count is: (\\d+)."); + private static final Pattern BARROWS_PATTERN = Pattern.compile("Your Barrows chest count is: (\\d+)."); private static final String TOTAL_LEVEL_COMMAND_STRING = "!total"; private static final String PRICE_COMMAND_STRING = "!price"; private static final String LEVEL_COMMAND_STRING = "!lvl"; @@ -244,7 +244,7 @@ public class ChatCommandsPlugin extends Plugin implements ChatboxInputListener } String message = chatMessage.getMessage(); - Matcher matcher = KILLCOUNT_PATERN.matcher(message); + Matcher matcher = KILLCOUNT_PATTERN.matcher(message); if (matcher.find()) { String boss = matcher.group(1); @@ -253,7 +253,7 @@ public class ChatCommandsPlugin extends Plugin implements ChatboxInputListener setKc(boss, kc); } - matcher = WINTERTODT_PATERN.matcher(message); + matcher = WINTERTODT_PATTERN.matcher(message); if (matcher.find()) { int kc = Integer.parseInt(matcher.group(1)); @@ -270,7 +270,7 @@ public class ChatCommandsPlugin extends Plugin implements ChatboxInputListener setKc(boss, kc); } - matcher = BARROWS_PATERN.matcher(message); + matcher = BARROWS_PATTERN.matcher(message); if (matcher.find()) { int kc = Integer.parseInt(matcher.group(1));