diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-02-26 22:52:44 +0100 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-02-26 22:52:44 +0100 |
commit | 9bb15c6cb1003b40dda07f14bf3abbe50652cb1d (patch) | |
tree | 82fd998649ea167ef87f017725c8779d7e238a29 /src/main/java/at/hannibal2/skyhanni | |
parent | 146f3cace9a0265a720e0d80555456eb6ba821fe (diff) | |
download | skyhanni-9bb15c6cb1003b40dda07f14bf3abbe50652cb1d.tar.gz skyhanni-9bb15c6cb1003b40dda07f14bf3abbe50652cb1d.tar.bz2 skyhanni-9bb15c6cb1003b40dda07f14bf3abbe50652cb1d.zip |
Griffin burrow waypoint tip block moves slower.
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/event/diana/GriffinBurrowHelper.kt | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/event/diana/GriffinBurrowHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/event/diana/GriffinBurrowHelper.kt index f7b21476c..62b914f7d 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/event/diana/GriffinBurrowHelper.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/event/diana/GriffinBurrowHelper.kt @@ -26,6 +26,7 @@ class GriffinBurrowHelper { private var lastDug: LorenzVec? = null private var teleportedLocation: LorenzVec? = null private var lastGuessTime = 0L + private var lastAnimationTime = 0L @SubscribeEvent fun onSoopyGuessBurrow(event: SoopyGuessBurrowEvent) { @@ -135,7 +136,7 @@ class GriffinBurrowHelper { val distance = location.distance(playerLocation) val burrowType = burrow.value // if (distance < 30) { - event.drawColor(location, burrowType.color, distance > 10) + event.drawColor(location, burrowType.color, distance > 10) // } event.drawDynamicText(location.add(0, 1, 0), burrowType.text, 1.5) // if (distance < 10) { @@ -151,7 +152,7 @@ class GriffinBurrowHelper { event.drawColor(guessLocation, LorenzColor.WHITE, distance > 10) event.drawDynamicText(guessLocation.add(0, 1, 0), "Guess", 1.5) if (distance > 5) { - val formattedDistance = LorenzUtils.formatDouble(distance) + val formattedDistance = LorenzUtils.formatInteger(distance.toInt()) event.drawDynamicText(guessLocation.add(0, 1, 0), "§e${formattedDistance}m", 1.7, yOff = 10f) } } @@ -211,8 +212,13 @@ class GriffinBurrowHelper { event.draw3DLine(animation.add(0.5, 0.5, 0.5), target.add(0.5, 0.5, 0.5), LorenzColor.WHITE.toColor(), 2, true) - vector = vector.multiply(1 / vector.length()) - vector = vector.multiply(0.18) - return animation.add(vector) + return if (System.currentTimeMillis() > lastAnimationTime + 25) { + lastAnimationTime = System.currentTimeMillis() + vector = vector.multiply(1 / vector.length()) + vector = vector.multiply(0.18) + animation.add(vector) + } else { + animation + } } }
\ No newline at end of file |