diff --git a/src/main/java/me/zeroeightsix/kami/module/modules/player/NoSwing.java b/src/main/java/me/zeroeightsix/kami/module/modules/player/NoSwing.java new file mode 100644 index 00000000..8f0ca51e --- /dev/null +++ b/src/main/java/me/zeroeightsix/kami/module/modules/player/NoSwing.java @@ -0,0 +1,23 @@ +package me.zeroeightsix.kami.module.modules.player; + +import me.zero.alpine.listener.EventHandler; +import me.zero.alpine.listener.Listener; +import me.zeroeightsix.kami.event.events.PacketEvent; +import me.zeroeightsix.kami.module.Module; +import net.minecraft.network.play.client.CPacketAnimation; + +/** + * Created 13 August 2019 by hub + * Updated 14 November 2019 by hub + */ +@Module.Info(name = "NoSwing", category = Module.Category.PLAYER, description = "Prevents arm swing animation server side") +public class NoSwing extends Module { + + @EventHandler + public Listener listener = new Listener<>(event -> { + if (event.getPacket() instanceof CPacketAnimation) { + event.cancel(); + } + }); + +}