Monetary Death Penalty
Fear death as MonetaryDeathPenalty will remove currency from a player's account when they die. This is a great way to help balance a server's economy.
Description
This is the MonetaryDeathPenalty plugin you can add to your server to monetary penalise players that die. It is currently v2.23 and was designed for v.1.6.4, v1.7.2, v1.7.9 and v1.8.1. It requires Vault. MonetaryDeathPenalty also supports most permissions and most currency plugins. You can add regions to the worldguardBlacklist in the config.yml to disable any money loss within those regions.
I will continue to support this and add many more features. If you have any suggestions please let me know in the comments or through a pm.
Installation and configuration
Place the MonetaryDeathPenalty.jar into your plugins directory and then run the server.
Commands
- /mdp - Current version of MonetaryDeathPenalty running.
- /mdp reload - Reloads the config for MonetaryDeathPenalty.
- /mdp set prefix <string> - Set the prefix for MonetaryDeathPenalty.
- /mdp set pvppay <integer> - Set the pvppay for MonetaryDeathPenalty.
- /mdp set usepercentage <boolean> - Set the usepercentage for MonetaryDeathPenalty.
- /mdp set flatpercentage <integer> - Set the flatpercentage MonetaryDeathPenalty.
- /mdp set flatamount <integer> - Set the flatamount MonetaryDeathPenalty.
- /mdp set vipflatpercentage <integer> - Set the vipflatpercentage MonetaryDeathPenalty.
- /mdp set vipflatamount <integer> - Set the vipflatamount MonetaryDeathPenalty.
- /mdp set minamountforpenalty <integer> - Set the minamountforpenalty MonetaryDeathPenalty.
- /mdp set flatamountbelowminamount <integer> - Set the flatamountbelowminamount MonetaryDeathPenalty.
- /mdp set maxpercentagecap <integer> - Set the maxpercentagecap MonetaryDeathPenalty.
- /mdp set currencysymbol <symbolr> - Set the currencysymbol MonetaryDeathPenalty.
Config
Click here for help with the config.yml
- checkForUpdates - MonetaryDeathPenalty will check for updates. Set to false to disable this./
- prefix - Display a prefix before the MonetaryDeathPenalty message. To disable type prefix: ''
- pvpPay: 150 - Allow players who kill another player to earn a flat amount of currency (pvpCost must be set to true). To disable type pvpPay: 0.
- usePercentage: true - If true will use the flatPercentage to calculate the amount that is lost upon death.
- flatPercentage: 10 - Will remove this percentage of the players current money upon death.
- flatAmount: 500 - Will remove this amount of money from the player upon death. Set usePercentage to false if you wish to use this.
- vipFlatPercentage: 5 - Will remove the specified percentage of the total players money upon death.
- vipFlatAmount: 250 - Will remove a set value rather than a percentage of the players money. Set usePercentage to false if you wish to use this.
- minAmountForPenalty: 1000 - If a player has less than or equal to this amount no currency will be deducted when they die.
- flatAmountBelowMinAmount: 100 - If a player has less than or equal to minAmountForPenalty then the value from flatAmountBelowMinAmount will be deducted from a player when they die. To disable type flatAmountBelowMinAmount: 0
- maxPercentageCap: 5000 - Will cap the max amount of currency that can be removed from the usePercentage.
- currencySymbol: $ - Will output currencySymbolX in the money lost message upon death.
- customMessage: '&6You have died at {0} &6and due to dying you have lost &a{1}&9{2}&6.' - Will show a custom death message upon death. Click here for help with the config.yml.
- customMessageForKiller: '&6You have earned &a{1}&9{4} &6for killing &d{3}&6.' - Will show a custom message when the player kills another player. Click here for help with the config.yml.
- worlds: - world - world_nether - Worlds listed here will prevent players losing money through MonetaryDeathPenalty.
- worldGuardBlackList: - region_name_here - Regions listed here will cause MonetaryDeathPenalty to have no affect on the players currency.
Permissions
- mdp.ignore
description: Player cannot be penalised by MonetaryDeathPenalty upon death. Give Ops - -mdp.ignore permission node to allow MonetaryDeathPenalty to affect their cash. They will still need the - -mdp.vip permission node if you want Ops to be fully affected by MonetaryDeathPenalty.
- mdp.vip
description: Player/group is marked as Vip and penalised using the value from vipFlatPercentage or vipFlatAmount. Give Ops - -mdp.vip permission node to allow MonetaryDeathPenalty to fully affect their cash.
- mdp.admin
description: Player/group is granted admin permissions
default: op
- mdp.reload
description: Reload the config for MonetaryDeathPenalty.
default: op
Changelog
Click here for the full Changelog
Metrics
As of v2.0 this plugin sends statistics about the usage to the server http://mcstats.org/. You can disable it by setting "opt-out" to true in \plugins\PluginMetrics\config.yml.
Auto-checking for updates
As of v2.0 this plugin will check for updates using Curse's ServerMods API. It always checks the current version with the version on BukkitDev and will notify ops or any players/groups with the mdp.admin permission that there is an update available. It will never automatically download an update without the user typing /mdp update. All of the updates are downloaded from BukkitDev. These checks can be disabled in the config.yml by setting checkForUpdates to false.
Donate
As people have requested a donation button to help support the development of MonetaryDeathPenalty I've decided to add one. Thanks to the current and future donations I really appreciate it.
@Six_shooter87
In your permissions config add a user then give them the specific permission node; - -mdp.ignore and - -mdp.vip both of those permission nodes will allow that op to receive the full affect of MonetaryDeathPenalty.
If you are unsure on how to add those. Below is what it would be for me using PermissionsEx.
can you make an option in the config to enable the money-loss for Ops? because as it seems, ops are not affected right now...it seems a tad unfair for the rest of the players :)
Just uploaded v1.7. Be sure to update to that if you are using the WorldGuard Blacklist feature as it fixes a major bug. If you aren't using that feature then there is no need to update.
Just uploaded v1.6.5 which fixed a bug with the reload command and implemented a WorldGuard blacklist feature to prevent players from losing any money when within a specified region.
@InsomniaCraft
Cool. I was planning to add a feature like that for WG and eventually MobArena as well.
I also had my plugin developer develop a world guard flag to disable cash loss in specific regions. I can talk to him about posting it for you if you would like. I've disabled cash loss in certain pvp arenas and spawn.
I didnt even realize you added my requested feature for the maximum amount lost, thank you so much! My players are very happy with me, making me very happy with you!
@Kino876
I'll have a look into adding that in the next build.
Can you do not lose money when you are in the MobArena?
@asmit10
Just uploaded a fix for that which will hopefully be available soon. It was an error in my code after doing the clean up in v1.3 but it's fixed in v1.45.
@Supavitax
It seems like the v1.4 update broke the mdp.vip permission node. If a user on my server has the mdp.vip permission node, they don't lose any money and the customMessage doesn't appear. When I remove the permission node for that user, he loses money normally.
Yes, I have put the code into a yaml parser just to make sure I didn't make a mistake, no I don't accidentally have the ignore permission set to that user.
Just uploaded v1.4 which includes the last suggestion for multiple worlds. You can now configure which worlds MonetaryDeathPenalty will affect.
Thanks for all of the suggestions. I've included them all except the multiverse/multiworld as I will need more time to look in on how to implement that.
I've just uploaded v1.3 which is a big improvement over the previous versions. Please make sure you read the config as some things have changed and if you have any problems just let me know and I'll help.
Edit: v1.3 is now available to download.
Hi Supavitax,
This plugin is GREAT! Makes the players more focus on surviving. I would like to suggest three more features:
Please keep up the good works! Many thanks!
@Supavitax
Yes make it so they take money from the player when they are killed. <3
@RustyDagger
I'll look into adding something like that to allow the players to earn the money when pvpCost is enabled.
Thanks for the report I'll sort that out.
Ok I will change that so it can support colours as well. All of these will be sorted for the v1.0 release which should be in a few days.
Some way to give some amount to the player that did the killing might be handing for causing wide spread killing. could be a flat fee I think a % would be over kill and unused.
Edit bug report.
Negating the ignore permission still does not allow Op's to have to pay they seem top bypass no matter what I tried mdp.ignore too
one more thing it would be alot more useful if the currency name was not included with the value. as it stands i cant color all the text one color and the numbers another. so how about leaving the text to the config and not hard coding it in like that.
@InsomniaCraft
Thanks that's a great suggestion. Added that in the next build and should be available soon once its been approved. Can be found in the config of 0.7 as maxPercentageCap: 10000
Edit: v0.7 is now available
I love this idea, it could potentially stabilize my economy by creating a good gold sink. I do have a request for the next version though. Can you add a capped amount when using percentages? Say I set it to 10% but the user has millions, I don't want them to lose more than 10,000 or so etc.
Awesome, thank you very much, more than a year looking for a plugin like this one.