⚡ SimpleLogs
下一代战斗、取证与管理员日志系统
专为高性能 Spigot、Paper 和 Purpur 网络打造 —— Minecraft 1.21.1+
一个插件。完整的服务端可见性。零 TPS 损耗。
? 什么是 SimpleLogs?
SimpleLogs 是一款面向生产环境的服务端管理插件,其核心哲学只有一个:你的服务器应该确切地知道发生了什么、何时发生以及是谁做的——而且绝不能牺牲性能。
从战斗挂机者(Combat Loggers)到基地破坏者,从偷窃箱子的人到可疑的爆炸事件,SimpleLogs 利用完全异步 I/O、智能速率限制和高效数据结构在后台静默捕获所有信息。不进行区块扫描。不执行阻塞操作。没有任何妥协。
该插件为 Spigot 作为主要平台而从头构建,并原生完全兼容 Paper。
⚔️ 战斗挂机预防
阻止玩家不公平地逃避战斗。一旦开始 PvP,SimpleLogs 就会立即标记双方玩家,并在战斗计时器结束前保持该标记状态。
- 可配置的登出动作 — 当被标记的玩家断开连接时,选择
KILL(击杀)、PUNISH(惩罚)或 BOTH(两者兼施)
- 自然物品掉落 — 战斗挂机者的背包物品将在其确切位置掉落,供胜利者拾取
- 惩罚引擎 — 根据服务器策略应用
BAN(封禁)、TEMPBAN(临时封禁)、WARN(警告)或 NONE(无)。临时封禁时长完全可配置(如 10m、1h、1d)
- 宽限期保护 — 新加入的玩家在可配置的窗口期内(默认 5 秒)免疫战斗标记,防止出生点击杀滥用
- 命令拦截 — 白名单/黑名单引擎阻止
/spawn、/tp、/home 等逃跑命令,同时始终允许 /msg 和 /reply 等聊天命令。完全可配置,支持绕过权限
- 战斗反馈 — ActionBar 或 BossBar 计时器显示,支持可配置的颜色、样式和格式。进入战斗时播放一次音效(默认:末影龙咆哮)。所有 UI 元素均可单独开关
? 爆炸取证系统
运行私人 SMP 服务器?是否曾需要证明究竟是谁炸毁了别人的基地?
激活 PRIVATE_SMP 模式以启用完整的爆炸取证引擎。每次爆炸都会被捕获为带时间戳的取证报告,包含调查所需的一切信息。
记录的爆炸类型:
- TNT 引爆(含来源玩家检测)
- 下界和末地的床爆炸
- 末地水晶爆炸
- 重生锚误用
每份报告均包括:
- 爆炸类型和精确坐标
- 触发玩家(若无法检测则为
UNKNOWN)
- 爆炸瞬间所有在线玩家的完整快照 —— 名称、世界和坐标
- 高亮显示附近的嫌疑人,并标注精确的方块距离
- 多时区时间戳(IST, CET, EST, PST)
内置防卡顿系统 — 每秒速率限制、按地点冷却以及极端刷屏下的自动禁用(阈值可配置),确保 TNT 机器和掠夺农场永远不会降低你的 TPS。
半径计算仅使用 distanceSquared 进行嫌疑人检测 —— 主线程上无需平方根开销。
? 方块日志
以手术般的精度追踪服务器上的每一次方块交互。
- 独立记录 破坏 和 放置 行为 —— 可在配置中切换每种操作
- 材质过滤系统 — 选择
BLACKLIST(黑名单)模式忽略垃圾方块(泥土、石头、砾石、沙子、树叶 —— 包含 40 多种默认项),或选择 WHITELIST(白名单)模式仅记录你关心的特定方块
- 按玩家速率限制 — 每个玩家每秒最大事件数可配置。农场和挖矿机器绝不会淹没你的日志
GLOBAL(全局模式,单个文件)或 PER_PLAYER(按玩家模式,每位玩家一个文件)
- 使用
/sl blocklogs <player> 查询
- 为受信任的员工或自动化账户提供绕过权限
? 容器交互日志
确切知晓谁打开了什么,以及谁拿走或放置了什么物品。
记录的容器:
箱子、 barrels(桶)、潜影盒、漏斗、投掷器、发射器、熔炉、高炉、烟熏炉、酿造台
记录的交互:
OPEN — 玩家打开了容器
TAKE — 玩家移除了物品(直接点击、shift-click、部分拾取)
PUT — 玩家放置了物品(直接放置、从背包 shift-click)
空物品和 AIR 会被自动忽略。Shift-click 方向正确解析 —— 无重复日志,无遗漏交互。
包含按玩家速率限制和绕过权限。支持 GLOBAL 或 PER_PLAYER 存储。使用 /sl containerlogs <player> 查询。
? 管理员调查工具
SimpleLogs 2.0 最强大的功能 —— 一个统一的调查命令,可同时聚合来自每个日志系统的数据。
/sl investigate <player>
/sl investigate <player> combat
/sl investigate <player> blocks
/sl investigate <player> containers
/sl investigate <player> all
运行 /sl investigate <player> 会在战斗日志、方块日志和容器日志之间并行发起 三个异步读取。结果在主线程合并,并渲染为单一颜色编码的报告 —— 无需等待,无阻塞,无延迟。
- 战斗条目以红色显示
- 方块破坏以红色显示,放置以绿色显示
- 容器拿走以红色显示,放置以绿色显示,打开以灰色显示
- 每个系统的最大条目数可配置
- 完全异步 —— 磁盘读取期间从不触碰主线程
⚙️ 智能服务器模式系统
SimpleLogs 会自动适应你的服务器类型。
| 模式 |
行为 |
UNSET |
提示首位 OP 加入并显示可点击的设置按钮 |
PRIVATE_SMP |
完整功能集 — 所有日志系统均启用,包括爆炸取证 |
PUBLIC |
轻量模式 — 为获得最高性能而禁用爆炸取证功能 |
使用 /sl setmode private 或 /sl setmode public 即时切换模式。无需重启服务器。
? 命令与权限
| 命令 |
描述 |
权限 |
/sl reload |
重新加载配置 |
simplelogs.reload |
/sl setmode <private|public> |
设置服务器模式 |
OP |
/sl history <player> |
查看战斗日志历史 |
simplelogs.history |
/sl explosions |
查看最近的爆炸事件 |
simplelogs.explosions |
/sl blocklogs <player> |
查看方块日志历史 |
simplelogs.blocklogs |
/sl containerlogs <player> |
查看容器日志历史 |
simplelogs.containerlogs |
/sl investigate <player> [filter] |
生成完整调查报告 |
simplelogs.investigate |
绕过权限:
simplelogs.bypass — 绕过战斗命令限制
simplelogs.blocklog.bypass — 不记录该玩家的方块变动
simplelogs.containerlog.bypass — 不记录该玩家的容器变动
## ? 日志文件结构
所有日志均存储在 `/plugins/SimpleLogs/` 目录下:
SimpleLogs/
├── CombatlogPlayers/
│ └── combat_log.txt(或在 PER_PLAYER 模式下为 <PlayerName>.txt)
├── ExplosionLogs/
│ └── explosions.txt
├── BlockLogs/
│ └── block_log.txt(或 <PlayerName>.txt)
└── ContainerLogs/
└── container_log.txt(或 <PlayerName>.txt)
所有日志条目均为人类可读的纯文本格式,并包含多时区时间戳。
⚡ 性能架构
SimpleLogs 在设计之初便将性能作为首要需求,而非事后补救。
- 零主线程阻塞 — 所有文件 I/O 操作均为异步执行
- ConcurrentHashMap 用于战斗会话管理 — 线程安全且无锁竞争
- EnumSet 用于容器类型查找 — 实现最快的枚举成员检查
- 按玩家限流器 — O(1) 复杂度地图查找,并采用惰性第二窗口清理机制
- distanceSquared 用于所有半径检测 — 消除平方根计算开销
- 动态监听器注册 — 爆炸监听器仅在 PRIVATE_SMP 模式下注册
- 单一刻任务 处理所有战斗过期和 UI 更新 — 无需为每个玩家创建调度器
- 内存环形缓冲区 存储最近爆炸事件 —
/sl explosions 命令从不从磁盘读取数据
? bStats 分析
SimpleLogs 通过 bStats(插件 ID: 30642)收集匿名服务器统计数据。
跟踪指标:服务器模式分布。可在 bStats 全局配置中禁用此功能。
SimpleLogs 2.0 — 专为要求全面可视性且毫不妥协的服务器打造。
由 YounggamingDJ 创作与维护
⚡ SimpleLogs
The Next-Generation Combat, Forensic & Admin Logging System
Engineered for high-performance Spigot, Paper, and Purpur networks — Minecraft 1.21.1+
One plugin. Complete server visibility. Zero TPS impact.
? What is SimpleLogs?
SimpleLogs is a production-grade server administration plugin built around a single philosophy: your server should know exactly what happened, when it happened, and who did it — without ever sacrificing performance.
From combat loggers to base griefers, chest thieves to suspicious explosions, SimpleLogs captures everything silently in the background using fully asynchronous I/O, smart rate limiting, and efficient data structures. No chunk scanning. No blocking operations. No compromise.
Built from the ground up for Spigot as its primary platform, with full Paper compatibility out of the box.
⚔️ Combat Logging Prevention
Stop players from escaping fights unfairly. SimpleLogs tags both players the moment PvP begins and holds that tag until the combat timer expires.
- Configurable Logout Actions — choose
KILL, PUNISH, or BOTH when a tagged player disconnects
- Natural Item Drops — the combat logger's inventory drops at their exact location for the victor to collect
- Punishment Engine — apply
BAN, TEMPBAN, WARN, or NONE as your server policy dictates. Tempban durations are fully configurable (10m, 1h, 1d)
- Grace Period Protection — newly joined players are immune to combat tagging for a configurable window (default 5 seconds), preventing spawn-kill abuse
- Command Interception — whitelist/blacklist engine blocks escape commands like
/spawn, /tp, /home while always allowing chat commands like /msg and /reply. Fully configurable, bypass permission supported
- Combat Feedback — ActionBar or BossBar timer display with configurable colors, styles, and formats. Combat-start sound plays once on entry (default: Ender Dragon growl). All UI elements are individually toggleable
? Explosion Forensic System
Running a Private SMP? Ever needed to prove exactly who blew up someone's base?
Activate PRIVATE_SMP mode to enable the full explosion forensics engine. Every detonation is captured as a timestamped forensic report containing everything you need for a thorough investigation.
Tracked explosion types:
- TNT ignitions (with source player detection)
- Bed detonations in the Nether and End
- End Crystal explosions
- Respawn Anchor misuse
Every report includes:
- Explosion type and exact coordinates
- Triggering player (or
UNKNOWN if undetectable)
- Full snapshot of all online players — names, worlds, and coordinates at the exact moment of detonation
- Nearby suspects highlighted with precise block distance
- Multi-timezone timestamps (IST, CET, EST, PST)
Anti-lag system built in — per-second rate limiting, per-location cooldowns, and automatic disabling under extreme spam (configurable threshold) ensure TNT machines and raid farms never degrade your TPS.
Radius calculations use distanceSquared exclusively for suspect detection — no square root overhead on the main thread.
? Block Logging
Track every block interaction across your server with surgical precision.
- Logs breaks and places independently — toggle each action in config
- Material filter system — choose
BLACKLIST mode to ignore junk blocks (dirt, stone, gravel, sand, leaves — 40+ defaults included) or WHITELIST mode to log only specific blocks you care about
- Per-player rate limiter — configurable max events per second per player. Farms and mining machines never flood your logs
GLOBAL mode (single file) or PER_PLAYER mode (one file per player)
- Query with
/sl blocklogs <player>
- Bypass permission for trusted staff or automated accounts
? Container Interaction Logging
Know exactly who opened what, and who took or placed what items.
Tracked containers:
Chest, Barrel, Shulker Box, Hopper, Dropper, Dispenser, Furnace, Blast Furnace, Smoker, Brewing Stand
Tracked interactions:
OPEN — player opened the container
TAKE — player removed items (direct click, shift-click, partial pickup)
PUT — player placed items (direct placement, shift-click from inventory)
Null items and AIR are automatically ignored. Shift-click direction is correctly resolved — no duplicate logs, no missed interactions.
Per-player rate limiter and bypass permission included. GLOBAL or PER_PLAYER storage. Query with /sl containerlogs <player>.
? Admin Investigation Tools
The most powerful feature of SimpleLogs 2.0 — a unified investigation command that aggregates data from every log system simultaneously.
/sl investigate <player>
/sl investigate <player> combat
/sl investigate <player> blocks
/sl investigate <player> containers
/sl investigate <player> all
Running /sl investigate <player> fires three parallel async reads across combat logs, block logs, and container logs simultaneously. Results merge on the main thread and render as a single color-coded report — no waiting, no blocking, no lag.
- Combat entries shown in red
- Block breaks in red, places in green
- Container takes in red, puts in green, opens in gray
- Configurable max entries per system
- Fully async — the main thread is never touched during disk reads
⚙️ Smart Server Mode System
SimpleLogs adapts to your server type automatically.
| Mode |
Behavior |
UNSET |
Prompts the first OP to join with clickable setup buttons |
PRIVATE_SMP |
Full feature set — all logging systems active including explosion forensics |
PUBLIC |
Lightweight mode — explosion forensics disabled for maximum performance |
Switch modes instantly with /sl setmode private or /sl setmode public. No restart required.
? Commands & Permissions
| Command |
Description |
Permission |
/sl reload |
Reload configuration |
simplelogs.reload |
/sl setmode <private|public> |
Set server mode |
OP |
/sl history <player> |
View combat log history |
simplelogs.history |
/sl explosions |
View recent explosions |
simplelogs.explosions |
/sl blocklogs <player> |
View block log history |
simplelogs.blocklogs |
/sl containerlogs <player> |
View container log history |
simplelogs.containerlogs |
/sl investigate <player> [filter] |
Full investigation report |
simplelogs.investigate |
Bypass permissions:
simplelogs.bypass — bypass combat command restrictions
simplelogs.blocklog.bypass — exclude from block logging
simplelogs.containerlog.bypass — exclude from container logging
## ? Log File Structure
All logs are stored under `/plugins/SimpleLogs/`:
SimpleLogs/
├── CombatlogPlayers/
│ └── combat_log.txt (or <PlayerName>.txt in PER_PLAYER mode)
├── ExplosionLogs/
│ └── explosions.txt
├── BlockLogs/
│ └── block_log.txt (or <PlayerName>.txt)
└── ContainerLogs/
└── container_log.txt (or <PlayerName>.txt)
All log entries are human-readable plain text with multi-timezone timestamps.
⚡ Performance Architecture
SimpleLogs was designed with performance as a first-class requirement — not an afterthought.
- Zero blocking main thread — all file I/O is exclusively asynchronous
- ConcurrentHashMap for combat sessions — thread-safe with no lock contention
- EnumSet for container type lookups — fastest possible enum membership check
- Per-player rate limiters — O(1) map lookup with lazy second-window cleanup
- distanceSquared for all radius checks — eliminates sqrt overhead
- Dynamic listener registration — explosion listener only registered in PRIVATE_SMP mode
- Single tick task for all combat expiration and UI updates — no per-player schedulers
- In-memory ring buffer for recent explosions —
/sl explosions never reads from disk
? bStats Analytics
SimpleLogs collects anonymous server statistics via bStats (Plugin ID: 30642).
Tracked metrics: server mode distribution. Can be disabled in the bStats global config.
SimpleLogs 2.0 — Built for servers that demand complete visibility without compromise.
Authored and maintained by YounggamingDJ
评论 0
登录后参与评分
还没有评论,来抢沙发吧