在 Minecraft 原生 Paper 对话框 UI 中完成限时国际象棋对局
Chess 将 Paper 的原生对话框系统转化为一个实时、可点击的 8x8 棋盘。挑战另一位玩家,选择计时模式,即可在不使用箱子菜单或实体棋盘的情况下进行完整的对局。
亮点
- 原生对话框棋盘: 64 个独立可点击的方格,界面简洁且实时更新。
- 完整的走子处理: 支持王车易位、吃过路兵、升变、将军、将死和逼和。
- 限时对局: 提供从一分钟超快棋到五小时慢棋的 17 种预设模式,并支持每步加时选项。
- 实用的棋盘反馈: 合法移动、选中高亮、最后一步、将军提示、吃子记录、坐标显示以及双方时钟均可直接在对话框内展示。
- 玩家友好控制: 翻转棋盘、提议或接受和棋、安全认输、关闭对话框,并可随时重新打开进行中的对局。
- 资源包感知: 纹理棋盘已打包内置,可通过 ResourcePackManager 自动注册,并提供可选的 Unicode 字符回退方案。
- 兼容 Folia: 游戏状态变更、时钟、命令、对话框发送和资源包分发均采用 Folia 安全的调度机制。
- 高度可配置: 可调整音效、过期计时器、棋盘行为、标签及提示信息。
游戏内预览
要求
- Java: 21
- 服务端: Paper 1.21.11 或基于相同 API 的 Folia
- 可选: ResourcePackManager
本插件依赖 Paper 的原生 Dialog API,无法在标准 Spigot 服务器上运行。
国际象棋引擎与棋盘资源包已包含在 Chess.jar 中;ResourcePackManager 并非必需。
快速开始
- 将
Chess.jar 放入服务器的 plugins 文件夹并重启服务器。
- 若已安装 ResourcePackManager,Chess 会自动注册其资源包。
- 若未安装 ResourcePackManager,请托管文件
plugins/Chess/resourcepack.zip,并在 plugins/Chess/settings.yml 的 resource-pack.url 中设置公开访问 URL。
- 一名玩家执行
/chess duel <player> <time> 发起挑战,另一名玩家执行 /chess accept <player> 接受挑战。
设置 ui.dialog.use-glyphs: false 可使用标准 Unicode 棋子图标而无需自定义纹理。
当由其他系统合并或分发资源包时,设置 resource-pack.use-resourcepack: false。
命令
| 命令 |
功能 |
/chess duel <player> <time> |
发送限时对决请求。 |
/chess accept <player> |
接受来自该玩家的请求。 |
/chess decline <player> |
拒绝来自该玩家的请求。 |
/chess open |
重新打开你当前的活跃棋盘。 |
/chess help |
显示命令帮助。 |
时间模式:1, 1|1, 2|1, 3, 3|2, 5, 5|2, 5|5, 10, 10|5, 15|10, 30,
60, 120, 180, 240, 和 300。在加时模式中,5|2 表示每步 5 分钟基础时间加上每步 2 秒的增量。
所有玩家均可使用 Chess;版本 1.0.0 没有权限节点限制。
支持
Complete timed chess matches in Minecraft's native Paper dialog UI
Chess turns Paper's native dialog system into a live, clickable 8x8 board. Challenge another
player, choose a clock, and play a complete match without chest menus or a physical board.
Highlights
- Native dialog board: 64 individually clickable squares in a clean, live interface.
- Complete move handling: castling, en passant, promotion, check, checkmate, and stalemate.
- Timed games: 17 presets from one-minute bullet to five-hour games, with increment options.
- Useful board feedback: legal moves, selection, last move, check, captures, coordinates, and
both clocks can be displayed directly in the dialog.
- Player-friendly controls: flip the board, offer or accept a draw, resign safely, close the
dialog, and reopen an active game at any time.
- Resource-pack aware: the textured board is bundled, can register itself with
ResourcePackManager, and has an optional Unicode fallback.
- Folia ready: game mutations, clocks, commands, dialog sends, and pack delivery use
Folia-safe scheduling.
- Configurable: tune sounds, expiry timers, board behavior, labels, and messages.
See it in game
Requirements
- Java: 21
- Server: Paper 1.21.11 or Folia based on the same API
- Optional: ResourcePackManager
This plugin requires Paper's native Dialog API and does not run on a standard Spigot server. The
chess engine and the board pack are included in Chess.jar; ResourcePackManager is not required.
Getting started
- Put
Chess.jar in the server's plugins folder and restart.
- With ResourcePackManager installed, Chess registers its pack automatically.
- Without ResourcePackManager, host
plugins/Chess/resourcepack.zip and set the public URL at
resource-pack.url in plugins/Chess/settings.yml.
- Have one player run
/chess duel <player> <time> and the other run
/chess accept <player>.
Set ui.dialog.use-glyphs: false for standard Unicode pieces without the custom textures. Set
resource-pack.use-resourcepack: false when another system will merge or distribute the pack.
Commands
| Command |
What it does |
/chess duel <player> <time> |
Send a timed duel request. |
/chess accept <player> |
Accept a request from that player. |
/chess decline <player> |
Decline a request from that player. |
/chess open |
Reopen your active board. |
/chess help |
Show command help. |
Time modes: 1, 1|1, 2|1, 3, 3|2, 5, 5|2, 5|5, 10, 10|5, 15|10, 30,
60, 120, 180, 240, and 300. In increment modes, 5|2 means five minutes plus two
seconds after each move.
All players can use Chess; version 1.0.0 has no permission nodes.
Support
评论 0
登录后参与评分
还没有评论,来抢沙发吧