Money and Sign Shops
这是一个可选的客户端模组,添加了非物品形式的货币以及玩家/服务器告示牌商店。
货币
玩家可以通过以下命令查看自己的余额:
/money
还可以进行玩家之间的资金转账。
告示牌商店
共有 4 种类型:
[buy] 从玩家扣除货币并从存储库存中给予物品
[sell] 从玩家物品栏中收取物品,并将货币从店主转移给玩家
[server-buy] 从玩家扣除货币并给予物品(无限库存)
[server-sell] 从玩家收取物品并给予货币(无限库存)
商店存储方块
任何具有容器界面和 ItemHandler 能力的方块都可以用作商店。这包括所有原版容器,如箱子、桶、漏斗、熔炉等,也包括来自模组的存储设备,甚至包括机器。(关于机器的说明:商店将顶部面视为插入和提取面)
激活商店
告示牌的第一行必须是上述 4 种类型之一(只有管理员可以激活服务器商店)。
第二行和第三行可以是任意内容,建议填写描述。
最后一行是价格(允许使用小数,但不要使用千位分隔符或货币符号)。
接下来,在容器中放入商店需要查找的物品。当商店被激活时,容器中的所有物品都将被使用。这允许你将多个物品组合在一起进行交易以换取货币,例如工具包。
设置好告示牌并放好物品后,右键点击告示牌以激活它。如果成功,类型和价格的颜色会发生变化。
查看商店信息
左键点击任意商店即可查看出售内容 (注意:如果你在创造模式下操作,这会破坏告示牌)
聊天中的商店信息会为待售物品提供工具提示,因此像工具和武器这样的物品可以显示它们的附魔信息。
售卖你没有的物品
你是否曾经想要某种稀有物品,一旦拥有就再也不需要了?是否觉得在没有该物品的情况下就无法请求它显得很荒谬?这个模组提供了解决方案。通过使用书与笔,你可以以 JSON 格式写下你想要的精确物品,商店在激活时会读取这本书。关键部分是第一页应以 "vending" 开头,然后在下一行开始你的 JSON。见下文。
商店保护
一旦商店被激活,容器就会受到保护,防止非所有者或非管理员打开和破坏。此外,无法在存储方块相邻的位置放置方块。这是为了防止其他玩家放置漏斗或管道来从你的商店中提取物品。请注意,由于保护仅在商店激活后生效,你可以在商店激活之前设置自己的机器连接到存储方块。这是一种制作自维持商店的方法。
API
此模组提供了一个 API 包,供其他模组进行钩子调用。如果你有关于在自己的模组中实现此功能的疑问,请通过 Discord 或 GitHub(链接如下)联系我。
原版客户端
如果你想纯服务端使用此模组,你需要将此模组的语言文件添加到客户端的资源包中。否则,大多数聊天消息对你的用户来说将不够详细。你可以在此处 获取 语言文件。
兼容模组
Section Protection
2.0 之前版本的详细信息可以在本剧透中找到。
Money Mod 是一个用于为 Minecraft 添加货币和账户的工具模组。
玩家功能:
- 通过 /account 命令快速访问金钱操作
- 通过 /account gui 命令访问账户操作的图形界面
如果你实在不喜欢使用命令,也可以随时使用内置的图形界面。
转账给其他玩家、提取你的钱袋,或将特定数量的钱袋批量存入你的账户。
- 所有面值仅使用一种货币物品,避免不必要的背包杂乱
MoneyBag!
与许多拥有不同面值独立物品的模组不同,Money Mod 只有一种物品,它可以容纳不同的数值。你可以堆叠相同类型的钱袋,或者在任意合成台中将它们合并成一个包含所有面值的组合钱袋。
通过使用 /account withdraw <bag value> <number of bags> 命令获取钱袋
或打开账户图形界面从中提取钱袋。
- 服务器管理员的图形界面
虽然可能计划添加更多功能,但基本功能已在此处可用。
API 可供其他模组直接接入。该模组计划随时间推移不断扩展,以满足依赖模组的需求。
开发者功能:
- 玩家与非玩家账户
玩家账户是该模组中唯一预定义的账户类型,但你可以创建无限多种账户类型供自己使用。
所有账户均使用 UUID 作为所有者标识。
账户类型为 ResourceLocation,因此你可以将路径设置为你想要的任何唯一账户类型,或使用来自其他依赖模组的类型以实现三角依赖关系。
- 集成式与外部数据库支持(开发中)
Money Mod 默认使用集成的 H2 数据库。然而,配置文件允许连接到外部数据库服务。
请注意:某些数据库可能需要添加到后端才能正常工作。如果你正在使用或计划使用当前不受支持的数据库平台,请通过我的 Discord 联系我,以便添加相应的集成支持。
Money and Sign Shops
Is a a client-optional mod that adds non-item money and player/server sign shops.
Money
Players can see how much money they have with:
/money
as well as transfer funds between players
Sign Shops
come in 4 types:
[buy] which takes money from the player and gives them items from the storage stock
[sell] which takes items from the player inventory and transfers money from the shop owner to the player
[server-buy] which takes money from the player and gives them items (infinite stock)
[server-sell] which takes items from the player and gives them money (infinite stock)
Shop Storage Blocks
Any block with an inventory and an itemhandler capability can be used as a shop. this includes all vanilla containers such as chests, barrels, hoppers, furnaces, etc., but also includes modded storage including machines. (A note on Machines: the shop uses the top face as it's insert and extract face)
Activating a Shop
The first line of the shop must be one of the 4 types above (only admins can activate server shops).
The second and third lines can be anything you want. A description is a good idea.
The last line is the price (decimals are acceptable, no thousand operators or currency symbols though)
Next, put the items the shop should look for in the container. All items in the container are used when the shop is activated. This allows you to trade multiple items together for money, such as tool kits
once your sign is set and your items in place, right click the sign to activate it. If successful, the type and price will change color.
Viewing shop info
left click any shop to see what is for sale (Note: if you are in creative mode this will break the sign)
shop info in the chat will give tooltips for the items for sale so items like tools and weapons can show their enchantments
Vending Items You Don't Have
Do you ever want something rare that if you had, you would never need again? Does it seem silly that you can't request that item without having it first? well this mod has a solution. By using a Book and Quill, you can write in the exact item you want in JSON format and the shop will read the book when activating your shop. Key components are the first page should start with "vending" then start your JSON on a new line. see below
Shop Protections
once a shop is activated, the container is protected from opening and destruction by anyone who is not the owner or an admin. Additionally, blocks cannot be placed adjacent to the storage block. This is to prevent other players from placing hoppers or pipes to extract items from your shop. Note that, since the protections only kick in after the shop is activated, you can set up your own machines to connect to the storage block so long as you do so before the shop is activated. This is one way to make self-sustaining shops.
API
This mod has an API Package for hooks by other mods. If you have questions about implementing this with your own mod, please contact me via discord or github(links below).
Vanilla Clients
If you want to use this purely server-side you will want to add this mod's lang file to a resource pack for your clients. Otherwise most chat messages will not be as informative to your users. you can get the lang file HERE.
Compatible Mods
Section Protection
Information on versions pre 2.0 can be found in this spoiler.
Money Mod is a utility for adding money and accounts to Minecraft.
Features for Players:
- Quick access to money actions via /account command
- accessible gui for account actions via /account gui
If commands are just too bukkity for you, you can always use the built in GUI.
Transfer to other players, withdraw your moneybags, or bulk deposit specific bags back into your account.
- One money item for all values to avoid unnecessary inventory clutter
The MoneyBag!
Unlike many mods which have separate items for various money values, Money Mod has one that can hold different values. You can stack bags of the same type, or combine them in any crafting grid to make one combined bag of all their values.
obtain bags by using /account withdraw <bag value> <number of bags>
or open the account Gui and withdraw bags from there.
- Admin Gui for server managers
While more features may be planned, the basic functions are accessible here.
API is accessible for mods to plug into directly. This mod is planned to expand over time to meet the needs of dependent mods.
Features for developers:
- Player and non-player accounts
Player accounts are the only pre-defined account type in the mod, but an infinite number of account types can be created for your use.
All accounts use UUIDs as the owner of an account.
The account type is a ResourceLocation, so set your path to whatever unique account type you want, or use one from another dependent mod for triangulated dependency.
- Integrated and External Database Support (WIP)
Money Mod uses an integrated H2 database by default. However, the config allows for connection to external database services.
PLEASE NOTE: certain databases may need to be added to the back end to work. If you are using, or plan to use, a currently unsupported database platform, please contact me on my discord to have that integration added.
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Money and Sign Shops
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
- 修复了激活时告示牌文本重置的问题。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
一个用于收集生物掉落物的多区块模组。
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
查看物品与配方
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
适用于 MC 1.18+ 的 Effekseer 加载器
模组
那是什么?一个 Waila/Hwyla 的分支。
评论 0
登录后参与评分
还没有评论,来抢沙发吧