⏱️ PlayTimePulse
一款轻量且精确的 Minecraft 插件,用于追踪玩家游戏时长,与 PlaceholderAPI 无缝集成,并提供带有可领取界面的内置奖励系统。
? 主要功能
- ⏳ 实时游戏时长追踪 - 准确记录每位玩家在服务器上的在线时长
- ? 24+ 项游戏时长奖励 - 基于里程碑的奖励,玩家随着游玩时间的增加即可领取
- ? 分页奖励 GUI - 易于导航的界面,为所有奖励提供多页展示
- ? 简洁命令 - 为玩家提供直观的
/playtime命令及管理员工具 - ? PlaceholderAPI 支持 - 通过占位符与其他流行插件集成
- ?️ AFK 保护 - 防止玩家利用挂机(AFK)作弊刷取时长
- ? 高效数据存储 - 使用轻量级扁平文件存储并自动保存
- ⚡ 高性能 - 经过优化的代码,不会拖慢服务器运行速度
- ?️ 奖励错误处理 - 即使命令执行失败,也能防止奖励被重复领取
- ⚙️ 灵活配置 - 轻松自定义所有奖励、GUI 和设置
? 全部功能
- ⏳ 实时游戏时长追踪(保存的历史时长 + 当前会话时长)
- ?
/playtime命令:- 以
Xd Yh Zm(天/小时/分钟)格式显示游戏时长 - 打开 GUI 以领取基于游戏时长的奖励
- 以
- ? 奖励系统:
- 基于里程碑的可领取奖励(当前配置包含 24 项奖励,未来将添加更多)
- 支持命令执行(因为大部分奖励是通过命令发放的)
- 通过追踪已领取状态来防止重复领取
- 支持玩家头颅作为 GUI 图标(例如自定义头颅或玩家骷髅头)
- 领取奖励时可播放自定义音效
- 对失败的命令进行错误处理,以防止奖励被恶意刷屏领取
- ? 分页奖励 GUI:
- 支持大量奖励的分页功能
- 可自定义每页显示的槽位数
- 提供用于翻页的导航按钮
- ? 导航系统:
- 上一页/下一页按钮
- 关闭按钮用于退出 GUI
- 可自定义导航按钮的材质和名称
- 可选为导航按钮设置自定义头颅纹理
- ?️ AFK 保护:
- 防止玩家利用挂机刷取游戏时长
- 可配置交互阈值和时间窗口
- 追踪有意义的玩家交互以验证活动状态
- ? 完整的 PlaceholderAPI 支持
- ? bStats 集成,用于匿名使用统计
- ? 扁平文件存储,支持自动保存
- ⚙️ 性能优化,易于配置
? 命令
| 命令 | 描述 | 权限 |
|---|---|---|
/playtime |
显示游戏时长与奖励 GUI | playtime.use |
| /playtime add <玩家> <小时数>h [<分钟数>m] | 为指定玩家增加游戏时长 | playtime.admin |
| /playtime reset <玩家> | 重置指定玩家的游戏时长及已领取的奖励 | playtime.admin |
? PlaceholderAPI 支持
| 占位符 | 描述 |
|---|---|
%playtime_overall_formatted% |
总时间(已保存 + 当前),格式如 2d 4h 30m |
%playtime_formatted% |
仅当前会话,格式化显示 |
%playtime_overall% |
总时间(秒,已保存 + 当前) |
%playtime_saved% |
仅已保存时间(秒) |
| %playtime_current% | 当前在线会话时长(以秒为单位) |
? 未来计划
- ? 支持格式化文本的渐变色
- ? 领取奖励时的粒子特效
- ? 调试模式,便于故障排查
- ➕ 更多功能即将推出
? 配置
config.yml:定义游戏时长里程碑、奖励(命令)、要求、奖励图标/描述以及音效。- 每个奖励在领取时都可以通过
claimSound参数自定义音效 - 从超过 400 种 Minecraft 音效中选择(例如
entity.player.levelup、block.note_block.pling) - 所有音效均以标准音量(1.0)和音调(1.0)播放
- 可以使用带有 Base64 纹理值的
headId添加自定义头颅 - 使用
page参数指定奖励应显示在哪一页(从 0 开始) - 导航按钮可以使用带有
headId参数的自定义玩家头颅 - GUI 槽位和每页槽位数均可配置
- AFK 保护设置:
interaction-threshold:时间窗口内所需的最少交互次数time-window-minutes:用于检查交互的时间窗口(分钟)
- 每个奖励在领取时都可以通过
? 安装
- 下载最新版本
- 将
.jar文件放入/plugins文件夹 - 重启服务器
- 配置
config.yml以定义奖励和要求。 - (可选)安装 PlaceholderAPI 以使用占位符
✅ 要求
- Minecraft:
1.21 至 1.21.8 - Java:
21+ - 服务端:Paper / Pufferfish / Purpur(其他服务端需自行测试)
- (可选)PlaceholderAPI
? 统计信息
PlayTimePulse 通过 bStats 收集匿名使用统计数据。这有助于我们了解插件的使用情况,并指导未来的开发方向。
您可以在 bStats 查看插件的统计数据。
若要退出数据统计收集,请在 /plugins/bStats/config.yml 文件中设置 enabled: false。
? 支持
- ? 提交问题
- ? Discord
⏱️ PlayTimePulse
A lightweight, accurate Minecraft plugin that tracks player playtime, integrates seamlessly with PlaceholderAPI, and provides a built-in rewards system with a claimable GUI.
? Main Features
- ⏳ Real-time Playtime Tracking - Accurately tracks how long each player has been on your server
- ? 24+ Playtime Rewards - Milestone-based rewards that players can claim as they play more
- ? Pageable Rewards GUI - Easy-to-navigate interface with multiple pages for all rewards
- ? Simple Commands - Intuitive
/playtimecommand for players and admin tools - ? PlaceholderAPI Support - Integrates with popular plugins through placeholders
- ?️ AFK Protection - Prevents players from cheating by being AFK
- ? Efficient Data Storage - Lightweight flat-file storage with automatic saving
- ⚡ High Performance - Optimized code that won't slow down your server
- ?️ Reward Error Handling - Prevents reward spamming even when commands fail
- ⚙️ Flexible Configuration - Easily customize all rewards, GUI, and settings
? All Features
- ⏳ Real-time playtime tracking (saved + current session)
- ?
/playtimecommand:- Shows formatted playtime in
Xd Yh Zm - Opens a GUI to claim playtime-based rewards
- Shows formatted playtime in
- ? Reward System:
- Milestone-based claimable rewards (24 rewards included in current config, with more to be added over time)
- Supports commands (since most of the things are given by commands)
- Blocks duplicate claiming with tracked saves
- Player head support for GUI icons (e.g., custom heads, player skulls)
- Custom sound effects when claiming rewards
- Error handling for failed commands to prevent reward spamming
- ? Pageable Rewards GUI:
- Pagination support for large numbers of rewards
- Customizable slots per page
- Navigation buttons for moving between pages
- ? Navigation System:
- Previous/Next page buttons
- Close button to exit the GUI
- Customizable navigation button materials and names
- Optional custom head textures for navigation buttons
- ?️ AFK Protection:
- Prevents AFK farming of playtime
- Configurable interaction threshold and time window
- Tracks meaningful player interactions to validate activity
- ? Full PlaceholderAPI support
- ? bStats integration for anonymous usage statistics
- ? Flat-file storage with autosave
- ⚙️ Performance optimized and easy to configure
? Commands
| Command | Description | Permission |
|---|---|---|
/playtime |
Shows playtime and rewards GUI | playtime.use |
/playtime add <player> <hours>h [<minutes>m] |
Add playtime to player | playtime.admin |
/playtime reset <player> |
Reset player's playtime and claimed rewards | playtime.admin |
? PlaceholderAPI Support
| Placeholder | Description |
|---|---|
%playtime_overall_formatted% |
Total time (saved + current), formatted like 2d 4h 30m |
%playtime_formatted% |
Current session only, formatted |
%playtime_overall% |
Total time in seconds (saved + current) |
%playtime_saved% |
Saved playtime only (in seconds) |
%playtime_current% |
Current online session (in seconds) |
? Future Plans
- ? Gradient color support for formatted text
- ? Particle effects for reward claiming
- ? Debug mode for easier troubleshooting
- ➕ More features coming soon
? Configuration
config.yml: Define playtime milestones, rewards (commands), requirements, rewards icon/lore, and sound effects.- Each reward can have a custom sound when claimed using the
claimSoundparameter - Choose from over 400 Minecraft sounds (e.g.,
entity.player.levelup,block.note_block.pling) - All sounds play at standard volume (1.0) and pitch (1.0)
- Custom heads can be added using
headIdwith Base64 texture values - Specify which page a reward should appear on using the
pageparameter (starting from 0) - Navigation buttons can use custom player heads with
headIdparameter - GUI slots and slots per page are configurable
- AFK protection settings:
interaction-threshold: Minimum number of interactions required in the time windowtime-window-minutes: Time window in minutes to check for interactions
- Each reward can have a custom sound when claimed using the
? Installation
- Download the latest release
- Drop the
.jarfile into your/pluginsfolder - Restart the server
- Configure
config.ymlto define rewards / requirements. - (Optional) Install PlaceholderAPI for placeholders
✅ Requirements
- Minecraft:
1.21 up to 1.21.8 - Java:
21+ - Server: Paper / Pufferfish / Purpur (others need testing)
- (Optional) PlaceholderAPI
? Statistics
PlayTimePulse collects anonymous usage statistics through bStats. This helps us understand how the plugin is used and guides future development.
You can view plugin statistics at bStats.
To opt out of statistics collection, set enabled: false in the /plugins/bStats/config.yml file.
? Support
- ? Open an issue
- ? Discord
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayTimePulse
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
? 版本 1.0.5-SNAPSHOT – 自定义更新
✨ 新增内容
- 配置:
disable-default-reward-information— 完全自定义奖励文本。 - 奖励: 为等级 20–23 添加了原生 Minecraft 奖励(无需外部插件依赖)。
? 修复
- 修复了阻止访问多页奖励的页面导航错误。
- 修正了 "More Rewards Coming Soon" 物品的显示行为。
⚙️ 更改
- 移除了不必要的
clear-default-rewards配置参数。 - 修正了默认配置文件中的 YAML 格式。
- 仅使用标准物品和命令,增强了与 Minecraft 原生的兼容性。
总结:
此更新让服务器管理员能够完全控制向玩家展示奖励信息的方式,同时修复了一个关键的导航问题,该问题曾导致无法访问后续页面的奖励。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
插件
PacketEvents 是一款专为 Minecraft Java 版打造的协议库,旨在简化数据包的处理与传输。
插件
ExyliaPlugins 的库。
插件
通过对话框或铁砧界面帮助你的 Anthme
插件
重新定义服务器上的生物运输方式。使用高度可定制的口袋道具,安全地捕获、存储和释放任何实体。
插件
为基于 Spigot/Paper/Folia 的服务器添加对 Vivecraft 的支持
插件
用于绘制游戏内地图或在浏览器中随探索实时进行地图绘制的实时地图。
评论 0
登录后参与评分
还没有评论,来抢沙发吧