? Playtime 是什么?
Playtime 是一款仅服务端的 Forge 模组,用于追踪每位玩家的有效游戏时间,并自动将其推进至完全可自定义的等级系统。它具备离线挂机(AFK)感知能力,因此空闲时间不会计入——只有真正的游戏操作才能获得等级。
无论你是运营小型社区服务器还是大型网络,Playtime 都能为你提供 奖励忠实玩家、管理领地声明 以及 保持服务器整洁 的工具——所有这些操作都无需手动触碰任何配置文件(当然,如果你愿意,也可以自行配置!)。
✨ 主要功能
?️ 33级进阶系统
穿越 8个主题阶段——从谦逊的新手到至高无上的 Singularity。每个等级解锁更多的领地区块、强制加载区块,并拥有其独特的颜色和图标。
| 阶段 |
主题 |
等级 |
风格 |
| ? Phase 1 |
The Grounded |
Starter → Settler |
生存与定居 |
| ? Phase 2 |
The Arcane |
Apprentice → Wizard |
魔法与神秘主义 |
| ⚙️ Phase 3 |
The Industrial |
工匠 → 蒸汽领主 |
蒸汽朋克时代 |
| ? 阶段 4 |
技术时代 |
技师 → 指挥官 |
现代工程 |
| ? 阶段 5 |
飞升 |
飞行员 → 轨道行者 |
大气层与早期太空 |
| ? 阶段 6 |
星际时代 |
太空旅者 → 寻星者 |
深空与殖民 |
| ? 阶段 7 |
宇宙操纵者 |
裂隙塑造者 → 日蚀使者 |
扭曲物理法则 |
| ⭐ 阶段 8 |
至高无上 |
飞升者 → 奇点 |
神级 |
? 完全可定制! 在游戏中或通过 JSON 添加、删除或编辑任何等级。没有限制——你可以拥有 16 个等级或 200 个!
? 丰富的色彩系统
等级不仅仅是名称——它们是视觉体验。
- ? 单一十六进制颜色 —
&#FFA500 呈现简洁、醒目的外观
- ? 多色阶渐变 —
gradient:#DDA0DD-#00CED1-#FFD700 打造令人惊叹的等级标题
- ✏️ 格式化 — 通过
§l、§n 等实现加粗、下划线、斜体等效果。
- ? 预烘焙的角色级渐变 — 完全兼容 Better-Forge-Chat
最终阶段的渐变由该阶段之前的 3 种颜色组成 — 第 1–2 阶段为下划线,第 3+ 阶段为粗体,第 8 阶段则为全渐变加粗体。?
?️ 自定义游戏内 GUI
打开游玩时间 GUI,一目了然地查看所有内容:
- ? 你的统计数据 — 总游玩时间、当前排名、下一排名及剩余时间
- ? 玩家列表 — 查看所有玩家、他们的排名和游玩时间,支持搜索与排序
- ? 排名网格 — 所有排名的可视化网格,包含图标、颜色和进度指示器
- ?️ 显示排名选择器 — 选择你已获得的任意排名作为显示头衔
- ? 玩家详情弹窗 — 点击任何玩家以查看其完整档案
- ? 排名详情弹窗 - 点击任何排名以查看阈值、奖励和描述
?️ 显示排名
让玩家炫耀他们最喜欢的已获排名!一旦达到某个排名,你可以将其设置为显示排名 — 它将以带下划线和颜色的后缀形式出现在聊天中你的名字旁边。
- 与 LuckPerms 后缀 和 Better-Forge-Chat 无缝协作
- 渐变排名在聊天中以逐字彩色文本显示
- 可通过 GUI 弹窗或
/playtime displayrank set <name> 设置
- 管理员可以为任何玩家设置显示排名
? 智能 AFK 检测
仅在你真正游玩时才计算游玩时间。多信号活动检测系统监控以下内容:
- ? 视角旋转
- ? 位置移动
- ? 快捷栏槽位切换
- ? 疾跑开关
- ⚔️ 交互行为(破坏/放置方块、攻击、聊天)
玩家必须产生多种不同的信号类型才会被视为活跃 — 简单的 AFK 宏无法欺骗该系统!当检测到 AFK 状态时,会出现操作栏消息,追踪将暂停,直到真实活动恢复为止。
? LuckPerms 集成
与 LuckPerms 组无缝同步排名:
- ✅ 自动组同步 — 排名提升 → 移除旧的 LP 组,添加新的组
- ? 前缀颜色 — 读取 LP 组前缀以用于显示颜色
- ? 批量重新同步 —
/playtimeadmin rank sync 修复任何不匹配项
- ⚙️ 按排名控制 — 为每个排名切换
syncWithLuckPerms 以实现细粒度控制
- ?️ 显示排名后缀 — 通过 LP API 自动设置彩色格式化的后缀
? 没有 LuckPerms?没问题。 该模组可独立运行,自带集成的聊天格式化器和备用颜色方案。
?️ OpenPAC 领地管理
与 Open Parties and Claims 集成,实现领地管理的自动化:
- ? 按权限组限制领地数量 — 更高权限的玩家拥有更多的领地和强制加载区块数
- ? 闲置清理 — 自动清除不活跃玩家的领地
- ⏱️ 各权限组的闲置阈值 — 每个权限组都有独立的超时时间(1天 → 永不)
- ?️ 豁免权 — 高级权限组可被设置为免受清理影响(
inactivityDays: -1)
- ? 试运行模式 — 测试清理功能而不会实际删除任何内容
- ? 模块化的闲置操作 — 在玩家闲置时运行任意命令,而不仅仅是清除领地
? 数据安全与备份
你的玩家数据非常珍贵。游戏时长是它的保护伞:
- ? 轮换备份 — 每小时、每天和每周的自动快照
- ? 手动备份 — 随时使用
/playtimeadmin backup now
- ?️ 安全加载防损坏 — 如果
players.json 损坏,模组将拒绝覆盖它
- ? 定期保存 — 会话数据每 30 秒刷新一次,完整保存每 5 分钟执行一次
- ? 基于 UUID 的记录 — 即使玩家用户名更改,玩家身份也不会丢失
?️ 完整的管理员命令套件
无需离开游戏即可管理一切:
| 命令 |
描述 |
/playtimeadmin list <player> |
? 查看详细的玩家信息 |
/playtimeadmin add/remove/set <player> <time> |
⏱️ 修改玩家的游戏时长 |
/playtimeadmin reset <player> |
?️ 重置玩家的完整数据 |
/playtimeadmin rank set <player> <rank> |
?️ 强制设置玩家的权限组等级 |
/playtimeadmin rank sync |
? 批量同步所有玩家与 LuckPerms (LP) 的数据 |
/playtimeadmin rank add/remove/edit |
✏️ 在游戏内对权限组进行完整的增删改查 (CRUD) |
/playtimeadmin rank list |
? 带有编辑按钮的交互式权限组列表 |
/playtimeadmin rank gradient <id> <colors...> |
? 为权限组设置渐变色颜色 |
/playtimeadmin setdisplayrank <player> <rank> |
?️ 设置任何玩家的显示等级 |
/playtimeadmin cleanup [dryrun] |
? 运行闲置清理 |
/playtimeadmin backup now |
? 创建手动备份 |
/playtimeadmin reload |
? 热重载权限组配置 |
/playtimeadmin import <file> |
? 从旧版 KubeJS 数据导入 |
灵活的时间格式: 1h30m, 2d4h, 45m, 90s,甚至是小数小时如 2.5。
? 升级效果
让升级感觉史诗般震撼:
- ? 服务器广播 — 当有人升级时,所有人都知道
- ? 自定义音效 — 升级时可配置的音效
- ? 标题显示 — 屏幕中央的大标题,带有可配置的淡入淡出时间
- ⚡ 自定义命令 — 在升级时运行任意命令(奖励、效果等)
? 玩家命令
| 命令 |
功能 |
/playtime |
? 查看你的游戏时长统计、当前等级和进度 |
/playtime top [page] |
? 全服务器的游戏时长排行榜 |
/playtime displayrank set <name> |
?️ 设置你的显示等级 |
/playtime displayrank clear |
❌ 清除你的显示等级 |
/ranks [page] |
? 浏览所有等级及其阈值和奖励 |
⚙️ 配置
所有内容均可通过 config/playtime.toml 进行配置:
- ? AFK 设置 — 超时时间、灵敏度、信号阈值
- ? 保存间隔 — 数据刷新和写入的频率
- ? 备份计划 — 启用/禁用、检查间隔
- ? 清理设置 — 启用/禁用、启动延迟
- ? 集成 — 独立切换 LuckPerms 和 OpenPAC 的支持
- ? 升级效果 — 声音、音量、音调、标题计时、广播
- ?️ 权限 — 管理员命令的权限级别
- ? 页面大小 — 自定义
/ranks 和 /playtime top 的分页
- ? 聊天格式化 — 完全控制集成的聊天格式化器
权限组配置位于 <world>/playtime/ranks.json — 可在游戏内或手动编辑。
? 安装
- 需要 Minecraft 1.20.1 和 Forge 47.x
- 将
playtime-1.0.jar 放入服务器的 mods/ 文件夹中
- 启动服务器 — 配置和数据目录会自动创建
- (可选) 安装 LuckPerms 以进行组同步
- (可选) 安装 Open Parties and Claims 以进行领地管理
?️ 仅限服务端! 客户端无需安装此模组。玩家可以在未安装的情况下正常连接。
? 兼容性
所有集成功能均为可选——在运行时自动检测,若未检测到对应模组则静默禁用。
? 等级进阶
以下是从首次登录到获得终极力量的完整 33 级旅程:
? 阶段 1 — 脚踏实地 (1小时 → 16小时)
新手 → 探索者 → 采集者 → 定居者 (渐变下划线)
? 阶段 2 — 奥术之力 (24小时 → 65小时)
学徒 → 炼金术士 → 智者 → 巫师 (渐变下划线)
⚙️ 阶段 3 — 工业时代 (80小时 → 140小时)
工匠 → 机械师 → 齿轮匠 → 蒸汽领主 (渐变粗体)
? 阶段 4 — 技术革新 (170小时 → 275小时)
技术员 → 工程师 → 建筑师 → 指挥官 (渐变粗体)
? 阶段 5 — 升空之旅 (320小时 → 485小时)
飞行员 → 宇航员 → 太空人 → 轨道行者 (渐变粗体)
? 阶段 6 — 星际漫游 (550小时 → 775小时)
星际旅行者 → 行星漫步者 → 星系驯兽师 → 星辰追寻者 (渐变粗体)
? 阶段 7 — 宇宙操纵者 (860小时 → 1145小时)
裂隙塑造者 → 时间扭曲者 → 虚空编织者 → 日蚀使者 (渐变粗体)
⭐ 阶段 8 — 绝对存在 (1180小时 → 1250小时)
飞升者 → 天神 → 超新星 → 奇点 (全渐变粗体)
? 奇点 —— 1,250 小时,2,000 个领地,32 个强制加载区块,永不过期。这是最终的等级。
❓ 常见问题
问:客户端需要安装此模组吗?
? 不需要!它完全运行在服务端。客户端可以正常连接。
问:我可以自定义等级吗?
✅ 可以!编辑 ranks.json 或使用 /playtimeadmin rank 命令。你可以添加任意数量的等级——没有上限。
问:挂机(AFK)时间会被计算在内吗?
? 不会。该模组使用多信号检测机制。玩家必须表现出多种类型的活动(如移动+旋转、交互+快捷栏变化等)才会被计入在线时长。
问:如果我的数据文件损坏了怎么办?
?️ 模组会拒绝覆盖损坏的数据,并在修复之前停止写入操作。自动备份(每小时、每天、每周)确保你始终拥有最近的时间快照以供恢复。
问:我可以从旧的 KubeJS 在线时长系统迁移吗?
✅ 可以!使用 /playtimeadmin import <filepath> 导入你的旧版数据。
问:如果我没有安装 LuckPerms 或 OpenPAC 怎么办?
? 模组可以完美独立运行。集成功能在运行时自动检测——如果未安装相关模组,这些功能将被静默跳过。
? 许可证
保留所有权利。
为 Minecraft 社区 ❤️ 制作。
? What Is Playtime?
Playtime is a powerful server-side only Forge mod that tracks every player's active playtime and automatically progresses them through a fully customizable rank system. It's AFK-aware, so idle time doesn't count — only real gameplay earns ranks.
Whether you're running a small community server or a massive network, Playtime gives you the tools to reward dedication, manage claims, and keep your server clean — all without touching a single config file manually (though you can if you want to!).
✨ Key Features
?️ 33-Rank Progression System
Progress through 8 themed phases — from humble Beginner to the almighty Singularity. Each rank unlocks more claim chunks, forceloaded chunks, and comes with its own unique color and icon.
| Phase |
Theme |
Ranks |
Style |
| ? Phase 1 |
The Grounded |
Starter → Settler |
Survival & Settlement |
| ? Phase 2 |
The Arcane |
Apprentice → Wizard |
Magic & Mysticism |
| ⚙️ Phase 3 |
The Industrial |
Tinker → Steamlord |
Steampunk Era |
| ? Phase 4 |
The Technological |
Technician → Commander |
Modern Engineering |
| ? Phase 5 |
The Ascent |
Aviator → Orbiteer |
Atmosphere & Early Space |
| ? Phase 6 |
The Interplanetary |
Spacefarer → Starseeker |
Deep Space & Colonization |
| ? Phase 7 |
The Cosmic Manipulators |
Riftshaper → Eclipsebringer |
Bending Physics |
| ⭐ Phase 8 |
The Absolute |
Ascendant → Singularity |
God-Tier |
? Fully customizable! Add, remove, or edit any rank in-game or via JSON. There's no limit — have 16 ranks or 200!
? Rich Color System
Ranks aren't just names — they're visual experiences.
- ? Single hex colors —
&#FFA500 for a clean, bold look
- ? Multi-stop gradients —
gradient:#DDA0DD-#00CED1-#FFD700 for stunning rank titles
- ✏️ Formatting — Bold, underline, italic, and more via
§l, §n, etc.
- ? Pre-baked per-character gradients — Full compatibility with Better-Forge-Chat
Phase finals use gradients composed of their phase's 3 preceding colors — Phases 1–2 are underlined, Phases 3+ are bold, and Phase 8 is all gradient + bold. ?
?️ Custom In-Game GUI
Open the Playtime GUI to see everything at a glance:
- ? Your stats — Total playtime, current rank, next rank, and time remaining
- ? Player list — See all players, their ranks, and playtime with search & sorting
- ? Rank grid — Visual grid of all ranks with icons, colors, and progress indicators
- ?️ Display Rank selector — Pick any rank you've earned as your display title
- ? Player detail popups — Click any player to see their full profile
- ? Rank detail popups — Click any rank for thresholds, benefits, and descriptions
?️ Display Ranks
Let players show off their favorite earned rank! Once you've reached a rank, you can set it as your display rank — it appears as an underlined, colored suffix next to your name in chat.
- Works seamlessly with LuckPerms suffixes and Better-Forge-Chat
- Gradient ranks show per-character colored text in chat
- Set via the GUI popup or
/playtime displayrank set <name>
- Admins can set display ranks for any player
? Smart AFK Detection
Playtime only counts when you're actually playing. The multi-signal activity detection system watches for:
- ? Camera rotation
- ? Position movement
- ? Hotbar slot changes
- ? Sprint toggles
- ⚔️ Interactions (block break/place, attacks, chat)
Players must produce multiple distinct signal types to be considered active — simple AFK macros won't fool it! When AFK is detected, an action bar message appears and tracking pauses until real activity resumes.
? LuckPerms Integration
Seamlessly sync ranks with LuckPerms groups:
- ✅ Auto group sync — Rank up → old LP group removed, new one added
- ? Prefix colors — Reads LP group prefixes for display colors
- ? Bulk resync —
/playtimeadmin rank sync fixes any mismatches
- ⚙️ Per-rank control — Toggle
syncWithLuckPerms per rank for fine-grained control
- ?️ Display rank suffixes — Colored, formatted suffixes set automatically via LP API
? No LuckPerms? No problem. The mod works standalone with its own integrated chat formatter and fallback colors.
?️ OpenPAC Claim Management
Integrate with Open Parties and Claims for automatic claim management:
- ? Claim limits by rank — Higher ranks get more claims and forceloads
- ? Inactivity cleanup — Automatically wipe claims from inactive players
- ⏱️ Per-rank inactivity thresholds — Each rank has its own timeout (1 day → never)
- ?️ Immunity — Top ranks can be made immune to cleanup (
inactivityDays: -1)
- ? Dry run mode — Test cleanup without actually removing anything
- ? Modular inactivity actions — Run any commands on inactivity, not just claim wipes
? Data Safety & Backups
Your player data is precious. Playtime protects it:
- ? Rotating backups — Hourly, daily, and weekly automatic snapshots
- ? Manual backups —
/playtimeadmin backup now anytime
- ?️ Wipe-safe loading — If
players.json is corrupt, the mod refuses to overwrite it
- ? Periodic saves — Session data flushed every 30s, full save every 5 minutes
- ? UUID-keyed records — Player identity is never lost, even if usernames change
?️ Full Admin Command Suite
Manage everything without leaving the game:
| Command |
Description |
/playtimeadmin list <player> |
? View detailed player info |
/playtimeadmin add/remove/set <player> <time> |
⏱️ Modify player playtime |
/playtimeadmin reset <player> |
?️ Full player data reset |
/playtimeadmin rank set <player> <rank> |
?️ Force-set a player's rank |
/playtimeadmin rank sync |
? Bulk resync all players with LP |
/playtimeadmin rank add/remove/edit |
✏️ Full rank CRUD in-game |
/playtimeadmin rank list |
? Interactive rank list with edit buttons |
/playtimeadmin rank gradient <id> <colors...> |
? Set gradient colors for a rank |
/playtimeadmin setdisplayrank <player> <rank> |
?️ Set display rank for any player |
/playtimeadmin cleanup [dryrun] |
? Run inactivity cleanup |
/playtimeadmin backup now |
? Create manual backup |
/playtimeadmin reload |
? Hot-reload rank config |
/playtimeadmin import <file> |
? Import from legacy KubeJS data |
Flexible time formats: 1h30m, 2d4h, 45m, 90s, or even decimal hours like 2.5.
? Rank-Up Effects
Make rank-ups feel epic:
- ? Server broadcast — Everyone knows when someone ranks up
- ? Custom sound — Configurable sound effect on rank-up
- ? Title display — Big on-screen title with configurable fade timings
- ⚡ Custom commands — Run any commands on rank-up (rewards, effects, etc.)
? Player Commands
| Command |
What It Does |
/playtime |
? View your playtime stats, current rank, and progress |
/playtime top [page] |
? Server-wide playtime leaderboard |
/playtime displayrank set <name> |
?️ Set your display rank |
/playtime displayrank clear |
❌ Clear your display rank |
/ranks [page] |
? Browse all ranks with thresholds and rewards |
⚙️ Configuration
Everything is configurable via config/playtime.toml:
- ? AFK settings — Timeout, sensitivity, signal thresholds
- ? Save intervals — How often data is flushed and written
- ? Backup schedule — Enable/disable, check intervals
- ? Cleanup settings — Enable/disable, startup delay
- ? Integrations — Toggle LuckPerms and OpenPAC independently
- ? Rank-up effects — Sound, volume, pitch, title timings, broadcasts
- ?️ Permissions — Admin command permission level
- ? Page sizes — Customize
/ranks and /playtime top pagination
- ? Chat formatting — Full control over the integrated chat formatter
Ranks are configured in <world>/playtime/ranks.json — editable in-game or by hand.
? Installation
- Requires Minecraft 1.20.1 with Forge 47.x
- Drop
playtime-1.0.jar into your server's mods/ folder
- Start the server — config and data directories are created automatically
- (Optional) Install LuckPerms for group syncing
- (Optional) Install Open Parties and Claims for claim management
?️ Server-side only! Clients do NOT need to install this mod. Players can connect without it.
? Compatibility
All integrations are optional — detected at runtime and silently disabled if not present.
? The Rank Progression
Here's the full 33-rank journey from first login to ultimate power:
? Phase 1 — The Grounded (1h → 16h)
Starter → Explorer → Gatherer → Settler (gradient underline)
? Phase 2 — The Arcane (24h → 65h)
Apprentice → Alchemist → Sage → Wizard (gradient underline)
⚙️ Phase 3 — The Industrial (80h → 140h)
Tinker → Machinist → Cogwright → Steamlord (gradient bold)
? Phase 4 — The Technological (170h → 275h)
Technician → Engineer → Architect → Commander (gradient bold)
? Phase 5 — The Ascent (320h → 485h)
Aviator → Astronaut → Cosmonaut → Orbiteer (gradient bold)
? Phase 6 — The Interplanetary (550h → 775h)
Spacefarer → Planetwalker → Galaxytamer → Starseeker (gradient bold)
? Phase 7 — The Cosmic Manipulators (860h → 1145h)
Riftshaper → Chronoshifter → Voidweaver → Eclipsebringer (gradient bold)
⭐ Phase 8 — The Absolute (1180h → 1250h)
Ascendant → Celestial → Hypernova → Singularity (all gradient bold)
? Singularity — 1,250 hours, 2,000 claims, 32 forceloads, never expires. The ultimate rank.
❓ FAQ
Q: Do clients need to install this mod?
? No! It's entirely server-side. Clients connect normally.
Q: Can I customize the ranks?
✅ Yes! Edit ranks.json or use /playtimeadmin rank commands. Add as many ranks as you want — there's no limit.
Q: Does AFK time count?
? No. The mod uses multi-signal detection. Players must show multiple types of activity (movement + rotation, interaction + hotbar change, etc.) to be tracked.
Q: What happens if my data file gets corrupted?
?️ The mod refuses to overwrite corrupted data and disables writes until you fix it. Automatic backups (hourly, daily, weekly) ensure you always have a recent snapshot to restore from.
Q: Can I migrate from the old KubeJS playtime system?
✅ Yes! Use /playtimeadmin import <filepath> to import your legacy data.
Q: What if I don't use LuckPerms or OpenPAC?
? The mod works perfectly standalone. Integrations are detected at runtime — if they're not installed, those features are silently skipped.
? License
All Rights Reserved.
Made with ❤️ for the Minecraft community.
评论 0
登录后参与评分
还没有评论,来抢沙发吧