? DuckyAC
可配置的 Minecraft 服务器防护,提供基于数据包的检查及供员工审查的工具。
DuckyAC 监控移动、战斗、方块交互及玩家行为。它将数据包历史与服务端状态、碰撞箱形状以及可配置的证据缓冲区相结合,以识别可疑行为并为工作人员提供有用的警报。
75 种可配置的检查变体 · 官方发布 · Java 21 · PacketEvents
下载 · 更新日志 · 源代码 · 报告问题 · Discord
✨ 特性
- 移动检查: 速度、飞行、侧滑、爬墙、液面行走、击退、碰撞检测及船类飞行。
- 战斗检查: 攻击距离、命中框角度、穿墙攻击、目标切换、暴击模式及数据包爆发。
- 建造与玩家检查: 脚手架模式、陷阱放置、挖掘、物品使用时机及无效的数据包序列。
- 可配置的响应: 违规等级、仅警报模式、命令惩罚、事件取消以及在支持情况下的挫败措施(setbacks)。
- 员工审查: 可点击的控制按钮用于确认检测、标记误报并撤销决定。
- 检测记录: 本地 JSON Lines 存储,包含移动测量数据、延迟(ping)、TPS 及特定检查的上下文信息。
- 服务端感知检查: 可配置的 TPS 限制,以及针对传送、外部运动、游戏模式和地形的特定处理。
- 集成: Discord Webhooks 及用于插件扩展的公开 Bukkit Service API。
所有捆绑的检查变体均属于官方发布的一部分。各个检查保留其自身的启用开关和响应设置。
? 要求与安装
| 组件 |
要求 |
| 服务端 |
Spigot 或 Paper;当前构建版本针对 Spigot 1.20.6 API |
| Java |
Java 21 或更高版本 |
| 依赖项 |
PacketEvents,Spigot 插件;DuckyAC 基于版本 2.11.2 构建 |
| 配置 |
架构版本 29,由插件生成并迁移 |
- 将 PacketEvents 安装至服务端的
plugins/ 目录中。
- 下载 DuckyAC 并将其 JAR 文件放入同一目录。
- 启动服务器,确保两个插件均能成功启用。
- 编辑
plugins/DuckyAntiCheat/config.yml 以选择检查项目、警报阈值和响应方式。
- 授予工作人员相应的权限,并在修改配置后使用
/duckyac reload 重新加载。
对于升级操作,请备份现有的插件配置文件和 learning-data/ 目录,在服务器停止运行时替换 JAR 文件,然后启动服务器以运行迁移程序。上述当前构建目标描述了此源码树结构;在选择发布版本时,请使用特定可下载版本列出的 Minecraft 兼容性信息。
? 检查
? 移动与载具
| 检查项 |
检测重点 |
AirJumpA |
空中重复不自然的向上移动 |
FlyA |
持续的向上飞行模式 |
InvalidPositionA |
与重力不一致的长时间悬停和坠落 |
SpeedA |
过度的水平移动及修改后的低跳动作 |
StrafeA |
不切实际的空中方向改变 |
BunnyHopA |
重复的修改后跳跃和空中控制循环 |
VelocityA-B |
水平和垂直击退响应的减弱 |
PhaseA |
穿过实心碰撞箱的移动 |
StepA |
超出允许高度的台阶 |
SpiderA-C |
稳定的墙壁攀爬、重复的墙面跳跃及垂直攀爬冲量 |
FastClimbA-B |
过快的攀爬速度及在可攀爬方块上的穿模式移动 |
JesusA-D |
液面移动、垂直偏移、地面主张及发射效果 |
GroundSpoofA-B |
与服务端支持不一致的地面状态主张 |
NoSlowDownA-H |
在使用物品、潜行或穿越减速方块时过度移动 |
NoWebA |
在蜘蛛网内的可疑移动 |
InventoryMoveA |
与物品栏点击相关的移动 |
VehicleFlyA |
不受支持的船只悬停、上升及抑制的重力,包括箱子船 |
地形感知检查利用碰撞箱形状来考虑地毯、台阶和楼梯等部分方块的影响。VehicleFlyA 结合了占用的船只位置、最新载具数据包以及针对水、气泡弹射、伤害和服务端校正的宽限期。
⚔️ 战斗
| 检查项 |
检测重点 |
ReachA |
过度的方块交互距离 |
ReachB |
过度的实体攻击距离,使用历史命中框和延迟补偿 |
HitboxA |
不切实际的攻击角度 |
ThruBlocksA-B |
穿透遮挡方块的攻击 |
KillAuraA-B |
快速的目标切换及缺失的挥动证据 |
CriticalsA |
与已确认伤害相关的可疑暴击移动 |
FakeLagA |
重复的移动停滞随后是压缩的数据包刷新 |
FastBowA |
与拉弓时间不一致的弓弦释放 |
VehicleOneHitA |
试图在一次点击中摧毁船只或矿车的攻击爆发 |
? 鞘翅
| 检查项 |
检测重点 |
ElytraAimA |
使用鞘翅飞行时的可疑攻击节奏 |
ElytraCriticalsA |
使用鞘翅期间重复的暴击行为 |
ElytraFlyA-C |
直接飞行控制、持续的物理偏差及自动化的俯仰循环 |
ElytraFireworkA |
高度规律的自动化火箭使用及相关物品栏模式 |
ElytraPacketsA |
已在滑翔状态下重复的开始飞行动作 |
? 建造与放置
| 检测项 |
检测重点 |
AirPlaceA |
在缺乏合理附近支撑的情况下放置方块 |
AutoTrapA-B |
快速封闭模式以及数据包与放置行为的一致性 |
FastPlaceA-B |
过高的放置速率和异常规律的放置间隔 |
InvalidPlaceA |
放置行为与玩家视角角度不一致 |
ScaffoldA-B |
不合理的放置角度和自动化的放置时机 |
⛏️ 玩家动作与数据包
| 检测项 |
检测重点 |
AutoTotemA |
图腾切换速度极快 |
FastEatA |
食物或药水消耗完成得过快 |
FastBreakA-B |
方块破坏或挖掘完成时间早于预期的挖掘耗时 |
FastExpA |
经验瓶使用出现不合理的爆发式集中 |
NukerA |
过多或距离过远的方块挖掘目标 |
MultiActionsA |
同时执行相互冲突的动作 |
BadPacketsA-F |
旋转模式、无效的俯仰角或槽位、动作序列、传送确认及挖掘序列 |
TimerA-D |
移动时钟漂移、数据包速率以及重复压缩的移动间隔 |
⚙️ 配置
默认配置文件包含完整的设置列表和说明。每个检测项都有各自的配置部分;附加选项取决于具体的检测器。
VehicleFlyA 示例:
vehicle-fly-a:
enabled: true
alert-only: false
min-tps: 19.0
window-ticks: 8
required-samples: 3
gravity-tolerance: 0.12
buffer-threshold: 2.0
alert-cooldown-ms: 300
max-alerts: 5
command: "kick %player% Invalid boat flight (VehicleFlyA)"
debug: false
在 20 TPS 下,持续的无支撑飞行在经过任何宽限期后,大约 550 ms 的有效采样时间后即可触发第一次 VehicleFlyA 警报。持续的违规行为大约每 300 ms 会触发一次警报。
enabled 控制是否运行某项检测。
alert-only(在支持的情况下)使检测不执行配置的惩罚命令。
cancel-event 和 setback-enabled(在支持的情况下)控制独立的防止措施。
max-alerts 和 command 配置基于命令的惩罚机制。
min-tps、缓冲区、容忍度和宽限期控制何时接受证据。
多项检测默认以仅警报模式启动。KillAuraB 和 BadPacketsC 默认禁用,可以单独启用。在选择服务器策略时,请查阅每项检测的响应选项。
?⚖️ 员工审核与检测记录
授权员工可以使用警报附带的控件来确认检测、标记误报或撤销标签。标记为误报会在存储的违规计数仍处于活跃状态时移除该警报的 VL 贡献。撤销则恢复已被移除的贡献。
检测记录包括警报 ID、玩家、检测项、插件版本、延迟、TPS、游戏模式以及可用的移动或特定检测测量数据。标签和检测特征在重启后会恢复。它们提供用于审核和未来模型训练的数据集。
machine-learning:
enabled: true
store-unlabeled: true
storage-directory: "learning-data"
记录默认存储在 plugins/DuckyAntiCheat/learning-data/ 目录下。按钮文本、悬停文本和员工消息均可配置。
?️ 命令与权限
| 命令 |
权限 |
用途 |
/duckyac reload |
duckyac.reload |
重新加载配置 |
/duckyac-debug debug <mode> [packet_name] |
duckyac.debug |
检查数据包流量;模式:C2S、S2C、BOTH、OFF |
/duckyaclabel <action> <alert-id> |
duckyac.learning.label |
应用 correct、false 或 undo;也用于警报按钮 |
| 权限 |
用途 |
duckyac.alerts |
接收违规警报 |
duckyac.learning.label |
审核并标记检测结果 |
duckyac.bypass |
绕过所有检测 |
duckyac.bypass.* |
通过权限组授予单项检测的绕过权限 |
duckyac.bypass.<config-section> |
绕过特定检测,例如 duckyac.bypass.vehicle-fly-a |
旧版检测项的权限名称可能有所不同;已注册的 权限条目 和各检测项的绕过查找定义决定了接受的名称。
? Discord
启用 discord 部分并提供 Webhook URL,即可将配置的违规和惩罚消息发送到您的员工频道。Webhook 用户名、头像和消息模板均可配置。
? 开发者 API
DuckyAC 通过 Bukkit 的 Services Manager 暴露其 API。在插件描述中添加 softdepend: [DuckyAntiCheat] 或 depend: [DuckyAntiCheat],并针对 DuckyAC JAR 进行编译。
import pl.barpad.duckyanticheat.api.DuckyAntiCheatAPI;
import pl.barpad.duckyanticheat.api.DuckyAntiCheatProvider;
DuckyAntiCheatAPI api = DuckyAntiCheatProvider.require();
int reachVl = api.getViolationLevel(player, "ReachB");
boolean vehicleFlyEnabled = api.isCheckEnabled("vehicle-fly-a");
API 支持检测元数据和配置、玩家违规档案、带有检测上下文的违规报告、惩罚命令、清除违规以及外部检测项的运行时注册。集成插件可以监听 DuckyViolationEvent 和 DuckyPunishmentEvent;违规事件会暴露关联的警报 ID。
检测 ID 经过标准化处理,因此 ReachB、reach-b 和 Reach B 都会解析到同一个检测项。外部检测项的注册在当前插件会话期间有效。
?️ 从源码构建
安装 Java 21 或更高版本后,运行:
.\gradlew.bat clean build
在 Linux 或 macOS 上:
./gradlew clean build
JAR 文件将写入 build/libs/。自动化测试涵盖检测模型、数据包注册、配置、权限和学习数据存储持久性。
? 支持
通过 GitHub Issues 报告 bug,或加入 Discord。请提供 DuckyAC 和 PacketEvents 的版本号、服务器软件、相关的检测设置以及复现步骤。带有标签的检测记录和调试数据有助于排查误报。
? 许可证
DuckyAC 遵循 GPL-3.0 许可证。
? DuckyAC
Configurable protection for Minecraft servers, with packet-based checks and tools for staff review.
DuckyAC monitors movement, combat, block interactions and player actions. It combines packet history with server state, collision shapes and configurable evidence buffers to identify suspicious behavior and give staff useful alerts.
75 configurable check variants · Official release · Java 21 · PacketEvents
Download · Changelog · Source code · Report an issue · Discord
✨ Features
- Movement checks: speed, flight, strafing, wall climbing, liquid walking, knockback, collisions and boat flight.
- Combat checks: reach, hitbox angles, attacks through blocks, target switching, critical-hit patterns and packet bursts.
- Building and player checks: scaffold patterns, trap placement, mining, item-use timing and invalid packet sequences.
- Configurable responses: violation levels, alert-only operation, command punishments, event cancellation and setbacks where supported.
- Staff review: clickable controls to confirm detections, mark false positives and undo decisions.
- Detection records: local JSON Lines storage with movement measurements, ping, TPS and check-specific context.
- Server-aware checks: configurable TPS limits and check-specific handling of teleports, external motion, game modes and terrain.
- Integrations: Discord webhooks and a public Bukkit service API for add-ons.
All bundled check variants are part of the official release. Individual checks retain their own enable switches and response settings.
? Requirements and installation
| Component |
Requirement |
| Server |
Spigot or Paper; the current build targets the Spigot 1.20.6 API |
| Java |
Java 21 or newer |
| Dependency |
PacketEvents, Spigot plugin; DuckyAC builds against version 2.11.2 |
| Configuration |
Schema version 29, generated and migrated by the plugin |
- Install PacketEvents in your server's
plugins/ directory.
- Download DuckyAC and place its JAR in the same directory.
- Start the server and check that both plugins enable successfully.
- Edit
plugins/DuckyAntiCheat/config.yml to choose checks, alert thresholds and responses.
- Grant staff the appropriate permissions and use
/duckyac reload after configuration edits.
For an upgrade, back up the existing plugin configuration and learning-data/ directory, replace the JAR while the server is stopped, then start the server to run migrations. The current build target above describes this source tree; use the Minecraft compatibility listed for the specific downloadable version when choosing a release.
? Checks
? Movement and vehicles
| Check |
Detection focus |
AirJumpA |
Repeated unnatural upward movement while airborne |
FlyA |
Sustained upward flight patterns |
InvalidPositionA |
Prolonged hovering and falling inconsistent with gravity |
SpeedA |
Excessive horizontal movement and modified low-hop motion |
StrafeA |
Implausible airborne direction changes |
BunnyHopA |
Repeated modified jump and air-control cycles |
VelocityA-B |
Reduced horizontal and vertical knockback response |
PhaseA |
Movement through solid collision shapes |
StepA |
Steps exceeding the allowed height |
SpiderA-C |
Stable wall climbing, repeated wall jumps and vertical climb impulses |
FastClimbA-B |
Excessive climb speed and clip-style movement on climbable blocks |
JesusA-D |
Liquid-surface movement, vertical offsets, ground claims and launches |
GroundSpoofA-B |
Ground-state claims inconsistent with server support |
NoSlowDownA-H |
Excessive movement while using items, sneaking or crossing slowing blocks |
NoWebA |
Suspicious movement inside cobwebs |
InventoryMoveA |
Movement correlated with inventory clicks |
VehicleFlyA |
Unsupported boat hovering, ascent and suppressed gravity, including chest boats |
Terrain-aware checks use collision shapes to account for partial blocks such as carpets, slabs and stairs. VehicleFlyA combines occupied-boat positions with fresh vehicle packets and grace periods for water, bubble launches, damage and server corrections.
⚔️ Combat
| Check |
Detection focus |
ReachA |
Excessive block interaction distance |
ReachB |
Excessive entity attack distance, using historical hitboxes and latency compensation |
HitboxA |
Implausible attack angles |
ThruBlocksA-B |
Attacks through obstructing blocks |
KillAuraA-B |
Rapid target switching and missing swing evidence |
CriticalsA |
Suspicious critical-hit movement correlated with confirmed damage |
FakeLagA |
Repeated movement stalls followed by compressed packet flushes |
FastBowA |
Bow releases inconsistent with draw time |
VehicleOneHitA |
Bursts of attacks attempting to destroy a boat or minecart in one click |
? Elytra
| Check |
Detection focus |
ElytraAimA |
Suspicious attack cadence while flying with an elytra |
ElytraCriticalsA |
Repeated critical-hit behavior during elytra use |
ElytraFlyA-C |
Direct flight control, sustained physics deviations and automated pitch cycles |
ElytraFireworkA |
Highly regular automated rocket use and related inventory patterns |
ElytraPacketsA |
Repeated start-flying actions while already gliding |
? Building and placement
| Check |
Detection focus |
AirPlaceA |
Placement without plausible nearby support |
AutoTrapA-B |
Rapid enclosing patterns and packet-to-placement consistency |
FastPlaceA-B |
Excessive placement rate and unusually regular placement intervals |
InvalidPlaceA |
Placement inconsistent with the player's viewing angle |
ScaffoldA-B |
Implausible placement angles and automated placement timing |
⛏️ Player actions and packets
| Check |
Detection focus |
AutoTotemA |
Extremely fast totem swaps |
FastEatA |
Food or potion consumption completed too quickly |
FastBreakA-B |
Block breaks or digging completions earlier than expected mining time |
FastExpA |
Implausible bursts of experience-bottle use |
NukerA |
Excessive or distant block-digging targets |
MultiActionsA |
Conflicting actions performed concurrently |
BadPacketsA-F |
Rotation patterns, invalid pitch or slots, action sequences, teleport confirmations and digging sequences |
TimerA-D |
Movement clock drift, packet rates and repeatedly compressed movement intervals |
⚙️ Configuration
The default configuration contains the full list of settings and descriptions. Each check has its own section; additional options depend on the detector.
VehicleFlyA example:
vehicle-fly-a:
enabled: true
alert-only: false
min-tps: 19.0
window-ticks: 8
required-samples: 3
gravity-tolerance: 0.12
buffer-threshold: 2.0
alert-cooldown-ms: 300
max-alerts: 5
command: "kick %player% Invalid boat flight (VehicleFlyA)"
debug: false
At 20 TPS, continuous unsupported flight can produce the first VehicleFlyA alert after approximately 550 ms of eligible sampling, following any grace period. Continued violations can alert at approximately 300 ms intervals.
enabled controls whether a check runs.
alert-only, where supported, keeps detections from executing the configured punishment command.
cancel-event and setback-enabled, where supported, control separate prevention actions.
max-alerts and command configure command-based punishment.
min-tps, buffers, tolerances and grace periods control when evidence is accepted.
Several checks start in alert-only mode. KillAuraB and BadPacketsC start disabled and can be enabled individually. Review each check's response options when choosing your server policy.
?⚖️ Staff review and detection records
Authorized staff can use the controls attached to alerts to confirm a detection, mark a false positive or undo a label. Marking a false positive removes that alert's VL contribution when the stored violation is still active. Undo restores a contribution that was removed.
Detection records include the alert ID, player and check, plugin version, ping, TPS, game mode and available movement or check-specific measurements. Labels and detection features are restored after a restart. They provide a dataset for review and future model training.
machine-learning:
enabled: true
store-unlabeled: true
storage-directory: "learning-data"
Records are stored under plugins/DuckyAntiCheat/learning-data/ by default. Button text, hover text and staff messages are configurable.
?️ Commands and permissions
| Command |
Permission |
Purpose |
/duckyac reload |
duckyac.reload |
Reload configuration |
/duckyac-debug debug <mode> [packet_name] |
duckyac.debug |
Inspect packet traffic; modes: C2S, S2C, BOTH, OFF |
/duckyaclabel <action> <alert-id> |
duckyac.learning.label |
Apply correct, false or undo; also used by alert buttons |
| Permission |
Purpose |
duckyac.alerts |
Receive violation alerts |
duckyac.learning.label |
Review and label detections |
duckyac.bypass |
Bypass all checks |
duckyac.bypass.* |
Grant individual check bypasses through the permission group |
duckyac.bypass.<config-section> |
Bypass a particular check, for example duckyac.bypass.vehicle-fly-a |
Permission names can differ for legacy checks; the registered permission entries and each check's bypass lookup define the accepted names.
? Discord
Enable the discord section and provide a webhook URL to send configured violation and punishment messages to your staff channel. The webhook username, avatar and message templates are configurable.
? Developer API
DuckyAC exposes its API through Bukkit's Services Manager. Add softdepend: [DuckyAntiCheat] or depend: [DuckyAntiCheat] to your plugin description and compile against the DuckyAC JAR.
import pl.barpad.duckyanticheat.api.DuckyAntiCheatAPI;
import pl.barpad.duckyanticheat.api.DuckyAntiCheatProvider;
DuckyAntiCheatAPI api = DuckyAntiCheatProvider.require();
int reachVl = api.getViolationLevel(player, "ReachB");
boolean vehicleFlyEnabled = api.isCheckEnabled("vehicle-fly-a");
The API supports check metadata and configuration, player violation profiles, violation reporting with detection context, punishment commands, clearing violations and runtime registration of external checks. Integrations can listen to DuckyViolationEvent and DuckyPunishmentEvent; violation events expose the associated alert ID.
Check IDs are normalized, so ReachB, reach-b and Reach B resolve to the same check. External check registrations last for the current plugin session.
?️ Build from source
With Java 21 or newer installed, run:
.\gradlew.bat clean build
On Linux or macOS:
./gradlew clean build
The JAR is written to build/libs/. Automated tests cover detection models, packet registration, configuration, permissions and learning-data persistence.
? Support
Report bugs through GitHub Issues or join Discord. Include the DuckyAC and PacketEvents versions, server software, relevant check settings and steps to reproduce the behavior. Labeled detection records and debug measurements help investigate false positives.
? License
DuckyAC is licensed under GPL-3.0.
评论 0
登录后参与评分
还没有评论,来抢沙发吧