QSH-OnePrice
简体中文 | English
QSH-OnePrice 是一个 QuickShop-Hikari 的附加插件,引入了 ONEPRICE 销售商店。容器内的所有物品共享一个单价,因此商店可以提供混合库存,而无需为每种物品类型创建单独的商店。
顾客浏览的是真实的容器库存。他们的第一次提取操作会记录确认信息;如果在确认过期前重复相同的提取操作,则通过 QuickShop 的经济系统、税收、事件和库存流程完成购买。
功能
- 从单个容器中出售不同物品,按每件物品统一计价。
- 直接创建商店,或将现有的 QuickShop 销售商店转换为此类商店。
- 支持左键点击、右键点击以及 Shift + 左键点击进行购买。
- 通过可配置的两步确认机制保护顾客的购买行为。
- 默认阻止顾客存入物品,并防止漏斗访问。
- 提供只读的完整容器预览以及专用的聊天面板。
- 根据库存中不同的物品种类轮换显示物品。
- 在商店告示牌上显示总物品数量或占用的槽位数量。
- 包含
en-US、zh-CN 和 zh-TW 翻译。
兼容性
QSH-OnePrice 以 1.21.4 作为其兼容性基线,并在上游 API 保持兼容的情况下允许使用更高版本。
| 组件 |
版本范围 |
状态 |
| Minecraft |
1.21.4 或更高版本 |
1.21.4 已全面测试;更高版本将尽最大努力提供支持。 |
| Server |
Paper 1.21.4 或更高版本 |
主要目标平台。Purpur 等与 Paper 兼容的衍生服务器将尽最大努力提供支持。 |
| Java |
21 或更高版本 |
Java 21 已测试;对于更高版本的发布,请使用服务器所需的 Java 版本。 |
| QuickShop-Hikari |
6.3.0.0 或更高版本 |
6.3.0.0 已全面测试;更高版本将在附带兼容性警告的情况下接受。 |
| Economy |
QuickShop-Hikari 支持的任何可用设置 |
QuickShop-Hikari 必需。 |
低于 Minecraft 1.21.4 或 QuickShop-Hikari 6.3.0.0 的版本将在启动时被拒绝,并显示明确的错误信息。更新的 Minecraft 或 QuickShop 版本将以尽最大努力模式启动。如果上游更新移除了此插件使用的 API 或更改了该 API,启用错误报告将显示已安装的 Minecraft 和 QuickShop 版本,并指出二进制不兼容的问题。
Spigot 不在测试矩阵中,尽管当已安装的 QuickShop 构建支持它时可能可以工作。不支持 Folia,因为此版本使用了标准的 Bukkit 调度程序和线程模型。完整的集成套件目前在 Paper 1.21.4、Java 21 和 QuickShop-Hikari 6.3.0.0 上运行。
安装
- 安装 QuickShop-Hikari 及其所需的经济系统集成,然后验证 QuickShop 是否成功启动。
- 停止服务器。
- 将 QSH-OnePrice JAR 文件复制到服务器的
plugins/ 目录中。
- 启动服务器,并确认日志中包含
Registered QuickShop shop type ONEPRICE。
- 在创建第一个 ONEPRICE 商店之前,请检查
plugins/QSH-OnePrice/config.yml,特别是 shop-type-id 配置项。
请勿从 build/libs/ 安装 integration-tests JAR 文件;它是测试工具,而非生产用插件。
用法
| 命令 |
描述 |
权限 |
/qs oneprice <价格> |
从你正在查看的容器创建一个 ONEPRICE 商店。 |
qshoneprice.command.create |
/qs oneprice |
转换你正在查看的 QuickShop 销售商店。 |
qshoneprice.command.convert |
/oneprice reload |
重新加载配置和翻译文件。 |
qshoneprice.reload |
| /qs oneprice reload | 通过 QuickShop 命令树重新加载。 | qshoneprice.reload |
要购买,请打开商店容器并使用左键点击、右键点击或 Shift + 左键点击选取物品。在启用确认的情况下,请在超时到期前对同一槽位重复相同操作。商店所有者以及拥有库存绕过权限的管理员可以直接维护库存。
ONEPRICE 商店始终是有限售商店。购买模式、无限模式以及外部 QuickShop 购买命令均被有意屏蔽,以确保交易一致性。
配置与权限
完整的选项参考、验证规则、重载行为、本地化说明和权限表可在以下文档中找到:
shop-type-id 会持久化存储在 QuickShop 的数据库中。请在创建商店前选择一个不冲突的值,且此后切勿更改。
构建与测试
# Linux/macOS
./gradlew clean build --no-daemon
./gradlew integrationTest --no-daemon --no-configuration-cache
# Windows
gradlew.bat clean build --no-daemon
gradlew.bat integrationTest --no-daemon --no-configuration-cache
插件 JAR 文件将生成至 build/libs/QSH-OnePrice-1.0.0.jar。集成测试会在首次运行时启动一个真实的 Paper 1.21.4 + QuickShop-Hikari 服务器并下载测试依赖项。
其他文档
许可证
QSH-OnePrice 是自由和开源软件,根据 GNU Affero General Public License v3.0 或更高版本(AGPL-3.0-or-later)授权。此 Copyleft 许可证与 QuickShop-Hikari 发布的 AGPL 许可路径兼容,并确保修改后的版本可供社区使用,包括对通过网络使用的修改软件的源代码可用性要求。
QuickShop-Hikari、Paper、VaultAPI 以及其他构建或测试依赖项均为独立项目,受其各自的许可条款约束。它们不会打包在生产插件 JAR 文件中。详情请参阅 第三方通知。
QSH-OnePrice
简体中文 | English
QSH-OnePrice is a QuickShop-Hikari add-on that introduces a ONEPRICE selling shop. Every item in the container shares one unit price, so a shop can offer mixed stock without creating a separate shop for each item type.
Customers browse the real container inventory. Their first extraction records a confirmation; repeating the same extraction before it expires completes the purchase through QuickShop's economy, tax, event, and inventory flow.
Features
- Sell different items from one container at a single per-item price.
- Create a shop directly or convert an existing QuickShop selling shop.
- Support left-click, right-click, and Shift + left-click purchases.
- Protect customer purchases with configurable two-step confirmation.
- Prevent customer deposits and, by default, hopper access.
- Provide a read-only full-container preview and a dedicated chat panel.
- Rotate the display item through the distinct items in stock.
- Show total item or occupied-slot stock on the shop sign.
- Include
en-US, zh-CN, and zh-TW translations.
Compatibility
QSH-OnePrice uses 1.21.4 as its compatibility baseline and allows newer versions wherever the upstream APIs remain compatible.
| Component |
Version range |
Status |
| Minecraft |
1.21.4 or newer |
1.21.4 is fully tested; newer releases are supported on a best-effort basis. |
| Server |
Paper 1.21.4 or newer |
Primary target. Paper-compatible derivatives such as Purpur are best effort. |
| Java |
21 or newer |
Java 21 is tested; use the Java version required by the server on newer releases. |
| QuickShop-Hikari |
6.3.0.0 or newer |
6.3.0.0 is fully tested; newer releases are accepted with a compatibility warning. |
| Economy |
Any working setup supported by QuickShop-Hikari |
Required by QuickShop-Hikari. |
Versions below Minecraft 1.21.4 or QuickShop-Hikari 6.3.0.0 are rejected during startup with an explicit error. Newer Minecraft or QuickShop versions start in best-effort mode. If an upstream update removes or changes an API used by this plugin, the enable error reports the installed Minecraft and QuickShop versions and identifies the binary incompatibility.
Spigot is not part of the test matrix, although it may work when the installed QuickShop build supports it. Folia is not supported because this release uses the standard Bukkit scheduler and thread model. The full integration suite currently runs on Paper 1.21.4, Java 21, and QuickShop-Hikari 6.3.0.0.
Installation
- Install QuickShop-Hikari and its required economy integration, then verify that QuickShop starts successfully.
- Stop the server.
- Copy the QSH-OnePrice JAR into the server's
plugins/ directory.
- Start the server and confirm that the log contains
Registered QuickShop shop type ONEPRICE.
- Review
plugins/QSH-OnePrice/config.yml, especially shop-type-id, before creating the first ONEPRICE shop.
Do not install the integration-tests JAR from build/libs/; it is a test harness, not a production plugin.
Usage
| Command |
Description |
Permission |
/qs oneprice <price> |
Create an ONEPRICE shop from the container you are looking at. |
qshoneprice.command.create |
/qs oneprice |
Convert the QuickShop selling shop you are looking at. |
qshoneprice.command.convert |
/oneprice reload |
Reload configuration and translations. |
qshoneprice.reload |
/qs oneprice reload |
Reload through the QuickShop command tree. |
qshoneprice.reload |
To buy, open the shop container and take an item with left-click, right-click, or Shift + left-click. With confirmation enabled, repeat the same action on the same slot before the timeout expires. The shop owner and administrators with inventory-bypass permission can maintain stock directly.
ONEPRICE shops are always finite selling shops. Buying mode, unlimited mode, and external QuickShop purchase commands are intentionally blocked to preserve transaction consistency.
Configuration and permissions
The complete option reference, validation rules, reload behavior, localization instructions, and permission table are available in:
shop-type-id is persisted in QuickShop's database. Choose a non-conflicting value before creating shops and never change it afterward.
Build and test
# Linux/macOS
./gradlew clean build --no-daemon
./gradlew integrationTest --no-daemon --no-configuration-cache
# Windows
gradlew.bat clean build --no-daemon
gradlew.bat integrationTest --no-daemon --no-configuration-cache
The plugin JAR is written to build/libs/QSH-OnePrice-1.0.0.jar. The integration test starts a real Paper 1.21.4 + QuickShop-Hikari server and downloads test dependencies on its first run.
Additional documentation
License
QSH-OnePrice is free and open-source software licensed under the GNU Affero General Public License v3.0 or later (AGPL-3.0-or-later). This copyleft license is compatible with the AGPL licensing path published by QuickShop-Hikari and keeps modified versions available to the community, including the source-availability requirements for modified software used over a network.
QuickShop-Hikari, Paper, VaultAPI, and the other build or test dependencies are separate projects under their own licenses and terms. They are not bundled in the production plugin JAR. See third-party notices for details.
评论 0
登录后参与评分
还没有评论,来抢沙发吧