diff options
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/rift/area/stillgorechateau/RiftBloodEffigies.kt | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/rift/area/stillgorechateau/RiftBloodEffigies.kt b/src/main/java/at/hannibal2/skyhanni/features/rift/area/stillgorechateau/RiftBloodEffigies.kt index be05e11fb..de0c57850 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/rift/area/stillgorechateau/RiftBloodEffigies.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/rift/area/stillgorechateau/RiftBloodEffigies.kt @@ -2,6 +2,7 @@ package at.hannibal2.skyhanni.features.rift.area.stillgorechateau import at.hannibal2.skyhanni.config.ConfigUpdaterMigrator import at.hannibal2.skyhanni.data.jsonobjects.repo.RiftEffigiesJson +import at.hannibal2.skyhanni.events.DebugDataCollectEvent import at.hannibal2.skyhanni.events.LorenzRenderWorldEvent import at.hannibal2.skyhanni.events.LorenzTickEvent import at.hannibal2.skyhanni.events.LorenzWorldChangeEvent @@ -28,7 +29,6 @@ class RiftBloodEffigies { private val config get() = RiftAPI.config.area.stillgoreChateau.bloodEffigies - private var locations: List<LorenzVec> = emptyList() private var effigiesTimes = mapOf( 0 to -1L, @@ -64,6 +64,23 @@ class RiftBloodEffigies { } @SubscribeEvent + fun onDebugDataCollect(event: DebugDataCollectEvent) { + event.title("Rift Blood Effigies") + + if (!isEnabled()) { + event.addIrrelevant("Not in Stillgore Château or not enabled ") + return + } + event.addData { + for ((number, duration) in effigiesTimes) { + val diff = duration - System.currentTimeMillis() + val time = TimeUtils.formatDuration(diff - 999) + add("$number: $time ($duration)") + } + } + } + + @SubscribeEvent fun onRepoReload(event: RepositoryReloadEvent) { val newLocations = event.getConstant<RiftEffigiesJson>("RiftEffigies").locations if (newLocations.size != 6) { |