diff --git a/src/main/java/net/ccbluex/liquidbounce/features/module/modules/combat/KillAura.kt b/src/main/java/net/ccbluex/liquidbounce/features/module/modules/combat/KillAura.kt index 490033a02..9c1ddf0a1 100644 --- a/src/main/java/net/ccbluex/liquidbounce/features/module/modules/combat/KillAura.kt +++ b/src/main/java/net/ccbluex/liquidbounce/features/module/modules/combat/KillAura.kt @@ -137,7 +137,7 @@ class KillAura : Module() { // Rotations private val rotationModeValue = ListValue( "RotationMode", - arrayOf("None", "LiquidBounce", "ForceCenter", "SmoothCenter", "SmoothLiquid", "LockView", "OldMatrix"), + arrayOf("None", "LiquidBounce", "ForceCenter", "SmoothCenter", "SmoothLiquid", "LockView"), "LiquidBounce" ) // TODO: RotationMode Bypass Intave @@ -1038,7 +1038,6 @@ class KillAura : Module() { true ) ?: return false - if (rotationModeValue.get() == "OldMatrix") directRotation.pitch = 89.9f var diffAngle = RotationUtils.getRotationDifference(RotationUtils.serverRotation, directRotation) if (diffAngle < 0) diffAngle = -diffAngle @@ -1067,7 +1066,7 @@ class KillAura : Module() { directRotation, (180.0).toFloat() ) - "SmoothCenter", "SmoothLiquid", "OldMatrix" -> RotationUtils.limitAngleChange( + "SmoothCenter", "SmoothLiquid" -> RotationUtils.limitAngleChange( RotationUtils.serverRotation, directRotation, (calculateSpeed).toFloat() diff --git a/src/main/java/net/ccbluex/liquidbounce/features/module/modules/player/nofalls/other/HypSpoofNofall.kt b/src/main/java/net/ccbluex/liquidbounce/features/module/modules/player/nofalls/other/HypSpoofNofall.kt deleted file mode 100644 index 6c8293465..000000000 --- a/src/main/java/net/ccbluex/liquidbounce/features/module/modules/player/nofalls/other/HypSpoofNofall.kt +++ /dev/null @@ -1,12 +0,0 @@ -package net.ccbluex.liquidbounce.features.module.modules.player.nofalls.other - -import net.ccbluex.liquidbounce.event.PacketEvent -import net.ccbluex.liquidbounce.features.module.modules.player.nofalls.NoFallMode -import net.ccbluex.liquidbounce.utils.PacketUtils -import net.minecraft.network.play.client.C03PacketPlayer - -class HypSpoofNofall : NoFallMode("HypSpoof") { - override fun onPacket(event: PacketEvent) { - if(event.packet is C03PacketPlayer) PacketUtils.sendPacketNoEvent(C03PacketPlayer.C04PacketPlayerPosition(event.packet.x, event.packet.y, event.packet.z, true)) - } -} \ No newline at end of file diff --git a/src/main/java/net/ccbluex/liquidbounce/features/module/modules/player/nofalls/other/HypixelFlagNofall.kt b/src/main/java/net/ccbluex/liquidbounce/features/module/modules/player/nofalls/other/HypixelFlagNofall.kt new file mode 100644 index 000000000..525199617 --- /dev/null +++ b/src/main/java/net/ccbluex/liquidbounce/features/module/modules/player/nofalls/other/HypixelFlagNofall.kt @@ -0,0 +1,35 @@ +package net.ccbluex.liquidbounce.features.module.modules.player.nofalls.other + +import net.ccbluex.liquidbounce.event.PacketEvent +import net.ccbluex.liquidbounce.event.UpdateEvent +import net.ccbluex.liquidbounce.features.module.modules.player.nofalls.NoFallMode +import net.ccbluex.liquidbounce.utils.PacketUtils +import net.ccbluex.liquidbounce.utils.misc.FallingPlayer +import net.minecraft.network.play.client.C03PacketPlayer +import kotlin.math.abs + +class HypixelFlagNofall : NoFallMode("HypixelFlag") { + + private var sendPacket = false + + override fun onUpdate(event: UpdateEvent) { + if (mc.thePlayer.onGround) { + sendPacket = false + } + } + + override fun onPacket(event: PacketEvent) { + if (event.packet is C03PacketPlayer) { + val fallingPlayer = FallingPlayer(mc.thePlayer) + val collLoc = fallingPlayer.findCollision(60) // null -> too far to calc or fall pos in void + if (abs((collLoc?.y ?: 0) - mc.thePlayer.posY) < 3 && mc.thePlayer.fallDistance > 4 && !sendPacket) { + event.cancelEvent() + mc.netHandler.addToSendQueue(C03PacketPlayer.C04PacketPlayerPosition(event.packet.x, event.packet.y, event.packet.z, false)) + mc.netHandler.addToSendQueue(C03PacketPlayer.C04PacketPlayerPosition(event.packet.x, event.packet.y, event.packet.z - 23, true)) + mc.netHandler.addToSendQueue(C03PacketPlayer.C04PacketPlayerPosition(event.packet.x, event.packet.y, event.packet.z, false)) + + sendPacket = true + } + } + } +}