diff options
author | inglettronald <inglettronald@gmail.com> | 2023-02-23 02:30:32 -0600 |
---|---|---|
committer | inglettronald <inglettronald@gmail.com> | 2023-02-23 02:30:32 -0600 |
commit | f0c36d2586a46dbe48d745866fbd62e74aa466c6 (patch) | |
tree | 6b155148c7d6b9bb3f0c584ff8eee91cf695c63b /src/main/kotlin/dulkirmod/DulkirMod.kt | |
parent | 7df778d6ac01a6d350608a5962b9344493444ebc (diff) | |
download | DulkirMod-f0c36d2586a46dbe48d745866fbd62e74aa466c6.tar.gz DulkirMod-f0c36d2586a46dbe48d745866fbd62e74aa466c6.tar.bz2 DulkirMod-f0c36d2586a46dbe48d745866fbd62e74aa466c6.zip |
Major tablist-related refactor and Garden notification stuff
Diffstat (limited to 'src/main/kotlin/dulkirmod/DulkirMod.kt')
-rw-r--r-- | src/main/kotlin/dulkirmod/DulkirMod.kt | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/main/kotlin/dulkirmod/DulkirMod.kt b/src/main/kotlin/dulkirmod/DulkirMod.kt index 51df365..014b06d 100644 --- a/src/main/kotlin/dulkirmod/DulkirMod.kt +++ b/src/main/kotlin/dulkirmod/DulkirMod.kt @@ -6,9 +6,9 @@ import dulkirmod.events.ChatEvent import dulkirmod.features.* import dulkirmod.features.chat.AbiphoneDND import dulkirmod.utils.ContainerNameUtil +import dulkirmod.utils.TabListUtils import dulkirmod.utils.TextUtils import dulkirmod.utils.TitleUtils -import dulkirmod.utils.Utils.getArea import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.launch @@ -74,6 +74,7 @@ class DulkirMod { mcBus.register(AbiphoneDND()) mcBus.register(KeeperWaypoints()) mcBus.register(ScalableTooltips) + mcBus.register(GardenVisitorAlert()) keyBinds.forEach(ClientRegistry::registerKeyBinding) } @@ -98,7 +99,10 @@ class DulkirMod { alarmClock() brokenHypeNotif() matchoAlert.alert() - getArea() + gardenVisitorAlert.alert() + // Now I don't have to fetch the entries for multiple things, this just updates and caches + // the data structure on 1s cooldown + TabListUtils.parseTabEntries() lastLongUpdate = currTime } } @@ -124,6 +128,8 @@ class DulkirMod { val scope = CoroutineScope(EmptyCoroutineContext) val titleUtils = TitleUtils() val matchoAlert = MatchoAlert() + val gardenVisitorAlert = GardenVisitorAlert() + var tabEntries: List<String?> = emptyList() val keyBinds = arrayOf( KeyBinding("Open Settings", Keyboard.KEY_RSHIFT, "Dulkir Mod"), |