Skip to content

About

A Bukkit Minecraft plugin that allows each player on a server to experience their own effective difficulty level, independent of the server's global difficulty.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

10 Commits

Folders and files

Repository files navigation

PerPlayerDifficulty

PerPlayerDifficulty is a Bukkit plugin that allows each player on a Minecraft server to experience their own effective difficulty level, independent of the server's global difficulty.

The server difficulty must be set to hard (recommended), normal, or easy. This plugin will not work correctly if the server is on peaceful.

Features

  • Players can select between peaceful, easy, normal, or hard difficulties
    • By default, they will be set to the same difficulty as the server is in
  • Player and admin commands to check and modify difficulties
  • The plugin acts on top of the server's global difficulty, modifying:
    • Hostile mob spawning
    • Hostile mob damage scaling and behavior
    • Hunger and starvation behavior

Commands

All commands are rooted at /playerdifficulty. /ppd and /mydifficulty are available as aliases of the same command.

Player Commands

Command Description Permission
/playerdifficulty Show your current difficulty none
/playerdifficulty <difficulty> Set your own difficulty none
/playerdifficulty reset Reset your difficulty to default none
/playerdifficulty help Show all the plugin's commands none

Admin Commands

Command Description Permission
/playerdifficulty get <player> View another player's difficulty perplayerdifficulty.admin
/playerdifficulty set <difficulty> <player> Set another player's difficulty perplayerdifficulty.admin
/playerdifficulty reset <player> Reset another player's difficulty to default perplayerdifficulty.admin

Mob spawning

Hostile mobs (except hoglins, shulkers, piglins, and ender dragons) can't spawn naturally within 128 blocks of a peaceful player.

If a non-peaceful player is within 128 blocks of a peaceful player, then the prioritize-easier-difficulties setting will decide if monsters can spawn or not. By deafult, the non-peaceful player will have priority and monters will spawn.

Mob Damage

Hostile mobs don't target peaceful players and they can't inflict damage to them.

For non-peaceful players, hostile mob damage is scaled to match with the player's difficulty. See the Minecraft wiki for details on damage scaling.

Hunger / Starvation

The damage due to starvation is dynamically modified in order to match with the expected behavior of the player's difficulty. See the Minecraft wiki for details on how starvation acts on different difficulties. On peaceful, the hunger bar never decreases.

Other sources of damage

Peaceful players won't receive any damage from explosions.

Zombies Breaking Doors

NOTE: If the server is not on hard difficulty, zombies will not be able to break doors at all, independently of the player's difficulty.

By default, if all nearby players are on peaceful, easy, or normal, door breaking is cancelled. Note that zombies will still pathfind towards the player and try to break the door, but they won't succeed and give up afterwards.

This behavior is affected by the prioritize-easier-difficulties setting.

Things this mod does NOT do (at least for now)

  • This mod doesn't affect zombie villager conversion
  • It doesn't kill existing mobs
  • It doesn't affect pillager raids
  • It doesn't affect mob equipment and loot
  • It doesn't affect status effects inflicted on the player (such as poison)
  • It doesn't affect how lightning behaves

All of these things will behave following the server's difficulty setting.

Recommended server difficulty

It's recommended that the server is set to HARD difficulty. Otherwise some features will not work as expected for hard players. The game will be a bit more difficult for easy and normal players though, since raids will be stronger and mobs will have better equipment.

Easy and normal are also playable, but some features of hard difficulty won't be available for hard players, such as door-breaking, better mob loot, or villagers always converting to zombies.

The server must NOT be set to peaceful, since that disables hostile mobs entirely. If you want players to be on peaceful by default, you can set the default-difficulty setting to PEACEFUL.

Server configuration

The server configuration file is available at plugins/PerPlayerDifficulty/config.yml, it should be created automatically when the plugin is first run. These are the available options:

  • default-difficulty: default difficulty that players are assigned. It defaults to the same one the server is using.
  • prioritize-easier-difficulties: controls how conflicts between different-difficulty players are handled. Affects two cases:
    • If a peaceful and a non-peaceful player are near each other, this controls whether hostile mobs spawn or not. They will NOT spawn if this is set to true. They will spawn if it's set to false.
    • If a hard and a non-hard player are near each other, this controls whether zombies can break doors or not. They will NOT break doors if this is set to true. They will break doors if it's set to false.
    • Note that if the players are far from each other this won't have any effect and each one will experience their own difficulty.

About

A Bukkit Minecraft plugin that allows each player on a server to experience their own effective difficulty level, independent of the server's global difficulty.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages