This repository has been archived by the owner on Aug 14, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ce5777b
commit f0bd7ba
Showing
2 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
...ava/net/ccbluex/liquidbounce/features/module/modules/player/nofallmodes/other/Cardinal.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
/* | ||
* SkidBounce Hacked Client | ||
* A free open source mixin-based injection hacked client for Minecraft using Minecraft Forge, Forked from LiquidBounce. | ||
* https://github.com/ManInMyVan/SkidBounce/ | ||
*/ | ||
package net.ccbluex.liquidbounce.features.module.modules.player.nofallmodes.other | ||
|
||
import net.ccbluex.liquidbounce.event.PacketEvent | ||
import net.ccbluex.liquidbounce.features.module.modules.player.nofallmodes.NoFallMode | ||
import net.minecraft.network.play.client.C03PacketPlayer | ||
import net.minecraft.network.play.server.S08PacketPlayerPosLook | ||
|
||
/** | ||
* @author ManInMyVan/SkidBounce | ||
* @author ManInMyVan | ||
*/ | ||
object Cardinal : NoFallMode("Cardinal") { | ||
private var falling = false | ||
|
||
override fun onEnable() { | ||
falling = false | ||
} | ||
|
||
override fun onUpdate() { | ||
if (mc.thePlayer.fallDistance > 3) | ||
falling = true | ||
} | ||
|
||
override fun onPacket(event: PacketEvent) { | ||
if (event.packet is C03PacketPlayer && falling && event.packet.onGround && mc.thePlayer.onGround) { | ||
falling = false | ||
mc.thePlayer.onGround = false | ||
event.packet.y = Double.POSITIVE_INFINITY | ||
event.packet.onGround = false | ||
} | ||
} | ||
} |