aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/utils
diff options
context:
space:
mode:
authorNetheriteMiner <88792142+NetheriteMiner@users.noreply.github.com>2023-05-06 15:31:25 -0400
committerGitHub <noreply@github.com>2023-05-06 21:31:25 +0200
commitfec41716f40ed43791fd37071b06e8516d207807 (patch)
treed59e894f8a106e4391a745fff48d256dfd18c043 /src/main/java/at/hannibal2/skyhanni/utils
parentd462d17308d2ac2754f73a64b61ac343677e0f30 (diff)
downloadskyhanni-fec41716f40ed43791fd37071b06e8516d207807.tar.gz
skyhanni-fec41716f40ed43791fd37071b06e8516d207807.tar.bz2
skyhanni-fec41716f40ed43791fd37071b06e8516d207807.zip
Add Auto, Pet, and Crop Milestones to RPC. (#83)
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/utils')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/utils/LorenzUtils.kt14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/utils/LorenzUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/LorenzUtils.kt
index cdd3af5d9..4a67184f2 100644
--- a/src/main/java/at/hannibal2/skyhanni/utils/LorenzUtils.kt
+++ b/src/main/java/at/hannibal2/skyhanni/utils/LorenzUtils.kt
@@ -265,4 +265,18 @@ object LorenzUtils {
fun <K, V> Map<K, V>.editCopy(function: MutableMap<K, V>.() -> Unit) =
toMutableMap().also { function(it) }.toMap()
+
+ fun colorCodeToRarity(colorCode: Char): String {
+ return when (colorCode) {
+ 'f' -> "Common"
+ 'a' -> "Uncommon"
+ '9' -> "Rare"
+ '5' -> "Epic"
+ '6' -> "Legendary"
+ 'd' -> "Mythic"
+ 'b' -> "Divine"
+ '4' -> "Supreme" // legacy items
+ else -> "Special"
+ }
+ }
} \ No newline at end of file