- 版权类型
- 原创
- 版权链接
- #
- 前置组件
- LeviLamina: https://github.com/LiteLDev/LeviLamina
legacy-script-engine-quickjs:https://github.com/LiteLDev/LegacyScriptEngine
UEssential(可选,提供TPS接口服务):https://www.minebbs.com/resources/uessential-tpa-tpr-ban-tps-home-warp.16002/
- 适配版本(基岩)
- 全版本
【授权声明】
本项目基于 AGPL-3.0 协议开源。详细条款、例外情况及授权定义,
请参阅项目根目录下的 LICENSE 文件。
USweeper - 高级实体清理插件
功能特性(以下所有功能均配有开关和自定义配置,所有功能默认开启):
1.定时清理:允许定时清理实体/掉落物。默认600秒。
2.上限清理:默认每30秒检查一次服务器符合清理要求的实体,若超过限度,则启动清理。
3.TPS清理(对接UEssential的TPS查询API):使用UEssential的高效TPSAPI接口,每10秒查询一次,若低于最低限度,则启动清理。当UEssential未安装时,该配置默认无效。
4.投票清理:玩家可以输入/clean 发起投票,默认情况下,投票支持率大于70%,或最终反对票小于30%则启动清理,默认投票时间30秒。
5.管理员清理:管理员可以输入/cleanadmin强制发起管理员清理实体。
6.多种清理模式:白名单/黑名单/混合模式;满足您的不同需求
安全性:
本插件提供多方位安全保护
1.默认有15秒的清理提示,只有提示结束后才会启动清理。
2.仅清理在提示前被记录的实体,清理提示期间新增的实体不会被记录清理名单。
3.提供多方位清理白名单,防止贵重实体被清理,可自定义配置,默认包括:村民、钻石(及其制品)、下界合金(及其制品)、潜影盒等十余项常见贵重实体,详见whitelist
4.提供清理间隔防止无意义清理与刷屏,默认间隔时间60秒,期间,定时清理、上限清理与TPS清理将被禁用,而投票清理和管理员清理的发起则不受影响
5.提供命名实体、信任玩家实体、有装备的实体等实体的清理保护。
清理模式:
仅白名单模式 (whitelist):只有白名单内或具备保护条件的实体会被保留,其余所有未知/常规生物与杂物统一清理(黑名单不生效)。
仅黑名单模式 (blacklist):只对黑名单内指定的实体进行清理,且若黑名单实体被命名/驯服仍可享有保护豁免(白名单不生效)。
混合模式 (mixed):黑名单内的实体具有最高处决优先级(无视命名、驯服等一切保护条件强制抹除);不在黑名单内的实体则遵循白名单与常规保护规则。
配置文件说明
配置文件路径:plugins/USweeper/config.json
{
// 清理模式:"whitelist" (仅白名单), "blacklist" (仅黑名单), "mixed" (混合模式)
"mode": "whitelist",
// 黑名单实体列表(支持命名空间和名称关键字模糊匹配)
"blacklist": [
"minecraft:zombified_piglin",
"minecraft:zombie_pigman"
],
// 白名单实体与掉落物列表(支持命名空间和名称关键字模糊匹配)
"whitelist": [
"minecraft:shulker_box",
"minecraft:netherite",
"minecraft:diamond",
"minecraft:ender_dragon",
"minecraft:ancient_debris",
"minecraft:beacon",
"minecraft:dragon_egg",
"minecraft:nether_star",
"minecraft:elytra",
"minecraft:emerald",
"minecraft:ender_crystal",
"minecraft:ender_eye",
"minecraft:ender_pearl",
"minecraft:enchanted_book",
"minecraft:painting",
"minecraft:sea_lantern",
"minecraft:totem_of_undying",
"minecraft:villager",
"minecraft:villager_v2",
"minecraft:chicken",
"minecraft:cow",
"minecraft:sheep",
"minecraft:rabbit",
"minecraft:mooshroom",
"minecraft:bee",
"minecraft:pig",
"minecraft:minecart",
"minecraft:hopper_minecart",
"minecraft:command_block_minecart",
"minecraft:chest_minecart",
"minecraft:iron_golem",
"minecraft:snow_golem",
"minecraft:copper_golem",
"minecraft:boat",
"minecraft:chest_boat",
"minecraft:armor_stand",
"minecraft:cat",
"minecraft:wolf",
"minecraft:shulker",
"minecraft:wither_skeleton",
"minecraft:wither",
"minecraft:pillager",
"minecraft:vindicator",
"minecraft:witch",
"minecraft:evoker",
"minecraft:ravager",
"minecraft:allay",
"minecraft:leash_knot"
],
// 数量上限监控配置
"limits": {
"enabled": true,
"checkInterval": 30, // 检查周期(秒)
"maxEntities": 200 // 可清理实体数量阈值
},
// 定时清理配置
"timer": {
"enabled": true,
"interval": 600 // 定时清理周期(秒)
},
// TPS 性能监控配置
"tps": {
"enabled": true,
"checkInterval": 10, // 监测周期(秒)
"threshold": 15.0 // 触发清理的 TPS 最低阈值
},
// 投票系统配置
"vote": {
"enabled": true,
"duration": 30, // 投票持续时间(秒)
"immediateYesRatio": 0.7, // 立即通过的支持率阈值 (70%)
"timeoutMaxNoRatio": 0.3 // 超时后判定通过的最大反对率阈值 (30%)
},
// 管理员指令配置
"admin": {
"enabled": true
},
// 清理与安全参数
"cleanup": {
"delay": 15, // 触发后倒计时秒数
"warningMark": 5, // 临界警告秒数(即倒计时剩余5秒时再次广播)
"safetyLockSeconds": 60, // 清理完成后的安全锁冷却时间(秒)
"ignoreTamedAndTrusted": true // 是否豁免信任玩家和已驯服的生物
}
}
本项目基于 AGPL-3.0 协议开源。详细条款、例外情况及授权定义,
请参阅项目根目录下的 LICENSE 文件。
USweeper - 高级实体清理插件
功能特性(以下所有功能均配有开关和自定义配置,所有功能默认开启):
1.定时清理:允许定时清理实体/掉落物。默认600秒。
2.上限清理:默认每30秒检查一次服务器符合清理要求的实体,若超过限度,则启动清理。
3.TPS清理(对接UEssential的TPS查询API):使用UEssential的高效TPSAPI接口,每10秒查询一次,若低于最低限度,则启动清理。当UEssential未安装时,该配置默认无效。
4.投票清理:玩家可以输入/clean 发起投票,默认情况下,投票支持率大于70%,或最终反对票小于30%则启动清理,默认投票时间30秒。
5.管理员清理:管理员可以输入/cleanadmin强制发起管理员清理实体。
6.多种清理模式:白名单/黑名单/混合模式;满足您的不同需求
安全性:
本插件提供多方位安全保护
1.默认有15秒的清理提示,只有提示结束后才会启动清理。
2.仅清理在提示前被记录的实体,清理提示期间新增的实体不会被记录清理名单。
3.提供多方位清理白名单,防止贵重实体被清理,可自定义配置,默认包括:村民、钻石(及其制品)、下界合金(及其制品)、潜影盒等十余项常见贵重实体,详见whitelist
4.提供清理间隔防止无意义清理与刷屏,默认间隔时间60秒,期间,定时清理、上限清理与TPS清理将被禁用,而投票清理和管理员清理的发起则不受影响
5.提供命名实体、信任玩家实体、有装备的实体等实体的清理保护。
清理模式:
仅白名单模式 (whitelist):只有白名单内或具备保护条件的实体会被保留,其余所有未知/常规生物与杂物统一清理(黑名单不生效)。
仅黑名单模式 (blacklist):只对黑名单内指定的实体进行清理,且若黑名单实体被命名/驯服仍可享有保护豁免(白名单不生效)。
混合模式 (mixed):黑名单内的实体具有最高处决优先级(无视命名、驯服等一切保护条件强制抹除);不在黑名单内的实体则遵循白名单与常规保护规则。
配置文件路径:plugins/USweeper/config.json
{
// 清理模式:"whitelist" (仅白名单), "blacklist" (仅黑名单), "mixed" (混合模式)
"mode": "whitelist",
// 黑名单实体列表(支持命名空间和名称关键字模糊匹配)
"blacklist": [
"minecraft:zombified_piglin",
"minecraft:zombie_pigman"
],
// 白名单实体与掉落物列表(支持命名空间和名称关键字模糊匹配)
"whitelist": [
"minecraft:shulker_box",
"minecraft:netherite",
"minecraft:diamond",
"minecraft:ender_dragon",
"minecraft:ancient_debris",
"minecraft:beacon",
"minecraft:dragon_egg",
"minecraft:nether_star",
"minecraft:elytra",
"minecraft:emerald",
"minecraft:ender_crystal",
"minecraft:ender_eye",
"minecraft:ender_pearl",
"minecraft:enchanted_book",
"minecraft:painting",
"minecraft:sea_lantern",
"minecraft:totem_of_undying",
"minecraft:villager",
"minecraft:villager_v2",
"minecraft:chicken",
"minecraft:cow",
"minecraft:sheep",
"minecraft:rabbit",
"minecraft:mooshroom",
"minecraft:bee",
"minecraft:pig",
"minecraft:minecart",
"minecraft:hopper_minecart",
"minecraft:command_block_minecart",
"minecraft:chest_minecart",
"minecraft:iron_golem",
"minecraft:snow_golem",
"minecraft:copper_golem",
"minecraft:boat",
"minecraft:chest_boat",
"minecraft:armor_stand",
"minecraft:cat",
"minecraft:wolf",
"minecraft:shulker",
"minecraft:wither_skeleton",
"minecraft:wither",
"minecraft:pillager",
"minecraft:vindicator",
"minecraft:witch",
"minecraft:evoker",
"minecraft:ravager",
"minecraft:allay",
"minecraft:leash_knot"
],
// 数量上限监控配置
"limits": {
"enabled": true,
"checkInterval": 30, // 检查周期(秒)
"maxEntities": 200 // 可清理实体数量阈值
},
// 定时清理配置
"timer": {
"enabled": true,
"interval": 600 // 定时清理周期(秒)
},
// TPS 性能监控配置
"tps": {
"enabled": true,
"checkInterval": 10, // 监测周期(秒)
"threshold": 15.0 // 触发清理的 TPS 最低阈值
},
// 投票系统配置
"vote": {
"enabled": true,
"duration": 30, // 投票持续时间(秒)
"immediateYesRatio": 0.7, // 立即通过的支持率阈值 (70%)
"timeoutMaxNoRatio": 0.3 // 超时后判定通过的最大反对率阈值 (30%)
},
// 管理员指令配置
"admin": {
"enabled": true
},
// 清理与安全参数
"cleanup": {
"delay": 15, // 触发后倒计时秒数
"warningMark": 5, // 临界警告秒数(即倒计时剩余5秒时再次广播)
"safetyLockSeconds": 60, // 清理完成后的安全锁冷却时间(秒)
"ignoreTamedAndTrusted": true // 是否豁免信任玩家和已驯服的生物
}
}
开发者与反馈
- 开发辅助: 本项目使用了AI进行辅助开发,模型包括:Gemini 3.1 Pro / Gemini 2.5 Pro
- 作者QQ:1376479666
- BUG反馈与交流群 (QQ): 1097933637