DynamicDifficulty
Description
Are Minecraft’s mobs not challenging enough for you? Do you find that survival lacks the tension it once had because the mobs no longer pose any threat to you? On the other hand, maybe you find some of Minecraft’s mobs too challenging. Perhaps you wish that these mobs were less difficult and overwhelming. If you fall into either of these groups or just want more control over the difficulty of the mobs in general, then DynamicDifficulty may be the plugin you are looking for.
What is dynamic difficulty?
Dynamic difficulty is a system where the difficulty of the videogame scales up or down in the middle of game play to match how well the player is currently performing at the game. In the case of this plugin, DynamicDifficulty scales how tough the mobs are based on its assessment of the player’s capability to fight off the mobs.
Performance Levels
Each player has one “auto performance level” for each type of hostile mob (not including bosses). A player’s auto performance level can range anywhere from 50 to 200 with 100 being the default value. 100 means that the mob is at its normal level of difficulty. 200 means that the mob is twice as tough as normal, and 50 means that the mob is only half as tough.
As a player fights each type of mob, the plugin calculates the player’s auto performance levels based on how much damage a player receives from a type of mob on average and how much damage a player gives to a type of mob on average.
Players also have a “manual performance level” for each mob if they would prefer to set the difficulty manually rather than have the plugin calculate the difficulty for them.
The plugin scales certain attributes of the mobs based on the player’s performance level for that mob. The chart below shows how much the mob attributes scale in relation to some sample performance levels.
| Example Performance Level | 50 | 100 | 200 |
| Attack Damage (% of damage normally dealt) | 50 | 100 | 200 |
| Defense (% of damage normally taken) | 200 | 100 | 50 |
| Speed (% of normal speed) | 75 | 100 | 150 |
| Knockback Resistance (%) | 0 | 0 | 50 |
| Max Follow Distance (% of normal distance) | 100 | 100 | 200 |
| XP (multiply amount of xp normally dropped by this %) | 100 | 100 | 200 |
Loot* (multiply amount of loot normally dropped by this %) | 100 | 100 | 200 |
*Loot scaling does not affect items worn or held by the mob; it only affects standard drops.
Note that this plugin scales the mob's attributes based on the player the mob is currently targeting. This means that this plugin can cater the difficulty to each individual player on the server all simultaneously.
Settings
DynamicDifficulty provides several adjustable settings for each type of mob.
Difficulty Settings
There are three difficulty settings: auto, manual, and disabled.
| Setting | Description |
| auto | The plugin will calculate your auto performance level and use it to scale the mob’s attributes. |
| manual | The plugin will not calculate your auto performance level. It will change the mob’s attributes based on the manual performance level you provide. |
| disabled | The mob’s attributes will not change from their normal values. |
Max Increment
Every 30 seconds, the plugin will update a player’s auto performance level. The max increment setting determines the maximum amount that a player’s auto performance level can change by in a single update. For example, if the player’s max increment is 10 and the player’s current auto performance level is 100 and the plugin determines that the player’s auto performance level should be 150, during the first update, it will change it to 110. Every 30 seconds, the player’s auto performance level will change by 10 units until it reaches 150.
Scale Attributes
Scaling for the following attributes of the mob can be toggled to true or false so that the plugin either will scale them based on the player’s performance level or will not scale them.
- Attack
- Defense
- Speed
- Knockback resistance
- Max follow distance
- XP
- Loot
Commands
DynamicDifficulty features commands to allow players fine-tuned control over the difficulty of the mobs. Commands are listed here: Commands.
Permissions
DynamicDifficulty features permissions to allow or deny players from using certain commands. Permission nodes are listed here: Permissions.
Configuration
Each player has a config file, named <player-uuid>.yml. When the player logs onto the server, the plugin will generate this file if the file does not exist. It will be placed in the "players" folder. The plugin saves a player’s dynamic difficulty settings to their config file when they log out. The next time a player logs onto the server, their data will be loaded back up.
The plugin will also generate a default_player.yml file. Server owners can specify default values for players’ settings using this file. When the plugin goes to generate the player's config file for the first time, it will load the values from default_player.yml.
The default config for default_player.yml is listed here: Configuration.
Source Code
The source code can be viewed here: Source Code.
Important Information
- The descriptions here are for the most current version of DynamicDifficulty. Older versions of the plugin do not have some of the features listed here and some features have changed slightly between updates.
- Each version of DynamicDifficulty is only compatible with the version of Bukkit it is listed with.
- As of DynamicDifficulty v1.3.0, this plugin is compatible with the new UUID system. Previous versions use a player’s name to link them with a yml file. Under old versions, if a player changes their name, they will lose their old yml file and a new one will be generated for their new name.
-
View User Profile
-
Send Message
Posted Jun 23, 2014Does the loot and XP increase / decrease work together with the loot and xp increase / decrease of DynamicDropRate http://dev.bukkit.org/bukkit-plugins/dynamicdroprate/
?
-
View User Profile
-
Send Message
Posted Jun 20, 2014can we raise the performance level past 200 to 1000%? I need people to learn to fear mobs
-
View User Profile
-
Send Message
Posted Jun 16, 2014@Professor_Tee
That's good idea. When I was first working on changing the speed of the mobs, I initially tested having their speed range from x1/2 to x2, but x1/2 was pathetically slow and x2 was ridiculously fast. However, I can see why having a speed even at x1.5 would be a problem when 40+ zombies are swarming you.
-
View User Profile
-
Send Message
Posted Jun 14, 2014i'd like to set a maximum increasement of a stat just for the sake of fun i got trouble with zombies getting way to fast to handle and i'd like to have it work with zombieapocalypse which would make em way to op xD
-
View User Profile
-
Send Message
Posted Jun 12, 2014@siege1313
Thanks mate, I've updated and the problem has stopped
-
View User Profile
-
Send Message
Posted Jun 12, 2014@frol1
I have reproduced the error and know why it is occurring.
This error occurs on Spigot Build #1434 and most likely other early builds of Spigot for 1.7.9-R0.1, but I have not tested this for every early build. I tested DynamicDifficulty v1.3.0 on Spigot Build #1473 (the most recent build for 1.7.9-R0.1), and the plugin works. If you switch to Spigot Build #1473, the error will not occur.
The reason for the error is that Bukkit/Spigot have recently been making several fundamental changes to their code, and instead of removing all of the old code entirely, they are slowly phasing it out. DynamicDifficulty v1.3.0 uses the new code. Early builds of Spigot for 1.7.9-R0.1, such as #1434, still use the old code and thus are not compatible with the new code DynamicDifficulty v1.3.0 uses. At some point, Spigot made the switch to the new code too.
Is updating to a more recent build of Spigot for 1.7.9-R0.1 an option for you? I would prefer that as the solution if possible because I would have to revert the plugin back to the old code to make the plugin work just for that particular build. If that is not an option, I can still do that, but I would prefer to avoid that if possible.
-
View User Profile
-
Send Message
Posted Jun 12, 2014@frol1
I am getting this error when starting the server
-
View User Profile
-
Send Message
Posted Jun 12, 2014@siege1313
Thanks for updating to 1.7.9 dude :D
-
View User Profile
-
Send Message
Posted Jun 1, 2014@closer75
Certainly. I apologize for the wait. I will have an update for 1.7.9 out soon that is compatible with the UUID system, hopefully by the end of the week if all goes according to plan.
I am actually in the middle of updating the plugin with some new features (those primarily being the ability to toggle scaling of specific mob attributes on and off, scaling mob defense, and scaling loot/xp). Once I have everything tested, including the UUID switch, I will post the plugin.
Thank you, everyone, for your patience.
-
View User Profile
-
Send Message
Posted Jun 1, 2014Can this please be updated to 1.7.9 with the new UUID system because it currently does not work right in 1.7.9.
-
View User Profile
-
Send Message
Posted May 21, 2014@pinkeyeZ
I tested DynamicDifficulty v1.2.2 on Bukkit 1.7.2-R0.2, and the difficulty scaling works for me as well as the default_player.yml settings.
I believe I know what the issue is. I take it you launched the server and it generated the default_player.yml file. You then joined the server, and the plugin generated your personal yml file. You then either changed the values in the default_player.yml file or your personal yml file, by hand, while you were still logged into the server. You expected to see all of your settings and numbers be "manual" and 200 and then see the mobs' difficulty be scaled.
At least, this is the only way I could foresee the difficulty not changing, but if this is not what you did, please let me know more specifically what is occurring so that I can help fix the problem you are facing. If this is what you did, here are the issues with it and how to fix it.
The first issue here is that the values from the default_player.yml file only get read when the plugin needs to generate a new .yml file for a player. If your personal .yml file already exists, then the plugin will not copy the values from default_player.yml to your .yml file. So, if you are changing the default_player.yml file after yours already exists, that will not affect your yml file.
The second issue is that if you change the values in your .yml file by hand, those changes do not affect the server until you log on to the serer after the changes are made. The plugin uses your .yml file as a place to save your current settings and performance levels when you log out so that next time you log back in, it can reload them back in. If you are already logged on to the server, use the commands to change your settings and performance levels like this:
/dynamic changesetting all manual
/dynamic changelevel all 200
While in game you should see that these commands take effect. When you log out, these values should be saved to your yml file and will be reloaded back in when you rejoin the server.
-
View User Profile
-
Send Message
Posted May 19, 2014I'm using 1.7.2 RO.2 and it still doesn't work (i changed every mobs default setting to manual 200 and it still doesn't effect them...) :(
-
View User Profile
-
Send Message
Posted Mar 27, 2014Needs an update for Bukkit 1.7.5 - I'll put in a ticket for the current errors later.
-
View User Profile
-
Send Message
Posted Mar 18, 2014@frol1
Yes. DynamicDifficulty v1.2.2 works on Bukkit 1.7.2-R0.2.
-
View User Profile
-
Send Message
Posted Mar 15, 2014Is this working On 1.7?
-
View User Profile
-
Send Message
Posted Feb 24, 2014@kittsfu
DynamicDifficulty v1.0.1 does not have any exploits, however it does have two bugs.
In the first bug, an error will generate whenever a mob not found in the list of dynamically changing mobs untargets a player.
In the second bug, sometimes the plugin would lose the data it had about a player. This would completely stop dynamic difficulty scaling for that particular player.
It was not originally my plan to provide fixes for 1.6.4, however seeing as there is a desire for it and it would be more professional of me as a developer, I will provide a fix for it. Additionally, I will bring the 1.6.4 compatible version of the plugin up to date with the current features of the plugin. After that, while I will fix any bugs for 1.6.4 that may come up, I cannot promise that I will add additional new features to the 1.6.4 version.
-
View User Profile
-
Send Message
Posted Feb 23, 2014I'm running a server with recommended craftbukkit 1.6.4 ..
How does your 1.6.4-R2 plugin version hold up? Was it filled with exploits/bugs? Did it work without problems? (DynamicDifficulty v1.0.1 Release CB 1.6.4-R2.0 124 16 November 2013)
I'm thinking of downloading it from the curse site, but i'll await a reply on it's condition first.
I love the idea of the plugin. Great work.
-
View User Profile
-
Send Message
Posted Feb 15, 2014Hey Siege,
Thanks for the reply. I wasn't sure if you were setting the mob's attributes when they spawn (based on the nearest player), or if you were doing something more dynamic. I'm assuming things like speed and damage are set when the mob acquires a new target?
A region would be great and definitely allow for the most flexibility. I've actually revamped my MobArena to compensate for the increased difficulty, and my players are more addicted to MA than ever before. Thanks again for such a great plugin.
-
View User Profile
-
Send Message
Posted Feb 13, 2014@TwitchXTRM
Currently, there are two big issues with changing the difficulty of the mobs. This is not to say it cannot be done, but there are two issues to deal with:
Others have mentioned changing the mob's max health as well. Seeing as it is a popular request, I will put it on my to do list to add to this plugin. Even with these issues, I am sure I can work something out.
As for disabling the dynamic difficulty for a particular group of mobs or a particular region, I think the region one would be easier to pull off. I think the region one would also allow greater flexibility because then it could work in conjunction with other plugins or situations on a server, not just Mob Arena or similar plugins that spawn additional mobs. I will also make note of this as a future thing to add.
-
View User Profile
-
Send Message
Posted Feb 9, 2014Loving this plugin, it's added another level onto Hard mode (which really isnt that hard) that I'm really enjoying.
I have a couple of requests/questions:
Is it possible to dynamically increase the mobs health in a similar fashion to the other attributes?
Is it possible to disable dynamic difficulty for mobs that spawn from Mob Arena? That is my biggest request if at all possible. Even if we could define a region where any spawned mobs spawn as regular, that would be great.