aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt
diff options
context:
space:
mode:
authorThunderblade73 <85900443+Thunderblade73@users.noreply.github.com>2024-02-25 12:52:08 +0100
committerGitHub <noreply@github.com>2024-02-25 12:52:08 +0100
commit67261413a76819ad2ef16182f56e2c4b61b21012 (patch)
tree69ff80409ace002885793dfef0df2af20f0ad65a /src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt
parent2a8edee6275a4abe3375351455c27d2ee56f9c36 (diff)
downloadskyhanni-67261413a76819ad2ef16182f56e2c4b61b21012.tar.gz
skyhanni-67261413a76819ad2ef16182f56e2c4b61b21012.tar.bz2
skyhanni-67261413a76819ad2ef16182f56e2c4b61b21012.zip
Fixed multiple edge cases with /gfs. (#1055)
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt b/src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt
index 53cab5d02..433ac6c09 100644
--- a/src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt
+++ b/src/main/java/at/hannibal2/skyhanni/api/GetFromSackAPI.kt
@@ -90,7 +90,7 @@ object GetFromSackAPI {
if (!LorenzUtils.inSkyBlock) return
if (queue.isNotEmpty() && lastTimeOfCommand.passedSince() >= minimumDelay) {
val item = queue.poll()
- ChatUtils.sendCommandToServer("gfs ${item.internalName.asString()} ${item.amount}")
+ ChatUtils.sendCommandToServer("gfs ${item.internalName.asString().replace('-', ':')} ${item.amount}")
lastTimeOfCommand = ChatUtils.getTimeWhenNewlyQueuedMessageGetsExecuted()
}
}
@@ -176,7 +176,7 @@ object GetFromSackAPI {
return CommandResult.WRONG_AMOUNT to null
}
- val itemString = args.dropLast(1).joinToString(" ").uppercase()
+ val itemString = args.dropLast(1).joinToString(" ").uppercase().replace(':', '-')
val item = when {
sackListInternalNames.contains(itemString) -> itemString.asInternalName()