
简要概览
Wandering Merchants 为你的服务器引入了 RPG 风格的商人。与所有商店都局限于单一市场区域的固定位置不同,这些商人生成并自行在世界中漫游,在野外偶然遇到他们会让服务器世界显得更加生机勃勃。当玩家发现一名商人时,必须向其提供符合其性格特征的物品作为交换,随后该商人将允许玩家与其交互以浏览和购买商品。
Minecraft 版本与服务端软件
最新版本的插件基于 Paper 服务端构建,支持 Minecraft 26.3 至 1.21.9 版本。在其他服务端软件上可能可用也可能不可用。它应该能在 Purpur 和 Pufferfish 等 Paper 分支上运行,尽管尚未对其进行测试。
必需插件
- EconomyShopGUI:
- EconomyShopGUI 还需要一个经济类插件才能正常运行
- Citizens2: 并非所有 Citizens2 构建版本都支持 26.3 至 1.21.9,你必须根据 Minecraft 服务器的版本选择特定的构建版本:
- 26.3, 26.2, 26.1.2, 26.1.1: (latest)
- 1.21.11:
- 1.21.10, 1.21.9:
设置指南
-
确保玩家的权限
economyshopgui.shop和economyshopgui.sellgui.all被设置为 false。这样可以防止玩家通过命令(如/shop)直接进行交易,否则玩家就没有必要特意去找商人购买或出售物品了。 -
确保在 EconomyShopGUI 的配置中将
direct-shop-command-console设置为true。这是因为如果玩家打开商店后可以使用返回按钮回到插件的主菜单,从而访问该商人本不应开放的其它商店。
底层原理
NPC 本身由 Citizens2 创建和控制。对于实际的买卖交易功能,本插件没有重新发明一套新的商店系统,而是让商人使用 EconomyShopGUI(直接接入你的服务器经济系统)来管理商店。这意味着与商人的交易使用你现有的游戏内货币,所有与商店相关的配置均可通过 EconomyShopGUI 的配置文件完成。未获得所需物品的商人会在一段时间后消失。
命令
-
/wm spawn <merchant id> [player]— 在你所在位置或另一名玩家的位置生成一名商人/wm spawn sylphie或/wm spawn sylphie MahinBro
-
/wm give <merchant id> [player]— 将商人的专属物品给予你自己或另一名玩家/wm give sylphie或/wm give sylphie MahinBro
-
/wm recipe <merchant id> [player]— 为你自己或另一名玩家打开商人商品的合成配方 GUI/wm recipe sylphie或/wm recipe sylphie MahinBro
-
/wm get general_config— 查看通用配置的默认设置数据 -
/wm get worlds_config <world name>— 查看特定世界的配置数据/wm get worlds_config world
-
/wm get merchants_config <merchant id>— 查看商人的配置数据/wm get merchants_config sylphie
-
/wm get npc_data <npc id>— 查看本插件设置的 NPC 内部数据/wm get npc_data 3
-
/wm get item_data— 查看你主手所持物品由本插件设置的内部数据 -
/wm set npc_data <npc id> <field> <value|player|NULL>— 设置本插件使用的 NPC 内部数据⚠️ 谨慎使用。 错误地修改商人 NPC 的内部数据可能导致意外问题。仅在你知道自己在做什么时使用此命令。
字段 描述 接受的值 示例 merchant_id配置文件中定义的商人 ID 商人 ID,或 NULL/wm set npc_data 3 merchant_id sylphiemerchant_variant当前商人 NPC 的状态 stray,stray_moving,shopkeeper,shopkeeper_moving,或NULL/wm set npc_data 3 merchant_variant shopkeepermerchant_viewers当前正在查看此 NPC GUI 的玩家数量。仅适用于流浪者变体 整数,或 NULL/wm set npc_data 3 merchant_viewers 0creation_time此 NPC 生成的时间戳 长整型整数,或 NULL/wm set npc_data 3 creation_time 1745000000000following此 NPC 当前跟随的玩家 在线玩家名称,或 NULL表示停止跟随/wm set npc_data 3 following MahinBro使用
NULL作为值可清除该字段。 -
/wm set item_data id <value|NULL>— 设置你主手所持物品的商人物品 ID/wm set item_data id sylphie_scroll
⚠️ 谨慎使用。 即使对泥土设置物品 ID,也可能导致商人接受该物品;或者对真正的商人物品设置错误的物品 ID,会导致商人拒绝接受。仅在你知道自己在做什么时使用此命令。
-
/wm set item_data cmd <value|NULL>— 设置你主手所持物品的自定义模型数据/wm set item_data cmd sylphie_grimoire
⚠️ 谨慎使用。 修改物品的自定义模型数据可能会导致其显示不同的纹理。仅在你知道自己在做什么时使用此命令。
权限
| 权限 | 描述 | 默认拥有者 |
|---|---|---|
wanderingmerchants.wm |
允许使用 /wm 命令 | 仅限操作员 |
多世界支持
你可以拥有多个世界,商人可以在这些世界中生成。你可以自定义哪些商人在哪些世界中生成,以及商人的生成频率。你还可以自定义商人在某个世界中生成的最低频率。下界和末地不受支持,仅支持主世界。阅读插件的默认配置文件以获取更多信息。
可选插件
- LuckPerms: (你可以使用任何你喜欢的权限管理插件)
- Vault 2.0: (你可以使用任何你喜欢的经济插件)
支持
如需支持或提问,请加入我的 Discord 服务器:
许可证
根据 Apache License 2.0 许可
其他项目
查看我在 上制作的其他有趣内容
备注
如果有人在意的话,游戏画面中使用的世界种子是 3353863628485365188(版本 26.3)。?

Brief Overview
Wandering Merchants brings RPG-style merchants to your server. Instead of every shop being in a fixed location like being confined to a single market area, these merchants spawn and roam the world on their own, and stumbling across one out in the wild make the server feel more alive. When a player finds a merchant, the player must give it an item specific to its personality and in return the merchant will allow the player to interact with it to browse and buy items.
Minecraft Version And Server Software
The latest version plugin was built for Minecraft versions between 26.3 and 1.21.9 running on Paper. It may or may not work on other server software. It should work on forks of Paper such as Purpur and Pufferfish, though it has not been tested on them.
Required Plugins
- EconomyShopGUI:
- EconomyShopGUI also requires an economy plugin to function properly
- Citizens2: Not all Citizens2 builds support 26.3 to 1.21.9, you must choose a specific build based on your Minecraft server's version:
- 26.3, 26.2, 26.1.2, 26.1.1: (latest)
- 1.21.11:
- 1.21.10, 1.21.9:
Setup Guide
-
Make sure that players have the permissions 'economyshopgui.shop' and 'economyshopgui.sellgui.all' set to false. This makes it so that players can make transactions through the merchants only otherwise why would players even bother to go to a merchant to buy or sell items when they can just do so using commands like
/shop. -
Make sure to set 'direct-shop-command-console' to 'true' in the EconomyShopGUI's config. This is because if a player were to open a shop, the player could just use the back button to go the main menu of the plugin and access all the other shops that the merchant was not supposed to give access to.
Under The Hood
The NPCs themselves are created and controlled through Citizens2. For the actual trading functionality of buying and selling, instead of reinventing a new shop system, the merchants use EconomyShopGUI (which directly plugs into your server's economy) for their shops mean transactions with the merchants uses your existing in-game currency meaning all shop related configuration can be done through EconomyShopGUI's config. Merchants that have not been given their desired items will disappear after a certain amount of time.
Commands
-
/wm spawn <merchant id> [player]— Spawn a merchant at your location or at another player's location/wm spawn sylphieor/wm spawn sylphie MahinBro
-
/wm give <merchant id> [player]— Give a merchant's item to yourself or another player/wm give sylphieor/wm give sylphie MahinBro
-
/wm recipe <merchant id> [player]— Open a merchant item's crafting recipe GUI for yourself or another player/wm recipe sylphieor/wm recipe sylphie MahinBro
-
/wm get general_config— View the config data general settings -
/wm get worlds_config <world name>— View the config data for a specific world/wm get worlds_config world
-
/wm get merchants_config <merchant id>— View the config data of a merchant/wm get merchants_config sylphie
-
/wm get npc_data <npc id>— View the internal data of a merchant NPC set by this plugin/wm get npc_data 3
-
/wm get item_data— View the internal data of the item in your main hand set by this plugin -
/wm set npc_data <npc id> <field> <value|player|NULL>— Set the internal data in NPCs used by this plugin⚠️ Use with caution. Incorrectly modifying internal data of a merchant NPC can lead to unexpected issues. Only use this command if you know what you are doing.
Fields Description Accepted Values Example merchant_idThe ID of a merchant defined in the config A merchant ID, or NULL/wm set npc_data 3 merchant_id sylphiemerchant_variantThe current state of the merchant NPC stray,stray_moving,shopkeeper,shopkeeper_moving, orNULL/wm set npc_data 3 merchant_variant shopkeepermerchant_viewersThe number of players currently viewing this NPC's GUI. Only for stray variants An integer, or NULL/wm set npc_data 3 merchant_viewers 0creation_timeThe timestamp of when this NPC was spawned A long integer, or NULL/wm set npc_data 3 creation_time 1745000000000followingThe player this NPC is currently following An online player's name, or NULLto stop following/wm set npc_data 3 following MahinBroUse
NULLas the value to clear the field. -
/wm set item_data id <value|NULL>— Set the merchant item ID for the item in your main hand/wm set item_data id sylphie_scroll
⚠️ Use with caution. Setting an item ID on even dirt can cause it to be accepted by a merchant, or setting an incorrect item ID on an actual merchant item can cause it to not be accepted by the merchant. Only use this command if you know what you are doing.
-
/wm set item_data cmd <value|NULL>— Set the custom model data of the item in your main hand/wm set item_data cmd sylphie_grimoire
⚠️ Use with caution. Modifying the custom model data of an item may cause it to display a different texture. Only use this command if you know what you are doing.
Permissions
| Permission | Description | Who has it by default |
|---|---|---|
wanderingmerchants.wm |
Allows the use of /wm command | Operators only |
Multi-World Support
You can have multiple worlds in which merchants can spawn in. You can customize which merchants can spawn in which worlds and how frequently should merchants spawn in a world. You can also customize how rarely a merchant can spawn in a world. Nether and the end are not supproted, only overworld worlds are supported. Read the default config file of the plugin for more information.
Optional Plugins
- LuckPerms: (you can use any permission manager plugin you like)
- Vault 2.0: (you can use any economy plugin you like)
Support
For support or questions, join my discord server:
License
Licensed under the Apache License 2.0
Other Projects
Check out other cool stuff I made at
Side Note
The world seed used in the gameplay images is 3353863628485365188 in version 26.3 if anyone cares ?.
下载 Wandering Merchants
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Wandering Merchants
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Wandering Merchants
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Wandering Merchants
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Wandering Merchants
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Wandering Merchants
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Wandering Merchants
下载 Wandering Merchants
下载 Wandering Merchants
下载 Wandering Merchants
此版本包含以下更改:
- 为跟随玩家的商人添加了卡住/迷路系统。当商人在导航过程中卡住时:
- 如果仍在配置的“迷路距离”内,它会向玩家发送一条卡住消息
- 如果距离过远或处于不同维度,它将停止跟随玩家,并向玩家发送一条独特的消息
- 在服务器关闭前正在跟随玩家的商人,现在会在下次启动时正确停止跟随并恢复到之前的状态
- 为每个商人新增了配置字段
lost_distance、stuck_dialogue、non_shopkeeper_lost_dialogue和shopkeeper_lost_dialogue(请阅读默认配置文件中的注释以获取更多信息) - 正在跟随玩家的商人将在该玩家断开连接时停止跟随
- 将配置字段
default_dialogue重命名为interaction_dialogue
此版本的更改包括:
- 为每个世界增加了更多的配置支持(请阅读配置文件以获取更多信息)
- 配置文件不会自动迁移,你的旧配置文件将被保存为
old_config.yml,并使用本版本的新配置文件
此版本包含以下更改:
- 添加了
/wm命令。请参阅 README 以获取其使用指南。 - 更新了配置文件,并新增了
no_permission_message(无权限消息)。 - 流浪商人现在支持 26.3 至 1.21.9 之间的所有 Minecraft 版本。
- 当有新更新时,会在玩家加入服务器后向服务器操作员发送更新提醒。
- 弃用了对 1.1.3 及更早版本中使用的旧格式的支持。由于
/wm命令提供了大量功能,您可以使用该命令手动将其迁移到最新格式。
如果您是从 1.1.3 版本进行更新,请先更新至 1.1.5 以迁移商人 NPC 系统和商人物品,然后再更新至 1.1.6 版本。
仅对插件更新通知器进行了小幅调整。之前忘记断开与 GitHub 的更新请求,现已修复。
此版本仍保留对旧格式的支持。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
插件
重新定义服务器上的生物运输方式。使用高度可定制的口袋道具,安全地捕获、存储和释放任何实体。
插件
用于绘制游戏内地图或在浏览器中随探索实时进行地图绘制的实时地图。
插件
一个高度兼容、功能完善且稳定的 TPA 模组
插件
在 Minecraft 中加入“最后一击”、“第二次机会”和“最后喘息”机制!从高处坠落时,你将拥有 0.5 HP 而不是直接死亡;当生命值较低时,增强你的能力。
插件
更快速的直线轨道矿车、链式连接列车、熔炉机车,以及原版红石信号!
插件
城镇现在可以要求建造具有特定功能的建筑
评论 0
登录后参与评分
还没有评论,来抢沙发吧