? ResourcePackEnforcer
强制你的服务器资源包 —— 支持踢出提示、更新检查器与全面自定义。
? 概述
ResourcePackEnforcer 是一款轻量级的 Spigot 插件,会在玩家加入时自动向其发送资源包。如果玩家拒绝接受,他们将被踢出服务器并显示完全可定制的提示消息 —— 再也不会有玩家绕过你服务器的资源包要求了!
所有功能开箱即用,均可配置。配置文件会在首次启动时自动生成,包含完整的注释说明;在插件更新后,缺失的配置项也会自动添加。
✨ 特性
- ? 自动发送 —— 玩家加入时向每位玩家发送资源包
- ? 强制模式 —— 拒绝接受的玩家会被立即踢出
- ? 自定义踢出消息 —— 完整支持颜色代码 (
&) 和十六进制颜色 (&#RRGGBB)
- ? 提示消息 —— 请求资源包时显示的自定义文本 (1.17+)
- ? SHA-1 哈希验证 —— 可选的哈希校验以确保资源包完整性
- ⏱️ 可配置的发送延迟 —— 调整发送资源包前的延迟(单位:刻)
- ?️ 豁免权限 —— 允许工作人员跳过资源包要求
- ? 自动更新检查器 —— 在启动时检查 GitHub Releases,并在游戏内通知管理员
- ? 十六进制颜色支持 —— 所有消息中均支持
&#RRGGBB (1.16+)
- ? 控制台横幅 —— 插件启动、停止及有可用更新时在控制台显示 ASCII 横幅
- ⚙️ 自动生成配置 —— 首次启动时生成带注释的配置文件,缺失键值自动添加
⚙️ 配置
resourcepack:
# 资源包 (.zip) 的直接下载 URL
url: "https://example.com/resourcepack.zip"
# 用于验证的 SHA-1 哈希值(或设为 "none" 以禁用)
hash: "none"
# 请求资源包时显示的提示消息 (1.17+)
prompt: "&e请接受资源包以加入服务器!"
# true = 拒绝则踢出 | false = 可选
enforce: true
# 发送前的延迟(单位:刻,20 刻 = 1 秒)
send-delay: 20
messages:
kick-message: |-
&c&l资源包被拒绝!
&7你必须接受资源包
&7才能在此服务器上游玩。
pack-loaded: "&a&l资源包加载成功!"
pack-failed: "&c&l加载资源包失败。请重新连接!"
prefix: "&8[&6ResourcePack&8] &r"
reload-success: "&a配置已成功重载!"
pack-sent: "&a已向 %player% 发送资源包!"
? 命令
| 命令 |
描述 |
权限 |
/rp reload |
重载配置 |
resourcepack.admin |
/rp send [player] |
向指定玩家发送资源包 |
resourcepack.admin |
/rp sendall |
向所有玩家发送资源包 |
resourcepack.admin |
/rp info |
显示插件状态 |
resourcepack.admin |
别名: /resourcepack
? 权限
| 权限 |
描述 |
默认值 |
resourcepack.admin |
访问所有命令 |
OP |
resourcepack.bypass |
跳过资源包要求 |
false |
?️ 要求
|
|
| Java |
21 或更高版本 |
| 服务端 |
Spigot / Paper 1.20 或更高版本 |
? 安装
- 从版本页面下载最新的
.jar 文件
- 将其放入服务器的
plugins/ 文件夹中
- 启动服务器 ——
config.yml 将自动生成
- 在
config.yml 中输入你的资源包 URL
- 运行
/rp reload 或重启服务器
? 更新检查器
ResourcePackEnforcer 通过 GitHub Releases API 在启动时检查新版本 —— 完全异步执行,因此绝不会延迟你的服务器启动。如果发现新版本,控制台会显示横幅,并且管理员在加入时会收到聊天通知。
[ResourcePack] ⚡ 有可用更新! (1.0.0 → 1.1.0)
[ResourcePack] 下载地址: https://github.com/.../releases/latest
? 问题与支持
发现 Bug 或有疑问?请在 GitHub 上提交 Issue。
用心制作 ❤️ —— 根据 MIT License 许可
? ResourcePackEnforcer
Enforce your server's resource pack — with kick message, update checker & full customization.
? Overview
ResourcePackEnforcer is a lightweight Spigot plugin that automatically sends a resource pack to every player on join. If a player declines, they are kicked with a fully customizable message — no more players bypassing your server's resource pack!
Everything is configurable out of the box. The config is generated automatically on first start with full comments, and missing keys are added automatically after plugin updates.
✨ Features
- ? Automatic sending — Resource pack is sent to every player on join
- ? Enforce mode — Players who decline are immediately kicked
- ? Custom kick message — Full support for color codes (
&) and hex colors (&#RRGGBB)
- ? Prompt message — Custom text shown when requesting the pack (1.17+)
- ? SHA-1 hash validation — Optional hash verification for pack integrity
- ⏱️ Configurable send delay — Adjust the delay in ticks before the pack is sent
- ?️ Bypass permission — Allow staff to skip the resource pack requirement
- ? Automatic update checker — Checks GitHub Releases on startup, notifies admins in-game
- ? Hex color support —
&#RRGGBB in all messages (1.16+)
- ? Console banners — ASCII banners on plugin start, stop and available updates
- ⚙️ Auto-generated config — Created with comments on first start, missing keys added automatically
⚙️ Configuration
resourcepack:
# Direct download URL to the resource pack (.zip)
url: "https://example.com/resourcepack.zip"
# SHA-1 hash for validation (or "none" to disable)
hash: "none"
# Prompt message shown when requesting the pack (1.17+)
prompt: "&ePlease accept the resource pack to join the server!"
# true = kick on decline | false = optional
enforce: true
# Delay in ticks before sending (20 ticks = 1 second)
send-delay: 20
messages:
kick-message: |-
&c&lResource Pack Declined!
&7You must accept the resource pack
&7to play on this server.
pack-loaded: "&a&lResource pack successfully loaded!"
pack-failed: "&c&lFailed to load resource pack. Please reconnect!"
prefix: "&8[&6ResourcePack&8] &r"
reload-success: "&aConfiguration successfully reloaded!"
pack-sent: "&aResource pack sent to %player%!"
? Commands
| Command |
Description |
Permission |
/rp reload |
Reload the configuration |
resourcepack.admin |
/rp send [player] |
Send the pack to a player |
resourcepack.admin |
/rp sendall |
Send the pack to all players |
resourcepack.admin |
/rp info |
Show plugin status |
resourcepack.admin |
Alias: /resourcepack
? Permissions
| Permission |
Description |
Default |
resourcepack.admin |
Access to all commands |
OP |
resourcepack.bypass |
Skip the resource pack requirement |
false |
?️ Requirements
|
|
| Java |
21 or higher |
| Server |
Spigot / Paper 1.20 or higher |
? Installation
- Download the latest
.jar from the version tab
- Drop it into your server's
plugins/ folder
- Start the server —
config.yml is generated automatically
- Enter your resource pack URL in
config.yml
- Run
/rp reload or restart the server
? Update Checker
ResourcePackEnforcer checks for new versions on startup via the GitHub Releases API — completely asynchronous, so it never delays your server start. If a new version is found, a banner appears in the console and admins receive a chat notification on join.
[ResourcePack] ⚡ Update available! (1.0.0 → 1.1.0)
[ResourcePack] Download: https://github.com/.../releases/latest
? Issues & Support
Found a bug or have a question? Open an issue on GitHub.
Made with ❤️ — Licensed under the MIT License
评论 0
登录后参与评分
还没有评论,来抢沙发吧