? ChestTrade
ChestTrade 是一款轻量级、由玩家驱动的 Paper 服务器商店插件。玩家将箱子或桶变成交易商店,其他玩家可以在此进行物品交换。无需经济插件或游戏内货币,仅支持物品对物品的交易。
OP(管理员)可以打开和破坏任何商店,因此管理员可以在无需额外配置的情况下掌控市场。
? 开发中。 请预期会有频繁的变更和更新。
✨ 特性
- ? 支持箱子和桶的商店,可通过命令或告示牌创建
- ? 物品对物品交易,无需经济插件
- ? 受保护的商店:只有所有者(或 OP)才能打开或破坏它们
- ? 交易箱始终保持为单格箱子(防止双格箱子漏洞)
- ? 漏斗无法向商店内/外移动物品,爆炸也无法破坏商店
- ? 交易成功或失败时有声音反馈
- ? 兼容任意权限插件(例如 LuckPerms)
? 依赖
| 依赖项 |
版本 |
备注 |
| Paper |
26.3 |
必需 (api-version: 26.3) |
| Java |
25+ |
必需 |
无需其他插件。如果你希望将 chesttrade.create 权限赋予非 OP 玩家,则需要一个权限插件。
? 安装
- 从 Releases 页面下载最新的
.jar 文件
- 将其放入服务器的
plugins/ 文件夹
- 重启服务器
- 将
chesttrade.create 权限授予能够创建商店的玩家(参见 Permissions)
? 使用方法
创建商店
你需要拥有 chesttrade.create 权限。有两种创建方式:
方法 1:命令
注视一个箱子或桶(距离 5 格以内)并运行:
/ctshop create <cost-item> <cost-amount> <product-item> <product-amount>
- cost 是顾客支付的物品
- product 是顾客获得的物品
示例:顾客支付 1 个钻石并获得 32 个小麦:
/ctshop create diamond 1 wheat 32
物品名称不区分大小写。多词名称请用引号包裹:
/ctshop create "spruce planks" 1 "oak planks" 16
方法 2:告示牌
在箱子或桶正上方放置一个告示牌,并写入以下内容:
| 行号 |
文本 |
| 1 |
[TRADE] |
| 2 |
DIAMOND:1 |
| 3 |
DIRT:16 |
第 2 行是消耗品,第 3 行是商品。告示牌会自动重写以显示交易内容。
补货
所有者(及 OP)可以右键点击商店以像普通容器一样打开它。放入商品物品。顾客的付款也会存储在该容器中,请在此收集。
交易
右键点击商店箱子(或其告示牌)。如果商店有足够的商品,你持有足够的消耗品,且双方背包都有空间,交易将立即完成。
移除商店
所有者(或 OP)需潜行时破坏箱子或告示牌。不潜行直接破坏会被阻止。
箱子放置
交易箱不能变为双格箱子。要在交易箱旁边放置另一个箱子,请在交易箱下方的方块上按住 Shift 右键,或使用桶以增加存储空间。
? 命令
| 命令 |
描述 |
权限 |
/ctshop create <cost-item> <cost-amount> <product-item> <product-amount> |
在你注视的容器上创建交易商店 |
chesttrade.create |
/ctshop info 或 /ctshop help |
显示游戏内帮助 |
无 |
/ctshop info chest |
显示你所注视的商店的所有者、位置、交易内容和库存 |
无 |
/help ctshop 会显示相同的帮助文本。
? 权限
| 权限 |
描述 |
默认值 |
chesttrade.create |
创建商店(通过命令和 [TRADE] 告示牌) |
false |
无论权限设置如何,OP 都可以打开和破坏任何商店。
LuckPerms 示例配置
让 default 组的所有人都能创建商店:
/lp group default permission set chesttrade.create true
⚙️ 兼容性
| 软件 |
状态 |
| Paper |
✅ 支持 (26.3) |
| Purpur |
⚠️ 未测试 (Paper 分支,应该可用) |
| Spigot |
⚠️ 未测试 (应该可用) |
| Bukkit |
⚠️ 未测试 (应该可用) |
| Folia |
❌ 不支持 |
? 从源码构建
需要 Java 25 和 Maven。
git clone https://github.com/wineredbbqsauce/Chest-Trade-plugin.git
cd Chest-Trade-plugin
mvn package
生成的 jar 文件位于 target/ 目录中。
? 问题与建议
发现 bug 或有功能请求?请提交 Issue 并包含:
- 你的服务器软件和版本
- 重现问题的步骤
- 任何相关的控制台错误
? 许可证
本项目采用 MIT License 许可。
? ChestTrade
ChestTrade is a lightweight, player-driven shop plugin for Paper servers. Players turn a chest or barrel into a trade shop where other players can swap one item for another. No economy plugin or in-game currency needed, just item-for-item trading.
OPs can open and break any shop, so admins stay in control of the marketplace without extra setup.
? Under development. Expect frequent changes and updates.
✨ Features
- ? Chest and barrel shops, created with a command or a sign
- ? Item-for-item trading, no economy plugin needed
- ? Protected shops: only the owner (or OP) can open or break them
- ? Trade chests are always kept as single chests (no double-chest exploits)
- ? Hoppers can't move items in or out, and explosions can't destroy shops
- ? Sound feedback on successful and failed trades
- ? Works with any permissions plugin (e.g. LuckPerms)
? Requirements
| Requirement |
Version |
Notes |
| Paper |
26.3 |
Required (api-version: 26.3) |
| Java |
25+ |
Required |
No other plugins are required. A permissions plugin is only needed if you want to give chesttrade.create to non-OP players.
? Installation
- Download the latest
.jar from the Releases page
- Drop it into your server's
plugins/ folder
- Restart the server
- Give
chesttrade.create to the players who should be able to create shops (see Permissions)
? How to Use
Creating a shop
You need the chesttrade.create permission. There are two ways:
Method 1: Command
Look at a chest or barrel (within 5 blocks) and run:
/ctshop create <cost-item> <cost-amount> <product-item> <product-amount>
- cost is what the customer pays
- product is what the customer gets
Example: customers pay 1 diamond and get 32 wheat:
/ctshop create diamond 1 wheat 32
Item names are case-insensitive. Wrap multi-word names in quotes:
/ctshop create "spruce planks" 1 "oak planks" 16
Method 2: Sign
Place a sign directly on top of a chest or barrel and write:
| Line |
Text |
| 1 |
[TRADE] |
| 2 |
DIAMOND:1 |
| 3 |
DIRT:16 |
Line 2 is the cost, line 3 is the product. The sign is rewritten automatically to show the trade.
Stocking the shop
The owner (and OPs) can right-click the shop to open it like a normal container. Put the product items inside. Customer payments are stored in the same container, so collect them there.
Trading
Right-click the shop chest (or its sign). If the shop has enough product, you have enough of the cost item, and both inventories have room, the trade completes instantly.
Removing a shop
The owner (or an OP) breaks the chest or sign while sneaking. Breaking it without sneaking is blocked.
Chest placement
Trade chests can't become double chests. To put another chest next to one, shift+right-click the block below the trade chest, or use a barrel for extra storage.
? Commands
| Command |
Description |
Permission |
/ctshop create <cost-item> <cost-amount> <product-item> <product-amount> |
Create a trade shop on the container you target |
chesttrade.create |
/ctshop info or /ctshop help |
Show in-game help |
none |
/ctshop info chest |
Show owner, location, trade and stock of the shop you're looking at |
none |
/help ctshop shows the same help text.
? Permissions
| Permission |
Description |
Default |
chesttrade.create |
Create shops (command and [TRADE] signs) |
false |
OPs can open and break any shop regardless of permissions.
Example LuckPerms setup
Let everyone in the default group create shops:
/lp group default permission set chesttrade.create true
⚙️ Compatibility
| Software |
Status |
| Paper |
✅ Supported (26.3) |
| Purpur |
⚠️ Untested (Paper fork, should work) |
| Spigot |
⚠️ Untested (Should work) |
| Bukkit |
⚠️ Untested (Should work) |
| Folia |
❌ Not supported |
? Building from source
Requires Java 25 and Maven.
git clone https://github.com/wineredbbqsauce/Chest-Trade-plugin.git
cd Chest-Trade-plugin
mvn package
The jar ends up in target/.
? Issues & Suggestions
Found a bug or have a feature request? Open an Issue and include:
- Your server software and version
- Steps to reproduce the problem
- Any relevant console errors
? License
This project is licensed under the MIT License.
评论 0
登录后参与评分
还没有评论,来抢沙发吧