NegiLib
一款适用于 Minecraft 服务器的现代化跨平台 UI 库。
NegiLib 是一款专为 Minecraft 插件开发者设计的强大 UI 框架。它提供统一的 API,用于在 Java 版和基岩版之间创建交互式菜单,并支持 Paper、Purpur、Folia 以及 GeyserMC。
NegiLib 最初作为 EasyMenu v7 的基础开发而成,同时也作为独立库供其他插件使用。
一次构建,支持多种 UI 系统,让 NegiLib 处理渲染工作。
✨ 功能特性
?️ 多种 UI 后端
- Inventory GUI: 兼容旧版 Minecraft 的传统基于箱子的菜单。
- Java Native Dialog: 使用 Minecraft 原生 Dialog API 的现代交互式菜单。
- Bedrock Rich UI: 由基岩版 JSON UI 和资源包驱动的多列自定义菜单。
- 自动回退: 当首选渲染器不可用时,会自动回退到兼容的 UI 后端。
? 丰富的 UI 与自定义选项
- 多列按钮布局。
- 自定义物品图标和纹理。
- 彩色文本、描述和工具提示。
- 可滚动的基岩版菜单。
- 支持不同的屏幕尺寸和输入方式。
- 资源包的生成与管理。
⚡ 对开发者友好的架构
- 跨支持平台的统一 Java API。
- 可扩展的渲染系统,支持自定义渲染器。
- 内置 UI 会话和交互管理。
- 感知平台的调度机制,包括 Folia 兼容性。
- 异步资源准备。
- 自动检测 UI 功能。
- 旨在最大限度地减少特定版本的依赖。
? GeyserMC 集成
NegiLib 通过 GeyserMC 支持基岩版玩家。
NegiLib 不仅限于标准的垂直基岩版表单,还可以使用 JSON UI 显示自定义的网格界面。
Rich UI 功能包括自定义布局、物品图标、工具提示和滚动,并在 Rich UI 不可用时提供支持回退。
无需额外的客户端模组。
? 安装
Paper / Purpur / Folia
- 下载最新的
NegiLib JAR 文件。
- 将其放入服务器的
plugins/ 目录中。
- 重启服务器。
- 安装一个使用 NegiLib 的兼容插件,例如 EasyMenu 7。
如果仅需支持 Java 版,NegiLib 可以在没有 GeyserMC 的情况下运行。
基岩版支持 — Paper 上的 Geyser
如果您的 Paper 兼容服务器上直接安装了 GeyserMC:
- 在服务器上安装 NegiLib。
- 安装 Geyser-Spigot。
- 重启服务器。
- 使用基岩版客户端连接。
此设置不需要 Velocity 配套插件。
基岩版支持 — Velocity 上的 Geyser
如果您的 GeyserMC 运行在 Velocity 代理上,您必须安装单独的 NegiLib Geyser Velocity 配套插件。
Velocity 代理:
- 安装 Geyser-Velocity。
- 将 NegiLib Geyser Velocity 安装到代理的
plugins/ 目录中。
后端服务器(Paper / Purpur / Folia):
- 在每个使用 NegiLib 的后端服务器上安装常规的 NegiLib 插件。
- 根据需要安装 EasyMenu 或其他基于 NegiLib 的插件。
- 重启代理和后端服务器。
重要提示: Velocity 配套插件不能替代常规的 NegiLib 插件。在使用 NegiLib 配合 Geyser-Velocity 时,两个组件都是必需的。
Velocity 配套插件负责处理基岩版 UI 通信和资源包分发,而后端 NegiLib 插件则管理菜单、渲染请求和交互。
?️ 兼容性
- 服务器软件: Paper, Purpur, Folia
- Minecraft Java Edition: 1.20.1+
- 原生对话框 (Native Dialog): 在支持的较新版本 Minecraft 中可用
- 基岩版 (Bedrock Edition): 通过 GeyserMC
- 代理集成: 配合 NegiLib Geyser Velocity 配套插件的 Velocity
- Java: Java 17+ 字节码兼容性;较新的 Minecraft 服务器版本可能需要更新的 Java 运行时环境
与新发布的 Minecraft 版本的兼容性可能需要额外验证。
不支持 Spigot。
?? 给开发者
NegiLib 的设计初衷是使其不仅仅局限于 EasyMenu,具有更高的复用性。
其公开 API 提供了针对 UI 文档、交互元素、渲染器选择、会话管理和玩家交互的抽象。
开发者可以基于 NegiLib 实现自己的菜单系统,而无需关心平台特定的渲染和兼容性细节。
? API 文档
API 参考文档正在准备中。
NegiLib 的公开 API 已可用,但完整的开发者文档、集成指南和代码示例尚未发布。
请密切关注官方 API 参考!
NegiLib —— 一套 UI 框架,多平台支持。
NegiLib
A modern, cross-platform UI library for Minecraft servers.
NegiLib is a powerful UI framework designed for Minecraft plugin developers. It provides a unified API for creating interactive menus across Java Edition and Bedrock Edition, with support for Paper, Purpur, Folia, and GeyserMC.
Originally developed as the foundation of EasyMenu v7, NegiLib is also available as a standalone library for other plugins.
Build once, support multiple UI systems, and let NegiLib handle the rendering.
✨ Features
?️ Multiple UI Backends
- Inventory GUI: Traditional chest-based menus compatible with older Minecraft versions.
- Java Native Dialog: Modern, interactive menus using Minecraft's native Dialog API.
- Bedrock Rich UI: Custom multi-column menus powered by Bedrock JSON UI and resource packs.
- Automatic Fallback: Falls back to compatible UI backends when a preferred renderer is unavailable.
? Rich UI & Customization
- Multi-column button layouts.
- Custom item icons and textures.
- Colored text, descriptions, and tooltips.
- Scrollable Bedrock menus.
- Support for different screen sizes and input methods.
- Resource pack generation and management.
⚡ Developer-Friendly Architecture
- Unified Java API across supported platforms.
- Extensible rendering system with custom renderer support.
- Built-in UI session and interaction management.
- Platform-aware scheduling, including Folia compatibility.
- Asynchronous resource preparation.
- Automatic UI capability detection.
- Designed to minimize version-specific dependencies.
? GeyserMC Integration
NegiLib supports Bedrock Edition players through GeyserMC.
Instead of being limited to standard vertical Bedrock forms, NegiLib can display customized grid-based interfaces using JSON UI.
Rich UI features include custom layouts, item icons, tooltips, and scrolling, with fallback support when Rich UI is unavailable.
No additional client-side mods are required.
? Installation
Paper / Purpur / Folia
- Download the latest
NegiLib JAR.
- Place it in your server's
plugins/ directory.
- Restart the server.
- Install a compatible plugin that uses NegiLib, such as EasyMenu 7.
NegiLib can operate without GeyserMC when only Java Edition support is required.
Bedrock Support — Geyser on Paper
If GeyserMC is installed directly on your Paper-compatible server:
- Install NegiLib on the server.
- Install Geyser-Spigot.
- Restart the server.
- Connect using a Bedrock Edition client.
The Velocity companion plugin is not required for this setup.
Bedrock Support — Geyser on Velocity
If GeyserMC runs on your Velocity proxy, you must install the separate NegiLib Geyser Velocity companion plugin.
Velocity Proxy:
- Install Geyser-Velocity.
- Install NegiLib Geyser Velocity in the proxy's
plugins/ directory.
Backend Servers (Paper / Purpur / Folia):
- Install the regular NegiLib plugin on every backend server that uses NegiLib.
- Install EasyMenu or other NegiLib-based plugins as needed.
- Restart the proxy and backend servers.
Important: The Velocity companion does not replace the regular NegiLib plugin. Both components are required when using NegiLib with Geyser-Velocity.
The Velocity companion handles Bedrock UI communication and resource pack delivery, while the backend NegiLib plugin manages menus, rendering requests, and interactions.
?️ Compatibility
- Server Software: Paper, Purpur, Folia
- Minecraft Java Edition: 1.20.1+
- Native Dialog: Available on supported newer Minecraft versions
- Bedrock Edition: Through GeyserMC
- Proxy Integration: Velocity with the NegiLib Geyser Velocity companion
- Java: Java 17+ bytecode compatibility; newer Minecraft server versions may require a newer Java runtime
Compatibility with newly released Minecraft versions may require additional verification.
Spigot is not supported.
?? For Developers
NegiLib is designed to be reusable beyond EasyMenu.
Its public API provides abstractions for UI documents, interactive elements, renderer selection, session management, and player interactions.
Developers can implement their own menu systems while relying on NegiLib to handle platform-specific rendering and compatibility.
? API Documentation
The API reference is currently being prepared.
NegiLib's public API is available, but the complete developer documentation, integration guides, and code examples are not yet published.
Please stay tuned for the official API reference!
NegiLib — One UI framework. Multiple platforms.
评论 0
登录后参与评分
还没有评论,来抢沙发吧