Nekoware v1 private Animations module 1 files, 26 lines

Nekoware v1 private Animations: Full Source Analysis

A two-mode cosmetic held-item animation switcher: on every UpdateEvent it writes a static int (1 for the '1.7' mode, 6 for the 'Sigma' mode) that the client's render path reads to change the swing/held-item pose.

me/nekoWare/client/module/render/Animations.java · GitHub source ↗

Published 2026-08-13 · Updated 2026-10-14

Packets This Module Uses

Analysis

Overview

A two-mode cosmetic held-item animation switcher: on every UpdateEvent it writes a static int (1 for the '1.7' mode, 6 for the 'Sigma' mode) that the client's render path reads to change the swing/held-item pose. It sends no packets; the vanilla C0APacketAnimation swing stream continues unchanged, so swing-packet anticheats observe an identical stream.

Architecture

The module's entire state is a public static int anim. The single UpdateEvent consumer sets it to 1 or 6 depending on which of the two modes (1.7, Sigma) is selected; any render or animation code elsewhere in the client reads Animations.anim to choose its pose. There is no per-tick work beyond the assignment, no onEnable/onDisable logic, and no packet interaction.

The swing packet is untouched

C0APacketAnimation is emitted by the vanilla swing path (attacks, block interactions, right-clicks) through EntityPlayer.swingItem, independently of how the held item is rendered. Because the module only changes the client-side pose, the C0A stream the server receives is byte-identical to vanilla. The real anticheat surface for animation cheats is therefore not this module but the adjacent class that does alter the swing stream: killaura that attacks without swinging (caught by NoSwing checks) and autoclickers that flood swings (caught by swing-frequency checks).

source Animations.java

Animations.java26 lines · JavaOriginal ↗
1
package me.nekoWare.client.module.render;
2
3
import me.hippo.api.lwjeb.annotation.Handler;
4
import me.nekoWare.client.event.events.UpdateEvent;
5
import me.nekoWare.client.module.Module;
6
7
import java.util.function.Consumer;
8
9
public class Animations extends Module {
10
11
    public static int anim;
12
13
    public Animations() {
14
        super("Animations", 0, Category.RENDER);
15
        addModes("1.7", "Sigma");
16
    }
17
18
    @Handler
19
    public Consumer<UpdateEvent> onEvent = (event) -> {
20
        if (isMode("1.7"))
21
            this.anim = 1;
22
23
        if (isMode("Sigma"))
24
            this.anim = 6;
25
    };
26
}

What this file does

A static int plus one consumer. The UpdateEvent handler compares the active mode by name and writes the matching animation id into the shared static, which is the entire public contract of the module. Other Nekoware render code switches its pose off Animations.anim, so toggling the module changes the visual without any per-frame cost or any packet. The mode check is exclusive: with 1.7 selected the value is 1, with Sigma it is 6, and no other value is ever written.

anticheat Countering Checks

The anticheat code that detects or counters the techniques this module uses. Full source, with the detection mechanism explained below each box.

anticheat NoSwing (arm-swing requirement between attacks)

NoSwing.java65 lines · Java
1
/*
2
 * This program is free software: you can redistribute it and/or modify
3
 *   it under the terms of the GNU General Public License as published by
4
 *   the Free Software Foundation, either version 3 of the License, or
5
 *   (at your option) any later version.
6
 *
7
 *   This program is distributed in the hope that it will be useful,
8
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
9
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10
 *   GNU General Public License for more details.
11
 *
12
 *   You should have received a copy of the GNU General Public License
13
 *   along with this program.  If not, see <http://www.gnu.org/licenses/>.
14
 */
15
package fr.neatmonster.nocheatplus.checks.fight;
16
17
import org.bukkit.entity.Player;
18
19
import fr.neatmonster.nocheatplus.checks.Check;
20
import fr.neatmonster.nocheatplus.checks.CheckType;
21
22
/**
23
 * We require that the player moves their arm between attacks, this is basically what gets checked here.
24
 */
25
public class NoSwing extends Check {
26
27
    /**
28
     * Instantiates a new no swing check.
29
     */
30
    public NoSwing() {
31
        super(CheckType.FIGHT_NOSWING);
32
    }
33
34
    /**
35
     * Checks a player.
36
     * 
37
     * @param player
38
     *            the player
39
     * @return true, if successful
40
     */
41
    public boolean check(final Player player, final FightData data, final FightConfig cc) {
42
        boolean cancel = false;
43
44
        if (data.exemptArmSwing) {
45
            data.exemptArmSwing = false;
46
        }
47
        // Did they swing his arm before?
48
        else if (++data.noSwingCount <= 1) {
49
            // Yes, reward them with reduction of their violation level.
50
            data.noSwingVL *= 0.9D;
51
        } 
52
        else {
53
            data.noSwingCount = 0;
54
            // No, increase their violation level.
55
            data.noSwingVL += 1D;
56
57
            // Execute whatever actions are associated with this check and the violation level and find out if we should
58
            // cancel the event.
59
            cancel = executeActions(player, data.noSwingVL, 1D, cc.noSwingActions).willCancel();
60
        }
61
62
        return cancel;
63
    } 
64
65
}

How it counteracts this module

NCP's fight NoSwing enforces that the player moves their arm between attacks: an attack event runs NoSwing.check, and a preceding swing (C0A) rewards a decay of noSwingVL (x0.9), while an attack with no preceding swing accumulates noSwingCount and raises noSwingVL by 1 per attack, executing the configured actions when the level passes the threshold. Honest note: this module never suppresses C0A (the vanilla swing still fires on every attack), so the check stays satisfied and cannot see the pose change. It is the real detector for the animation-cheat class this module's feature sits next to (killaura attacking without arm swings), and the mechanism it relies on is exactly the C0A stream the module leaves intact.

anticheat NoSwing (combat, legacy swing-time window)

NoSwing.java108 lines · Java
1
package arc.check.combat;
2
3
import arc.Arc;
4
import arc.check.Check;
5
import arc.check.result.CheckResult;
6
import arc.check.types.CheckType;
7
import arc.data.combat.CombatData;
8
import bridge.Version;
9
import org.bukkit.entity.Player;
10
11
/**
12
 * Combat check for NoSwing
13
 * <p>
14
 * TODO: Can be improved.
15
 * TODO: Schedule timer after an attack to check if we received a swing packet then.
16
 * TODO: But depending on attack speed, could be bypassed, so maybe check swing packets == attack packets
17
 */
18
public final class NoSwing extends Check {
19
20
    /**
21
     * The max swing time allowed.
22
     */
23
    private long swingTime;
24
25
    public NoSwing() {
26
        super(CheckType.NO_SWING);
27
28
        isEnabled(true)
29
                .cancel(true)
30
                .cancelLevel(0)
31
                .notify(true)
32
                .notifyEvery(1)
33
                .ban(false)
34
                .kick(false)
35
                .build();
36
37
        addConfigurationValue("max-swing-time-old", 100);
38
        addConfigurationValue("max-swing-time-new", 1000);
39
        if (isEnabled()) load();
40
    }
41
42
    /**
43
     * Checks for no swing in legacy mode.
44
     *
45
     * @param player the player
46
     * @param data   their data
47
     * @return the result
48
     */
49
    private boolean checkLegacyNoSwing(Player player, CombatData data) {
50
        final long delta = System.currentTimeMillis() - data.lastSwingTime();
51
        if (delta >= swingTime) {
52
            final CheckResult result = new CheckResult();
53
            result.setFailed("No swing animation within time")
54
                    .withParameter("delta", delta)
55
                    .withParameter("min", swingTime);
56
            return checkViolation(player, result);
57
        }
58
        return false;
59
    }
60
61
    /**
62
     * Checks for no swing in newer versions.
63
     *
64
     * @param player the player
65
     * @param data   their data
66
     * @return the result
67
     */
68
    private boolean checkNewNoSwing(Player player, CombatData data) {
69
        final long now = System.currentTimeMillis();
70
        final long delta = now - data.lastAttackNoSwing();
71
        final long swingDelta = now - data.lastSwingTime();
72
73
        data.lastAttackNoSwing(now);
74
        // we have attacked within the last second.
75
        if (delta <= 1000 && swingDelta >= swingTime) {
76
            final CheckResult result = new CheckResult();
77
            result.setFailed("No swing animation within time")
78
                    .withParameter("delta", delta)
79
                    .withParameter("min", swingDelta);
80
            return checkViolation(player, result);
81
        }
82
83
        return false;
84
    }
85
86
    /**
87
     * Check this player for NoSwing
88
     *
89
     * @param player the player
90
     * @param data   their data
91
     */
92
    public boolean check(Player player, CombatData data) {
93
        if (exempt(player)) return false;
94
        return Arc.getMCVersion() == Version.VERSION_1_8 ? checkLegacyNoSwing(player, data)
95
                : checkNewNoSwing(player, data);
96
    }
97
98
    @Override
99
    public void reloadConfig() {
100
        load();
101
    }
102
103
    @Override
104
    public void load() {
105
        swingTime = Arc.getMCVersion() == Version.VERSION_1_8 ? configuration.getLong("max-swing-time-old")
106
                : configuration.getLong("max-swing-time-new");
107
    }
108
}

How it counteracts this module

Arc's combat NoSwing times swings against attacks. On 1.8 it runs the legacy branch: after an attack, if the time since the last swing packet exceeds max-swing-time-old (default 100ms), it fails with 'No swing animation within time'. On newer versions the check only fires when an attack landed within the last second and the swing gap still exceeds the allowed window, which avoids flagging idle players. Honest note: the check measures the C0A stream relative to attacks; Nekoware's Animations alters neither, so a player using it passes. It is the closest real swing-stream check in Arc and represents the timing-based approach to the same cheat class.

anticheat SwingFrequency (swing packet rate)

SwingFrequency.java95 lines · Java
1
package arc.check.network;
2
3
import arc.Arc;
4
import arc.check.PacketCheck;
5
import arc.check.result.CheckResult;
6
import arc.check.types.CheckType;
7
import arc.data.packet.PacketData;
8
import arc.world.WorldManager;
9
import org.bukkit.Bukkit;
10
import org.bukkit.entity.Player;
11
12
/**
13
 * Checks if the player is sending too many swing packets.
14
 */
15
public final class SwingFrequency extends PacketCheck {
16
17
    /**
18
     * Max packets and packet kick threshold
19
     */
20
    private int maxPacketsPerSecond, packetKickThreshold;
21
22
    /**
23
     * Kick if the threshold is reached
24
     */
25
    private boolean kickIfThresholdReached;
26
27
    public SwingFrequency() {
28
        super(CheckType.SWING_FREQUENCY);
29
        isEnabled(true)
30
                .cancel(true)
31
                .cancelLevel(0)
32
                .notify(true)
33
                .notifyEvery(1)
34
                .ban(true)
35
                .banLevel(10)
36
                .kick(true)
37
                .kickLevel(5)
38
                .build();
39
40
        addConfigurationValue("max-packets-per-second", 50);
41
        addConfigurationValue("kick-if-threshold-reached", false);
42
        addConfigurationValue("packet-kick-threshold", 100);
43
        if (isEnabled()) load();
44
    }
45
46
    /**
47
     * Check this player
48
     *
49
     * @param player the player
50
     * @param data   the packet data
51
     */
52
    private void check(Player player, PacketData data) {
53
        final CheckResult result = new CheckResult();
54
        final int count = data.swingPacketCount();
55
56
        if (count >= maxPacketsPerSecond) {
57
            result.setFailed("Too many swing packets per second.")
58
                    .withParameter("packets", data.swingPacketCount())
59
                    .withParameter("max", maxPacketsPerSecond);
60
61
            if (count >= packetKickThreshold && kickIfThresholdReached
62
                    && !Arc.getInstance().getPunishmentManager().hasPendingKick(player)) {
63
                Arc.getInstance().getPunishmentManager().kickPlayer(player, this);
64
            }
65
        } else {
66
            data.cancelSwingPackets(false);
67
        }
68
        data.swingPacketCount(0);
69
        data.cancelSwingPackets(checkViolation(player, result));
70
    }
71
72
    @Override
73
    public void reloadConfig() {
74
        load();
75
    }
76
77
    @Override
78
    public void load() {
79
        maxPacketsPerSecond = configuration.getInt("max-packets-per-second");
80
        kickIfThresholdReached = configuration.getBoolean("kick-if-threshold-reached");
81
        packetKickThreshold = configuration.getInt("packet-kick-threshold");
82
83
        schedule(() -> {
84
            for (Player player : Bukkit.getOnlinePlayers()) {
85
                if (!WorldManager.isEnabledInWorld(player)) continue;
86
                if (!exempt(player)) check(player, PacketData.get(player));
87
            }
88
        }, 20, 20);
89
    }
90
91
    @Override
92
    public void unload() {
93
        cancelScheduled();
94
    }
95
}

How it counteracts this module

Arc's swing flood detector: a scheduled task runs every 20 ticks, counts the player's swing packets for the second, and flags 'Too many swing packets per second' once the count reaches maxPacketsPerSecond (default 50), with an optional hard kick at packetKickThreshold (default 100) and a cancel path that drops subsequent swings while flagged. This catches autoclicker and animation-spam clients that flood C0A. Honest note: the module emits zero extra swings (the client's swing rate is unchanged), so the per-second count never approaches the cap; the check is the real detector for the flood side of the animation-packet axis this module does not touch.

anticheat NoSwingBreak (break without swing)

NoSwingBreak.java43 lines · Java
1
package ac.grim.grimac.checks.impl.breaking;
2
3
import ac.grim.grimac.checks.Check;
4
import ac.grim.grimac.checks.CheckData;
5
import ac.grim.grimac.checks.type.BlockBreakListener;
6
import ac.grim.grimac.checks.type.PreViaPacketReceiveListener;
7
import ac.grim.grimac.player.GrimPlayer;
8
import ac.grim.grimac.utils.anticheat.update.BlockBreak;
9
import com.github.retrooper.packetevents.event.PacketReceiveEvent;
10
import com.github.retrooper.packetevents.protocol.packettype.PacketType;
11
import com.github.retrooper.packetevents.protocol.player.DiggingAction;
12
13
@CheckData(name = "NoSwingBreak", stableKey = "grim.breaking.no_swing_break", description = "Did not swing while breaking block", experimental = true)
14
public class NoSwingBreak extends Check implements BlockBreakListener, PreViaPacketReceiveListener {
15
    private boolean sentAnimation;
16
    private boolean sentBreak;
17
18
    public NoSwingBreak(GrimPlayer player) {
19
        super(player);
20
    }
21
22
    @Override
23
    public void onBlockBreak(BlockBreak blockBreak) {
24
        if (blockBreak.action != DiggingAction.CANCELLED_DIGGING) {
25
            sentBreak = true;
26
        }
27
    }
28
29
    @Override
30
    public void onPreViaPacketReceive(PacketReceiveEvent event) {
31
        if (event.getPacketType() == PacketType.Play.Client.ANIMATION) {
32
            sentAnimation = true;
33
        }
34
35
        if (isTickPacket(event.getPacketType())) {
36
            if (sentBreak && !sentAnimation) {
37
                flag();
38
            }
39
40
            sentAnimation = sentBreak = false;
41
        }
42
    }
43
}

How it counteracts this module

Grim's breaking variant of the no-swing family: it latches sentBreak on any non-cancelled digging action and sentAnimation on any ANIMATION packet, and at each tick boundary flags if a break was sent without a swing in the same tick, resetting both latches. It targets clients that mine with packet-level speed hacks while suppressing the arm animation. Honest note: the module leaves the vanilla swing path intact, so every break still carries its C0A and the latches always pair; it is the per-tick swing-consistency check that would catch the suppression cheat this module's feature class is commonly paired with.

← Back to Analysis Hub