功能
现已支持 Vault 集成!
SpawnSurance 是 Spawn(出生点)和 Insurance(保险)的组合词。
SpawnSurance 的主要目标是让玩家在死亡并重生后,通常是在远离出生点的地方时,不会丢失物品。
SpawnSurance 的核心功能是在玩家死亡时将玩家的背包内容持久化到数据库中,然后在玩家重生后将这些物品恢复给玩家。
当然,如此美妙的效果不应完全免费,每次后续使用的成本应逐渐增加。
为了持久化背包内容,SpawnSurance 首先检查玩家是否携带了足够数量的可配置物品。默认情况下,SpawnSurance 使用腐肉作为消耗品。
每次后续使用的成本会加速增长。
默认情况下,SpawnSurance 首次使用需支付 1 单位,第二次需支付 2 单位,最高上限为 64 单位。初始费率、额外成本的增幅以及最大成本均可配置。
设置 SpawnSurance 以集成 Vault
最初,SpawnSurance 配置为默认行为,即使用 ROTTEN_FLESH(腐肉)作为支付手段。
要集成 Vault,请使用以下命令:
/spawnsurance set pay-source vault
此外,默认的初始成本为 1,加速度值为 1,最大值为 64,这对于经济系统来说可能过于便宜。
如果您希望最低成本为 1000 “美元”,最高成本为 10000 “美元”,并且每次使用增加 500 “美元”的跳跃幅度,您可以这样配置:
/spawnsurance set minimum 1000
/spawnsurance set maximum 10000
/spawnsurance set acceleration 500
您自然会知道什么最适合您的服务器。
使用 SpawnSurance
使用 SpawnSurance 非常简单。
只需在背包中拥有适当数量的消耗品,然后死亡并重生即可。
这需要名为 spawnsurance.use 的权限,默认值为 true。
SpawnSurance 用户命令
玩家可以发出许多聊天命令。
显示一般帮助
/spawnsurance
/spawnsurance help
这些命令显示插件命令的一般帮助信息。
这些命令不检查权限。
显示玩家当前 SpawnSurance 状态
/spawnsurance check
此命令报告几项内容。
首先,它报告玩家是否没有使用 spawnsurance 的必要权限。
其次,它报告玩家是否有足够的消耗品数量来使用 spawnsurance。
第三,它报告当前激活 spawnsurance 所需的消耗品数量。
此命令需要 spawnsurance.use 权限,默认值为 true。
此命令无法在控制台使用,因为没有当前玩家。
获取当前玩家的索赔次数
/spawnsurance get claims
此命令检索玩家的索赔次数(即 SpawnSurance 的使用次数)。
SpawnSurance 的成本计算公式为:(最低成本) + (加速度) * (索赔次数),但结果会被限制在最大值和最小值之间(按此顺序进行钳制)。
此命令需要 spawnsurance.use 权限,默认值为 true。
此命令无法在控制台使用,因为没有当前玩家。
SpawnSurance 管理命令
SpawnSurance 的所有管理功能都归入“get”命令和“set”命令,它们用于检索或设置 SpawnSurance 的各种配置详情。
此外,使用以下两个命令中的任何一个:
/spawnsurance get
/spawnsurance set
将提供有关可用于 get 或 set 的属性帮助。
这些命令不检查权限。
“Get”命令
/spawnsurance get material
此命令检索当前用作 SpawnSurance 消耗品的材质。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
/spawnsurance get minimum
此命令检索 SpawnSurance 的最低成本。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
/spawnsurance get maximum
此命令检索 SpawnSurance 的最高成本。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
/spawnsurance get acceleration
此命令检索 SpawnSurance 的加速度。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
/spawnsurance get claims (playername)
此命令检索特定玩家的索赔次数。
此命令需要 spawnsurance.admin.claims 权限,默认值为 op。
/spawnsurance get pay-source
此命令检索当前的支付来源。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
/spawnsurance get message-enabled
此命令检索 spawnsurance 消息的当前启用状态。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
/spawnsurance get message-text
此命令检索 spawnsurance 消息的当前文本内容。
此命令需要 spawnsurance.admin.configuration 权限,默认值为 op。
“Set”命令
/spawnsurance set material (MATERIAL_NAME)
此命令将设置 SpawnSurance 的消耗物品材质。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
/spawnsurance set minimum (amount)
此命令将设置 SpawnSurance 的最小费用。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
/spawnsurance set maximum (amount)
此命令将设置 SpawnSurance 的最大费用。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
/spawnsurance set acceleration (amount)
此命令将设置 SpawnSurance 的加速费用。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
/spawnsurance set claims (playername) (amount)
此命令将设置玩家的领地数量。
此命令需要权限 spawnsurance.admin.claims,默认授予 op(管理员)。
/spawnsurance set pay-source (default|vault)
此命令将设置当前的支付来源。有效值为 default 和 vault。任何其他值将被解释为 default。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
/spawnsurance set message-enabled (true|false)
此命令将设置 spawnsurance 消息的启用状态。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
/spawnsurance set message-text (message text)
此命令将设置 spawnsurance 消息的文本内容。
此命令需要权限 spawnsurance.admin.configuration,默认授予 op(管理员)。
Features
Now with integration into Vault!
SpawnSurance is a portmanteau of Spawn and Insurance.
The chief goal of SpawnSurance is to allow a player to not lose his stuff when he dies and respawns, often far away from his spawn point.
The primary function of SpawnSurance is to persist a player's inventory into a database when a player dies, and then to restore that inventory to the player upon respawn.
Naturally, such a wonderful effect should not be completely free, and each subsequent use should cost a little more each time.
In order to persist inventory, SpawnSurance first checks to see if the player is carrying the correct amount of the configurable item. By default, SpawnSurance uses rotten flesh as the cost item.
The cost of each subsequent use accelerates.
By default, SpawnSurance first costs 1 unit, then the next time 2 units, and caps out at 64 units. The initial rate, the rate of additional cost, and the maximum cost are all configurable.
Setting Up SpawnSurance for Vault Integration
Initially, SpawnSurance is configured for the default behavior, which is to use ROTTEN_FLESH as the payment.
To integrate with vault, use the command:
/spawnsurance set pay-source vault
Also, the default initial cost is 1, with an acceleration value of 1, and a maximum value of 64, which is likely a bit too cheap for use with an economy.
If you wanted to have a minimum cost of 1000 "dollars" and a maximum cost of 10000 "dollars" with a jump of 500 "dollars" for each use, you would configure like so:
/spawnsurance set minimum 1000
/spawnsurance set maximum 10000
/spawnsurance set acceleration 500
You will naturally know what is best for your server.
Using SpawnSurance
Using SpawnSurance is very simple.
Just die with the appropriate number of the cost item in the inventory, then respawn.
This requires a permission named spawnsurance.use, which defaults to true.
SpawnSurance User Commands
There are a number of chat commands that may be issued by a player.
Showing General Help
/spawnsurance
/spawnsurance help
These commands show general help for the commands of the plugin.
These commands do not check permissions.
Showing The Current Status of the Player's SpawnSurance
/spawnsurance check
This command reports several things.
First, it reports if the player does not have the necessary permission to use spawnsurance.
Second, it reports whether or not the player has sufficient number of cost items to make use of spawnsurance.
Third, it reports the number of cost items currently necessary to activate spawnsurance.
This command requires the permission spawnsurance.use, which defaults to true.
This command will not work on the console, as there is no current player.
Retrieving the Current Player's Number of Claims
/spawnsurance get claims
This command retrieves the number of claims (times that SpawnSurance has been used) by the player.
The cost of SpawnSurance is (Minimum Cost) + (Accleration) * (Number of Claims), but clamped to be no greater than the maximum, but no less than the minimum, in that order.
This command requires the permission spawnsurance.use, which defaults to true.
This command will not work on the console, as there is no current player.
SpawnSurance Administration Commands
All of the functionality of administration commands for SpawnSurance fall into the "get" command and the "set" command, and they retrieve or set the various configuration details of SpawnSurance
In addition, using either of the two commands:
/spawnsurance get
/spawnsurance set
Will give help with the properties that can be used with either get or set.
These commands do not check permissions.
The "Get" Commands
/spawnsurance get material
This command retrieves the material currently used as a cost item for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance get minimum
This command retrieves the minimum cost for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance get maximum
This command retrieves the maximum cost for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance get acceleration
This command retrieves the acceleration for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance get claims (playername)
This command retrieves the number of claims for a particular player
This command requires the permission spawnsurance.admin.claims, which defaults to op.
/spawnsurance get pay-source
This command retrieves the current pay source
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance get message-enabled
This command retrieves the current enabled state of the spawnsurance message.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance get message-text
This command retrieves the current message text of the spawnsurance message.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
The "Set" Commands
/spawnsurance set material (MATERIAL_NAME)
This command will set the material for the cost item for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance set minimum (amount)
This command will set the minimum cost for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance set maximum (amount)
This command will set the maximum cost for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance set acceleration (amount)
This command will set the acceleration cost for SpawnSurance.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance set claims (playername) (amount)
This command will set the number of claims for a player.
This command requires the permission spawnsurance.admin.claims, which defaults to op.
/spawnsurance set pay-source (default|vault)
This command will set the current pay source. Valid values are default and vault. Any other value will be interpreted as default.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance set message-enabled (true|false)
This command will set the current enabled state of the spawnsurance message.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
/spawnsurance set message-text (message text)
This command will set the current message text of the spawnsurance message.
This command requires the permission spawnsurance.admin.configuration, which defaults to op.
评论 0
登录后参与评分
还没有评论,来抢沙发吧