BNes Fork
一个基于地图的 Minecraft 服务器用 NES 模拟器插件。此分支继续维护 MoeWhite19/BNes,并使用 Nestalgia 作为模拟核心。
这是一个由社区维护的分支,并非原项目的官方版本。本分支中的移植、调试和部分代码修改得到了 OpenAI Codex 的协助。AI 辅助生成的代码可能包含未被发现的问题;在生产服务器上部署前请进行全面测试。用户需自行承担所有兼容性和数据风险。
✨ 特性
- ✅ 适配 Paper 1.21.1、Java 21 及现代 Gradle 构建系统
- ✅ 声明支持 Folia 调度环境
- ✅ 通过 JitPack 集成,使用 Shadow JAR 打包 Nestalgia 模拟器核心
- ✅ Plasmo Voice 空间音频 – 实时将 NES 48 kHz 游戏音频编码为 Opus 并流式传输给附近玩家
- ✅ 修复了 Plasmo Voice 音频卡顿、PCM 帧故障、缓冲延迟、重连问题及资源清理问题
- ✅ 在 Plasmo Voice 中使用
icon.png 作为 BNes 语音源图标
- ✅ 修复了远程玩家和独立服务器的缺失游戏图像问题;地图数据包主要通过 PacketEvents 发送,备选方案包括 ProtocolLib 和原生 Paper/NMS,并为迟到的观察者提供完整的首帧同步
- ✅ GitHub Actions 自动构建;在 GitHub Release 时上传插件 JAR,当发布说明为空时自动生成变更日志
? 依赖要求
| 依赖项 |
详情 |
| Java |
21 |
| 服务端 |
Paper 1.21.1 或兼容服务端 |
| Plasmo Voice |
服务端插件 + 客户端模组(音频必需) |
| PacketEvents |
可选但推荐 – 首选的地图数据包后端 |
| ProtocolLib |
可选 – 备用后端 |
| Vault |
可选 – 仅在经济功能需要时使用 |
| Chair plugin |
推荐 – 也可使用矿车作为替代 |
? 安装与使用
- 从 Releases 页面下载 JAR 文件。
- 将其放入服务器的
plugins 文件夹中。
- 启动服务器一次,然后将你有权使用的 NES ROM 文件放入
plugins/BNes-Fork/roms。
- 使用
/bnes create <实例名称> 创建控制台(在末尾添加 min 可创建单地图版本)。
- 将生成的地图放置在墙上。坐在椅子上并对地图右键点击即可加入游戏。
- 最多支持两名玩家同时游玩。要听到游戏音频,服务器和客户端都必须正确安装并连接 Plasmo Voice。
该插件还会生成 non_card.nes 作为默认画面,用于新控制台未插入卡带或 ROM 无效的情况。
从原版 BNes 升级
如果要从原版 BNes 升级,请先关闭服务器,然后将原版的 plugins/BNes 数据目录重命名或移动至 plugins/BNes-Fork。否则,新插件将会创建一个全新的空配置。
⌨️ 命令与权限
| 命令 |
描述 |
权限 |
/bnes |
显示可用帮助信息 |
– |
/bnes reload |
重新加载并规范化配置文件与语言文件 |
bnes.command.reload |
/bnes create <name> [min] |
创建一个控制台实例 |
bnes.command.create |
/bnes map <name> [player] |
获取指定控制台的地图视图 |
bnes.command.map |
/bnes close <name> |
关闭一个控制台实例 |
bnes.command.close |
/bnes showfps |
切换 FPS 显示状态 |
bnes.command.showfps |
/bnes rename <name> <new_name> |
重命名一个实例 |
bnes.command.rename |
/bnes card <URL/filename> |
加载本地卡带或下载 iNES ROM 格式游戏 |
bnes.command.card |
/bnes menu [page] |
打开卡带菜单 |
bnes.command.menu |
/bnes saves [page] |
管理个人存档(左键点击以物品形式下载,右键点击删除) |
– |
/bnes speed [percentage] |
查看或修改 Nestalgia 模拟器运行速度 |
– |
? 默认按键绑定
| Minecraft 操作 |
NES 按键 |
| 移动键 |
方向键 |
| 跳跃 |
A |
| 切换副手物品 |
B |
| 左键点击地图 |
Select |
| 右键点击地图 |
Start |
| 同时按下 Start + A |
重置游戏 |
| 同时按下 Select + A |
写入个人存档文件 |
按键绑定可在插件配置文件中修改。
? 许可证
本项目继续使用与原始仓库相同的 GPL-3.0 许可证。详情请参阅 LICENSE 文件。
? 鸣谢
感谢原作者 BNes、Nestalgia 项目以及所有相关依赖项的维护者所付出的宝贵工作。
BNes Fork
A map-based NES emulator plugin for Minecraft servers. This fork continues maintenance of MoeWhite19/BNes and uses Nestalgia as the emulation core.
This is a community-maintained fork, not an official release of the original project. Porting, debugging, and some code modifications in this fork were assisted by OpenAI Codex. AI-assisted code may contain undiscovered issues; please test thoroughly before deploying on production servers. Users assume all compatibility and data risks.
✨ Features
- ✅ Adapted for Paper 1.21.1, Java 21, and modern Gradle builds
- ✅ Declared support for Folia scheduling environment
- ✅ Integrated via JitPack with Shadow JAR packaging for Nestalgia emulator core
- ✅ Plasmo Voice spatial audio – encodes NES 48 kHz game audio in real-time as Opus and streams to nearby players
- ✅ Fixed Plasmo Voice audio stuttering, PCM frame glitches, buffering delays, reconnection issues, and resource cleanup
- ✅ Uses
icon.png as the BNes voice source icon in Plasmo Voice
- ✅ Fixed missing game image for remote players and standalone servers; map packets sent primarily via PacketEvents, with fallback to ProtocolLib and native Paper/NMS, and full first-frame sync for late-joining observers
- ✅ GitHub Actions automatic builds; uploads plugin JAR on GitHub Release, auto-generates changelog when release notes are empty
? Requirements
| Requirement |
Details |
| Java |
21 |
| Server |
Paper 1.21.1 or compatible |
| Plasmo Voice |
Server plugin + client mod (required for audio) |
| PacketEvents |
Optional but recommended – preferred map packet backend |
| ProtocolLib |
Optional – fallback backend |
| Vault |
Optional – only needed for economy features |
| Chair plugin |
Recommended – can also use minecarts as alternative |
? Installation & Usage
- Download the JAR from the Releases page.
- Place it in your server's
plugins folder.
- Start the server once, then place your NES ROMs (that you have rights to use) in
plugins/BNes-Fork/roms.
- Create a console with
/bnes create <instance_name> (add min at the end for a single-map version).
- Place the generated map on a wall. Sit on a chair and right-click the map to join.
- Up to two players can play simultaneously. To hear game audio, both server and client must have Plasmo Voice properly installed and connected.
The plugin also generates non_card.nes as a default screen when a new console has no cartridge or an invalid ROM.
Upgrading from Original BNes
If upgrading from the original BNes, shut down the server first, then rename or move the original plugins/BNes data directory to plugins/BNes-Fork. Otherwise, the new plugin will create a fresh empty configuration.
⌨️ Commands & Permissions
| Command |
Description |
Permission |
/bnes |
Shows available help |
– |
/bnes reload |
Reloads and normalizes config & language files |
bnes.command.reload |
/bnes create <name> [min] |
Creates a console |
bnes.command.create |
/bnes map <name> [player] |
Gets the console map |
bnes.command.map |
/bnes close <name> |
Closes a console |
bnes.command.close |
/bnes showfps |
Toggles FPS display |
bnes.command.showfps |
/bnes rename <name> <new_name> |
Renames an instance |
bnes.command.rename |
/bnes card <URL/filename> |
Gets a local cartridge or downloads an iNES ROM |
bnes.command.card |
/bnes menu [page] |
Opens the cartridge menu |
bnes.command.menu |
/bnes saves [page] |
Manages personal saves (left-click to download as item, right-click to delete) |
– |
/bnes speed [percentage] |
Views or modifies Nestalgia emulation speed |
– |
? Default Key Bindings
| Minecraft Action |
NES Button |
| Movement keys |
Directional pad |
| Jump |
A |
| Swap offhand |
B |
| Left-click map |
Select |
| Right-click map |
Start |
| Start + A simultaneously |
Reset game |
| Select + A simultaneously |
Write to personal save file |
Key bindings can be modified in the plugin configuration file.
? License
This project continues to use the GPL-3.0 license as in the original repository. See the LICENSE file for details.
? Acknowledgements
Thanks to the original BNes author, the Nestalgia project, and all maintainers of related dependencies for their valuable work.
评论 0
登录后参与评分
还没有评论,来抢沙发吧