diff options
| author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-09-16 12:34:18 +0200 |
|---|---|---|
| committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-09-16 12:34:18 +0200 |
| commit | 4293cfd919c3c93d4532534f722c407d7ad1370d (patch) | |
| tree | f9f612f021ef7f4283d74312edfaca30badc6749 /src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt | |
| parent | 538e3ceb76f8e0b590291ce9aa90aa94896cdcb6 (diff) | |
| parent | 024ba52fb69b6cd44b4e31542867f802de656f15 (diff) | |
| download | SkyHanni-cum.tar.gz SkyHanni-cum.tar.bz2 SkyHanni-cum.zip | |
Merge branch 'beta' into cumcum
# Conflicts:
# src/main/java/at/hannibal2/skyhanni/config/ConfigManager.kt
# src/main/java/at/hannibal2/skyhanni/config/features/AshfangConfig.java
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt')
| -rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt b/src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt index 9948695bb..6d93816b7 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/slayer/VampireSlayerFeatures.kt @@ -18,6 +18,7 @@ import at.hannibal2.skyhanni.utils.RenderUtils.draw3DLine import at.hannibal2.skyhanni.utils.RenderUtils.drawColor import at.hannibal2.skyhanni.utils.RenderUtils.drawDynamicText import at.hannibal2.skyhanni.utils.RenderUtils.exactLocation +import at.hannibal2.skyhanni.utils.RenderUtils.exactPlayerEyeLocation import at.hannibal2.skyhanni.utils.SoundUtils.playSound import kotlinx.coroutines.* import net.minecraft.client.Minecraft @@ -127,8 +128,12 @@ object VampireSlayerFeatures { if (shouldSendSound) playTwinclawsSound() if (shouldSendTitle) - TitleUtils.sendTitle("§6§lTWINCLAWS", (1750 - config.twinclawsDelay), 2.6) - nextClawSend = System.currentTimeMillis() + 5000 + TitleUtils.sendTitle( + "§6§lTWINCLAWS", + (1750 - config.twinclawsDelay).milliseconds, + 2.6 + ) + nextClawSend = System.currentTimeMillis() + 5_000 } } } @@ -178,7 +183,7 @@ object VampireSlayerFeatures { else canUseSteak && configCoopBoss.steakAlert && containCoop if (shouldSendSteakTitle) - TitleUtils.sendTitle("§c§lSTEAK!", 300, 2.6) + TitleUtils.sendTitle("§c§lSTEAK!", 300.milliseconds, 2.6) if (shouldRender) { RenderLivingEntityHelper.setEntityColor(this, color) { isEnabled() } @@ -278,10 +283,8 @@ object VampireSlayerFeatures { val vec = event.exactLocation(it) val distance = start.distance(vec) if (distance <= 15) { - val player = Minecraft.getMinecraft().thePlayer - val add = if (player.isSneaking) LorenzVec(0.0, 1.54, 0.0) else LorenzVec(0.0, 1.62, 0.0) event.draw3DLine( - event.exactLocation(player).add(add), + event.exactPlayerEyeLocation(), vec.add(0.0, 1.54, 0.0), config.lineColor.toChromaColor(), config.lineWidth, |
