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
3be7d50
commit a7a690b
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
35 changes: 35 additions & 0 deletions
35
.../java/net/ccbluex/liquidbounce/features/module/modules/movement/noslowmodes/other/Slot.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,35 @@ | ||
/* | ||
* 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.movement.noslowmodes.other | ||
|
||
import net.ccbluex.liquidbounce.event.EventState.* | ||
import net.ccbluex.liquidbounce.event.MotionEvent | ||
import net.ccbluex.liquidbounce.features.module.modules.movement.NoSlow.blockingPacketTiming | ||
import net.ccbluex.liquidbounce.features.module.modules.movement.NoSlow.bowPacketTiming | ||
import net.ccbluex.liquidbounce.features.module.modules.movement.NoSlow.consumePacketTiming | ||
import net.ccbluex.liquidbounce.features.module.modules.movement.noslowmodes.NoSlowMode | ||
import net.ccbluex.liquidbounce.utils.PacketUtils.sendPacket | ||
import net.ccbluex.liquidbounce.utils.inventory.InventoryUtils.serverSlot | ||
import net.minecraft.item.* | ||
import net.minecraft.network.play.client.C09PacketHeldItemChange | ||
|
||
object Slot : NoSlowMode("Slot") { | ||
override fun onMotion(event: MotionEvent) { | ||
when (mc.thePlayer.heldItem.item) { | ||
is ItemSword -> | ||
if ((blockingPacketTiming == "Post" && event.eventState != POST) || (blockingPacketTiming == "Pre" && event.eventState != PRE)) | ||
return | ||
is ItemBow -> | ||
if ((bowPacketTiming == "Post" && event.eventState != POST) || (bowPacketTiming == "Pre" && event.eventState != PRE)) | ||
return | ||
is ItemFood, is ItemBucketMilk, is ItemPotion -> | ||
if ((consumePacketTiming == "Post" && event.eventState != POST) || (consumePacketTiming == "Pre" && event.eventState != PRE)) | ||
return | ||
} | ||
// has to be noevent for some reason | ||
sendPacket(C09PacketHeldItemChange(serverSlot), false) | ||
} | ||
} |