mirror of https://github.com/kami-blue/client
add nopush
This commit is contained in:
parent
4de9c14996
commit
deb15b183d
|
@ -17,6 +17,7 @@ import net.minecraft.network.play.server.SPacketExplosion;
|
|||
@Module.Info(name = "Velocity", description = "Modify knockback impact", category = Module.Category.MOVEMENT)
|
||||
public class Velocity extends Module {
|
||||
|
||||
private Setting<Boolean> noPush = register(Settings.b("NoPush", true));
|
||||
private Setting<Float> horizontal = register(Settings.f("Horizontal", 0));
|
||||
private Setting<Float> vertical = register(Settings.f("Vertical", 0));
|
||||
|
||||
|
@ -44,7 +45,7 @@ public class Velocity extends Module {
|
|||
@EventHandler
|
||||
private Listener<EntityEvent.EntityCollision> entityCollisionListener = new Listener<>(event -> {
|
||||
if (event.getEntity() == mc.player) {
|
||||
if (horizontal.getValue() == 0 && vertical.getValue() == 0) {
|
||||
if ((horizontal.getValue() == 0 && vertical.getValue() == 0) || noPush.getValue()) {
|
||||
event.cancel();
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue