blob: 86065a3a2b05483a4405222eb144ddc84855a93f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
package com.ambientaddons.utils
enum class Area {
Dungeon,
PrivateIsland,
DungeonHub,
GoldMine,
DeepCaverns,
DwarvenMines,
CrystalHollows,
SpiderDen,
CrimsonIsle,
End,
Park,
FarmingIslands,
Kuudra;
companion object {
fun fromString(str: String?): Area? = when (str) {
"Crimson Isle" -> CrimsonIsle
"Catacombs" -> Dungeon
"Private Island" -> PrivateIsland
"Dungeon Hub" -> DungeonHub
"Gold Mine" -> GoldMine
"Deep Caverns" -> DeepCaverns
"Dwarven Mines" -> DwarvenMines
"Crystal Hollows" -> CrystalHollows
"Spider's Den" -> SpiderDen
"The Park" -> Park
"The End" -> End
"The Farming Islands" -> FarmingIslands
"Instanced" -> Kuudra
else -> null
}
}
}
|