From 168455eeed4af33ba49ad8a8bc9f2b6b1a051152 Mon Sep 17 00:00:00 2001 From: Walker Selby Date: Tue, 17 Oct 2023 10:30:09 +0100 Subject: Bug Fix: Fix DanceHelper (#590) Fixed Dance Room Helper in Rift showing wrong stuff. #590 --- .../features/rift/area/mirrorverse/DanceRoomHelper.kt | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'src/main/java/at') diff --git a/src/main/java/at/hannibal2/skyhanni/features/rift/area/mirrorverse/DanceRoomHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/rift/area/mirrorverse/DanceRoomHelper.kt index 9abad8212..f7acdfd1d 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/rift/area/mirrorverse/DanceRoomHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/rift/area/mirrorverse/DanceRoomHelper.kt @@ -12,12 +12,7 @@ import at.hannibal2.skyhanni.utils.LocationUtils.isPlayerInside import at.hannibal2.skyhanni.utils.RenderUtils.renderStrings import at.hannibal2.skyhanni.utils.StringUtils.firstLetterUppercase import at.hannibal2.skyhanni.utils.jsonobjects.DanceRoomInstructionsJson -import kotlinx.coroutines.CoroutineScope -import kotlinx.coroutines.Dispatchers -import kotlinx.coroutines.Job -import kotlinx.coroutines.NonCancellable -import kotlinx.coroutines.delay -import kotlinx.coroutines.launch +import kotlinx.coroutines.* import net.minecraft.client.entity.EntityOtherPlayerMP import net.minecraft.util.AxisAlignedBB import net.minecraftforge.fml.common.eventhandler.SubscribeEvent @@ -80,7 +75,7 @@ object DanceRoomHelper { "Jump" -> jump "Punch" -> punch else -> fallback - } + this + } + this@addColor } @SubscribeEvent @@ -172,7 +167,7 @@ object DanceRoomHelper { fun start(interval: Long): Job { return CoroutineScope(Dispatchers.Default).launch { - while (NonCancellable.isActive && found) { + while (isActive && found) { index++ startCountdown(0, 500) delay(interval) -- cgit