McMoney
请为我想想可以往这个模组里添加哪些功能
McMoney 类似于大多数为 Minecraft 制作的经济系统,但我认为它更容易集成到插件中。它包含一些通用命令,例如
/money 和 /pay(这些命令将在本文稍后部分进行解释)。在配置文件中,你可以设置货币名称以及初始资金数额。
如果配置文件中允许,你可以为玩家提供利息。其运作方式与现实生活中的利息相同。默认利率为 2.5%。如果你不了解利息是如何计算的,以下是其工作原理:
A = P(1+R)^T
A = 最终金额
P = 当前金额
R = 利率 / 100
T = 时间
如果你有 $5,287,年利率为 2.5%,经过一年(在插件中相当于每小时视为一年)后,金额将变为:
A = 5,287 * ((1 + .025)^1)
A = 5,419.16
命令:
- /money [玩家] - 显示你或另一名玩家的金钱数量
- /pay <玩家> <金额> - 向玩家转账
- /mcadmin <set | add | remove> <玩家> <金额> - 管理员命令
如何集成到其他插件:
获取插件实例的方式如下:
MoneyAPI money = MoneyAPI.getInstance();
然后使用以下方法:
- addMoney(玩家名称, 金额); - 给予玩家金钱
- removeMoney(玩家名称, 金额); - 从玩家处扣除金钱
- getMoney(玩家名称); - 获取玩家的金钱数量
- setMoney(玩家名称, 金额); - 设置玩家的金钱数量
- hasMoney(玩家名称); - 返回该玩家是否存在
- createPlayerMoney(玩家名称); - 将该名称添加到金钱文件中,并设置初始资金
- getMoneyString(金额); - 获取金钱的字符串表示形式(例如:153.7 duckets)
示例
MoneyAPI money = MoneyAPI.getInstance();
money.addMoney(player.getName(), 100);
这将给玩家增加 100 单位金钱
待办事项:
- 绿色 - 正在开发中
- 红色 - 尚未开始
- 蓝色 - 测试中
McMoney
PLEASE GIVE ME IDEAS FOR THINGS TO ADD TO THIS
McMoney is like most economy systems made for minecraft but I feel is much easier to add to plugins. it has the general commands such as
/money and /pay (will explain the commands later on in this post). In the config you can set the name of the money and the starting amount of money.
You can give people interest if you allow it in the config. It works the same way as real interest works. The default is a 2.5% interest rate. If you don't know anything about interest this is how it works
A = P(1+R)^T
A = New amount
P = Current amount
R = Rate / 100
T = Time
If you have $5,287 with an interest rate of 2.5% after a year (in the plugin it would be every hour as if it was a year) it will be this
A = 5,287 * ((1 + .025)^1)
A = 5,419.16
Commands:
- /money [player] - show the amount of money you or another player has
- /pay <player> <amount> - pay players
- /mcadmin <set | add | remove> <player> <amount> - admin commands
How to add to plugins:
Get the plugin with
MoneyAPI money = MoneyAPI.getInstance();
then use these
- addMoney(player name, amount); - gives the player money
- removeMoney(player name, amount); - removes money from the player
- getMoney(player name); - get amount player has
- setMoney(player name, amount); - sets the amount of money a player has
- hasMoney(player name); - returns if the player exists or not
- createPlayerMoney(player name); - add that name to the money file with the starting amount of money
- getMoneyString(amount); - gets the string of the money (ex. 153.7 duckets)
example
MoneyAPI money = MoneyAPI.getInstance();
money.addMoney(player.getName(), 100);
this will add 100 to the players money
TODO:
- GREEN - Being worked on
- RED - Not yet started
- BLUE - In testing
下载 McMoney
下载 McMoney
下载 McMoney
下载 McMoney
下载 McMoney
下载 McMoney
下载 McMoney
下载 McMoney
V1.2.1
- 新增“登录时余额”功能,玩家下次登录时会显示其盈利或亏损情况
V1.2
- 适配 1.8.8 版本
- 修复了向他人扣款时支付负数金额的问题
V1.1
- 全新界面
- 新增真实感效果
V1.0
- 重制版正式发布
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
插件
Vault2.0 是什么? Vault2.0 是一个经济插件,它注册了一个兼容 Vault API 的 Bukkit Economy 服务,允许其他插件(商店、等级等)使用货币而无需依赖原始的 Vault.jar。它包含菜单、支付/收费流程
插件
一款旨在与 Multiverse-Core 紧密结合的库存管理插件
插件
一个功能丰富、完全动画化的箱子插件,适用于 Paper 1.21.x,支持 IA、Vault、PlaceholderAPI 和 Citizens
插件
一个现代且高度可配置的 Essentials 插件,类似于 EssentialsX
插件
城镇现在可以要求建造具有特定功能的建筑
插件
奖励你的玩家,配送员,冷却时间,100% 可定制,支持 MySQL,多服务器!
评论 0
登录后参与评分
还没有评论,来抢沙发吧