KeepSprint module

KeepSprint: Minecraft 26.3 cheat module, full source for every implementation (1 client: LiquidBounce (Kotlin)).

1 implementationCOMBAT

Clients with this module

Full module source: 1 implementation

Every implementation below is the complete module file, verbatim. Expand a client to read its code.

LiquidBounce (Kotlin)COMBATsrc/main/kotlin/net/ccbluex/liquidbounce/features/module/modules/combat/ModuleKeepSprint.ktKotlin · 57 lines · 2.1 KB

Keeps you sprinting even when attacking.

SettingsMotionMotionWhenHurtHurtTime
ModuleKeepSprint.ktKotlin · Minecraft 26.2 · 57 lines · 2.1 KB · complete file, verbatimOriginal ↗
1
/*
2
 * This file is part of LiquidBounce (https://github.com/CCBlueX/LiquidBounce)
3
 *
4
 * Copyright (c) 2015 - 2026 CCBlueX
5
 *
6
 * LiquidBounce is free software: you can redistribute it and/or modify
7
 * it under the terms of the GNU General Public License as published by
8
 * the Free Software Foundation, either version 3 of the License, or
9
 * (at your option) any later version.
10
 *
11
 * LiquidBounce is distributed in the hope that it will be useful,
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
 * GNU General Public License for more details.
15
 *
16
 * You should have received a copy of the GNU General Public License
17
 * along with LiquidBounce. If not, see <https://www.gnu.org/licenses/>.
18
 */
19
20
package net.ccbluex.liquidbounce.features.module.modules.combat
21
22
import net.ccbluex.liquidbounce.config.utils.percentageChance
23
import net.ccbluex.liquidbounce.event.events.PlayerPostTickEvent
24
import net.ccbluex.liquidbounce.event.handler
25
import net.ccbluex.liquidbounce.features.module.ClientModule
26
import net.ccbluex.liquidbounce.features.module.ModuleCategories
27
import net.ccbluex.liquidbounce.utils.kotlin.random
28
29
/**
30
 * When hitting an entity, the player will keep sprinting
31
 */
32
object ModuleKeepSprint : ClientModule("KeepSprint", ModuleCategories.COMBAT) {
33
    private val motion by floatRange("Motion", 100f..100f, 0f..100f, "%")
34
    private val motionWhenHurt by floatRange("MotionWhenHurt", 100f..100f, 0f..100f, "%")
35
    private val hurtTime by intRange("HurtTime", 1..10, 1..10)
36
    private val chance = percentageChance("Chance", 100f)
37
38
    // prevents getting slowed multiple times in a tick (without knockback item)
39
    var sprinting = false
40
41
    @Suppress("unused")
42
    private val postTickHandler = handler<PlayerPostTickEvent> {
43
        sprinting = player.isSprinting
44
    }
45
46
    fun getMotion(): Double {
47
        if (!chance.asBoolean) {
48
            return 0.6
49
        }
50
51
        return when {
52
            player.hurtTime in hurtTime -> motionWhenHurt
53
            else -> motion
54
        }.random() / 100.0
55
    }
56
}
57