BetterMOTDS
适用于 Paper/Purpur 26.3 — Java 25 — 版本 2.1.0
BetterMOTDS 自定义了您的服务器在多人游戏服务器列表中的显示方式。它设置一个两行的 MOTD(维护公告),控制显示的在线玩家数量(真实或伪造),添加鼠标悬停时的玩家样本,并更换服务器图标——正常模式和维护模式拥有完全独立的配置档案。MOTD 条目可以随机、顺序或按天轮换,每个条目都可以携带自己的图标。
格式支持 MiniMessage、十六进制颜色代码和旧版颜色代码。
功能
- 双行 MOTD,支持针对每个条目的独立配置。
- MOTD 轮换 —
random(随机)、sequential(顺序)或 per-day(按天)。
- 自定义服务器图标 — 一个默认图标加上可选的每个 MOTD 专属图标(64x64 PNG)。
- 玩家数量控制 — 对在线数量和最大数量均可设置为
real(真实)、static(固定)、random(随机)或 offset(偏移)。
- 悬停玩家样本 — 在列表中悬停玩家数量时显示的自定义行。
- 独立的维护配置档案 — 拥有其自身的 MOTD、图标、数量、悬停文本和原因说明。
- 维护期间禁止加入 — 在维护期间踢出尝试加入的玩家,提供绕过权限和可配置的踢出消息。
- 灵活的格式支持 — MiniMessage、十六进制 (
&#RRGGBB) 和旧版 & 代码。
- 占位符 —
{online}、{max}、{fake_online}、{fake_max}、{tps}、{reason}。
- 双语语言文件 — 包含
en_US 和 pt_PT。
命令
| 命令 |
描述 |
权限 |
/motd reload |
重新加载配置文件和语言文件。 |
motd.admin |
/motd status |
显示维护模式是否处于激活状态(及其原因)。 |
motd.admin |
别名:/bmotd。
权限
| 节点 |
描述 |
默认值 |
motd.admin |
允许重新加载配置和检查状态。 |
op |
motd.maintenance.bypass |
允许在维护模式激活期间加入服务器。 |
op |
配置
以下是默认 config.yml 中主要键值的摘录:
language: en_US
normal:
default-icon: "icons/server-icon.png"
motd:
rotation-mode: random # random, sequential, per-day
motds:
- line1: "<gradient:#1E90FF:#00BFFF>My Awesome Server</gradient> &8| &7Paper 26.3"
line2: "&aCome join us! &7({online}/{max})"
# icon: "icons/pvp.png" # optional per-MOTD icon
- line1: "&bWelcome to the server!"
line2: "&7Type &f/discord &7for news"
player-count:
online:
mode: real # real, static, random, offset
value: 0
min: 10
max: 50
max:
mode: static
value: 100
hover:
enabled: true
lines:
- "&b&lMy Awesome Server"
- ""
- "&7Website: &a&nwww.example.com"
maintenance:
enabled: false
reason: ""
default-icon: "icons/maintenance-icon.png"
motds:
- line1: "&cMaintenance Mode"
line2: "&7We'll be back soon! &f{reason}"
player-count:
online:
mode: static
value: -1
max:
mode: static
value: -1
hover:
enabled: true
lines:
- "&c&lMaintenance Mode"
- "&7Reason: {reason}"
join-block:
enabled: true
kick-message-key: "maintenance.kick_message"
default-reason: ""
关键点说明:
rotation-mode — 插件如何在每次连接请求(ping)时循环切换多个 motds 条目。
player-count.*.mode — real 使用实时计数;static 显示固定值;random 在 min/max 之间随机选择;offset 将 value 加到真实计数上。计数值为 -1 时将隐藏数字。
- 图标 — 将 PNG 文件放置在
plugins/BetterMOTDS/ 目录下(例如 icons/server-icon.png)。图标为 64x64 像素,并缓存在内存中,因此连接请求不会进行磁盘 I/O。
maintenance.join-block — 当启用维护模式时,除非玩家拥有 motd.maintenance.bypass 权限,否则尝试加入的玩家将被踢出。
安装
- 需要 Paper 或 Purpur 26.3 以及 Java 25(2.0.0 运行于 26.2,1.x 版本运行于 1.21.x)(使用 Paper 的服务器列表 ping API)。
- 将
BetterMOTDS.jar 放入服务器的 plugins/ 文件夹。
- 启动服务器一次以生成
config.yml、语言文件和图标文件夹。
- 添加您的图标并编辑
config.yml,然后运行 /motd reload。
依赖项
- MaintenancePlugin(可选)— 检测名为
MaintenancePlugin 且暴露了 isMaintenanceEnabled() 方法的插件,或者检测 plugins/MaintenancePlugin/state.yml 文件(由同一作者制作的配套插件)。其他维护插件不会被检测;始终可以通过此插件自身的配置来控制维护模式。
支持 / 源码
源代码:
BetterMOTDS
For Paper/Purpur 26.3 — Java 25 — Version 2.1.0
BetterMOTDS customizes how your server appears in the multiplayer server list. It sets a
two-line MOTD, controls the displayed player count (real or faked), adds a hover player-sample,
and swaps the server icon — with completely separate profiles for normal and maintenance
mode. MOTD entries can rotate randomly, sequentially or per day, and each entry can carry its own
icon.
Formatting supports MiniMessage, hex colors and legacy color codes.
Features
- Two-line MOTD with per-entry configuration.
- MOTD rotation —
random, sequential or per-day.
- Custom server icons — a default icon plus optional per-MOTD icons (64x64 PNG).
- Player count control —
real, static, random or offset for both the online and max
counts.
- Hover player-sample — custom lines shown when hovering the player count in the list.
- Separate maintenance profile — its own MOTD, icon, counts, hover and reason.
- Maintenance join blocking — kick joining players during maintenance, with a bypass
permission and a configurable kick message.
- Flexible formatting — MiniMessage, hex (
&#RRGGBB) and legacy & codes.
- Placeholders —
{online}, {max}, {fake_online}, {fake_max}, {tps}, {reason}.
- Bilingual language files —
en_US and pt_PT included.
Commands
| Command |
Description |
Permission |
/motd reload |
Reload the configuration and language files. |
motd.admin |
/motd status |
Show whether maintenance mode is active (and its reason). |
motd.admin |
Alias: /bmotd.
Permissions
| Node |
Description |
Default |
motd.admin |
Allows reloading the configuration and checking status. |
op |
motd.maintenance.bypass |
Allows joining the server while maintenance mode is active. |
op |
Configuration
An excerpt of the default config.yml showing the main keys:
language: en_US
normal:
default-icon: "icons/server-icon.png"
motd:
rotation-mode: random # random, sequential, per-day
motds:
- line1: "<gradient:#1E90FF:#00BFFF>My Awesome Server</gradient> &8| &7Paper 26.3"
line2: "&aCome join us! &7({online}/{max})"
# icon: "icons/pvp.png" # optional per-MOTD icon
- line1: "&bWelcome to the server!"
line2: "&7Type &f/discord &7for news"
player-count:
online:
mode: real # real, static, random, offset
value: 0
min: 10
max: 50
max:
mode: static
value: 100
hover:
enabled: true
lines:
- "&b&lMy Awesome Server"
- ""
- "&7Website: &a&nwww.example.com"
maintenance:
enabled: false
reason: ""
default-icon: "icons/maintenance-icon.png"
motds:
- line1: "&cMaintenance Mode"
line2: "&7We'll be back soon! &f{reason}"
player-count:
online:
mode: static
value: -1
max:
mode: static
value: -1
hover:
enabled: true
lines:
- "&c&lMaintenance Mode"
- "&7Reason: {reason}"
join-block:
enabled: true
kick-message-key: "maintenance.kick_message"
default-reason: ""
Key points:
rotation-mode — how the plugin cycles through multiple motds entries per ping.
player-count.*.mode — real uses live counts; static shows a fixed value; random
picks between min/max; offset adds value to the real count. A count of -1 hides the
numbers.
- Icons — place PNG files under
plugins/BetterMOTDS/ (for example icons/server-icon.png).
Icons are 64x64 and are cached in memory, so pings do no disk I/O.
maintenance.join-block — when maintenance is enabled, joining players are kicked unless
they hold motd.maintenance.bypass.
Installation
- Requires Paper or Purpur 26.3 and Java 25 (2.0.0 runs on 26.2, 1.x on 1.21.x) (uses the Paper server-list-ping API).
- Drop
BetterMOTDS.jar into your server's plugins/ folder.
- Start the server once to generate
config.yml, the language files and the icon folder.
- Add your icons and edit
config.yml, then run /motd reload.
Dependencies
- MaintenancePlugin (optional) — detects a plugin literally named
MaintenancePlugin exposing
isMaintenanceEnabled(), or a plugins/MaintenancePlugin/state.yml file (the companion plugin
by the same author). Other maintenance plugins are not detected; maintenance can always be
controlled from this plugin's own configuration instead.
Support / Source
Source code:
评论 0
登录后参与评分
还没有评论,来抢沙发吧