Sueta
FO

FortuneBlocks

2.1

Allow FortuneBlocks to cause the Fortune enchantment to work on any block you want.

·Plugin

FORTUNE BLOCKS

This plugin is designed for servers that want to allow players to have fortune on their pickaxes apply to things other than the default.

Completely customizable, the lang and config files can be reloaded on the fly with extremely easy to use commands to manage adding and removing tracked materials.

Additionally, this plugin can track blocks that players place in order to prevent them from infinitely duplicating blocks.

Config:

version: 2.0
blocks:
- diamond_block
- emerald_block
- gold_block
- coal_block
pickup: true
full:
  drop: true
  message:
    use: true
    cooldown: 5
require_survival: true
tracking:
  enabled: false
  save_rate: 6000
  • version: Do not touch this! If it does not match what is in the plugin's code, it will wipe your changes.
  • blocks: The materials that this plugin will apply to.
  • pickup: When true, it will send items straight to a player's inventory. Alternatively, this can be given on a case by case basis using the permission seen below.
  • full: What to do when a player's inventory is full and they are supposed to pick up items
  • full.drop: When true, drops items on the floor instead of them disappearing.
  • full.message: Settings for the message players get with a full inventory
  • full.message.use: When true, it will send a message to the players.
  • full.message.cooldown: The cooldown, in seconds, for a player to get the full inventory message.
  • require_survival: Require a player to be in survival to get fortune blocks. Should almost always be true.
  • tracking: Settings to track block placing.
  • tracking.enabled: When true, will save placed blocks and write it to a file to prevent players duping blocks. Recommended only for non-prison servers. Leave FALSE most of the time.
  • tracking.save_rate: The time in ticks between file saves.

Commands:

/fortuneblocks
- add [material] - Adds a new material to be tracked.
- remove [material] - Removes a material to be tracked.
- list - Lists off all tracked materials.
- reload - Reloads the configuration and lang files.

Permissions:

  • fortuneblocks.silent - Allows players to place blocks without it being tracked.
  • fortuneblocks.pickup - Allows items to go directly to a player's inventory when the option is toggled off by default.
  • fortuneblocks.admin - Allows use of the command system.
  • fortuneblocks.admin.add - Allows admins to add materials
  • fortuneblocks.admin.remove - Allows admins to remove materials
  • fortuneblocks.admin.list - Allows admins to list off materials
  • fortuneblocks.admin.reload - Allows admins to reload the config and lang.

Common Issues:

  • To use the command system, you must have the permission "fortuneblocks.admin" as well as "fortuneblocks.admin.[command]"
  • ?

Known Bugs:

  • When tracking is enabled, players can get around the tracking by moving blocks with a piston.
  • When you are not running the latest version of 1.12, this plugin must cancel the BlockBreakEvent, which is how other plugins "listen" to blocks being broken. This should not be a problem ever unless you have a plugin that records a history of blocks breaking. There is no way to fix this besides updating to the most recent version of 1.12, or having me write a specific hook into whatever plugin you are having problems with. If you really need it fixed to be able to use this plugin, let me know which plugin there are conflicts with and I can try to see if I can make a workaround.

Credits:

  • Essentials team - Essentials items.csv file is used to make life easier.

Similar projects

Plugin →