aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/utils
diff options
context:
space:
mode:
authorEmpa <42304516+ItsEmpa@users.noreply.github.com>2024-04-08 21:11:08 +0200
committerGitHub <noreply@github.com>2024-04-08 21:11:08 +0200
commit4d2c73dc271c1255c86ca9d811468e8b36d48640 (patch)
tree425bfb580aafac65232286900cc77718e0acf083 /src/main/java/at/hannibal2/skyhanni/utils
parentfc65c99130a46bb7234f2f593362a8824bc620d1 (diff)
downloadskyhanni-4d2c73dc271c1255c86ca9d811468e8b36d48640.tar.gz
skyhanni-4d2c73dc271c1255c86ca9d811468e8b36d48640.tar.bz2
skyhanni-4d2c73dc271c1255c86ca9d811468e8b36d48640.zip
Fix: Duplicate Custom Keybinds (#1387)
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/utils')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt
index 3a88fd51f..d2dd5c9b0 100644
--- a/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt
+++ b/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt
@@ -53,6 +53,19 @@ object ChatUtils {
}
/**
+ * Sends a message to the user that they did something incorrectly.
+ * Runs a command when clicked to fix the issue.
+ *
+ * @param message The message to be sent
+ * @param command The command to be executed when the message is clicked
+ *
+ * @see USER_ERROR_PREFIX
+ */
+ fun clickableUserError(message: String, command: String) {
+ internalChat(createClickableChat(USER_ERROR_PREFIX + message, command))
+ }
+
+ /**
* Sends a message to the user that an error occurred caused by something in the code.
* This should be used for errors that are not caused by the user.
*