CheckType and PunishmentType
Two small enums: how a check is classified, and what happens when it reaches its threshold.
CheckType
| Signature | Description |
|---|---|
MOVEMENT | Prediction, simulation and movement validation. |
COMBAT | Attacking: reach, click patterns, swing behaviour. |
KILL_AURA | Rotation and targeting patterns typical of aura clients. |
VELOCITY | Knockback and explosion handling. |
GROUND_SPOOF | Claiming to be on ground the simulation disagrees with. |
LATENCY_ABUSE | Exploiting packet delay: backtrack, blink, out-of-order latency tricks. |
TICK_SPEED | Timer and tick-rate manipulation. |
REACH | Interaction distance. |
BLOCK_INTERACT | Breaking and placing blocks. |
OCCLUDED_INTERACT | Interacting through geometry that should block it. |
PHASE | Moving through solid blocks. |
PACKET | Malformed, contradictory or impossible packets. |
INVENTORY | Inventory and container handling. |
CHAT | Chat and command behaviour. |
CLOUD | Detections produced by the cloud models. |
OTHER | Anything that does not fit the list above. |
static CheckType[] VALUES | A cached copy of values(), for hot loops. |
PunishmentType
| Signature | Description |
|---|---|
BAN | Runs the configured ban command(s). |
KICK | Removes the player from the server. |
BANWAVE | Queues the player in the cloud ban wave instead of punishing immediately. |
NONE | Alerts and logs only; the check never punishes on its own. |
Map<CheckType, Long> byType = api.checks().of(user).stream()
.filter(check -> check.violationLevel() > 0)
.collect(Collectors.groupingBy(Check::type, Collectors.counting()));
byType.forEach((type, flags) -> System.out.println(type + ": " + flags));
// Which of a player's active checks can punish on their own?
api.checks().of(user).stream()
.filter(check -> check.punishmentType() != null
&& check.punishmentType() != PunishmentType.NONE)
.forEach(check -> System.out.println(check.name() + " -> " + check.punishmentType()));