This plugin allows a player to have a tool that automatically changes its type to the most suitable type for the action depending on the type of the target object:
 
  • mining -> item will be switched to PickAxe
  • excavating -> item will be switched to Spade
  • woodcutting -> item will be switched to Axe
  • fighting/cobweb -> item will be switched to Sword.
  • harvesting -> item will be switched to Shears/Hoe
Depending on the permission, the type of tool will be determined.  Which type yields what type of tools can be configured in the config file.  A sample configuration is attached at the bottom.
 
Unlike other similar plugins, this plugin automatically pulls out the information about the best tool for a given block type from your underlying Minecraft server.  Therefore, no need to implement/configure specific materials and corresponding tools.  All new materials and any future materials are already supported. (No need to cry for "oh no, xxx block type is not supported... tools are not morphing!", yes, that's correct, this plugin does not hard code which material types should be handled by which tool type.)
 
Demo: 
 
Permissions:
  • omnitool.toggle : allow a user to use /omni command to toggle morphing function as well as /omni name command.
  • omnitool.<set_name> : allow a user to have an access to <set_name> morphing tools.  For example, to give a user an access to DIAMOND set, give him/her "omnitool.DIAMOND.
 
Installation:
Just install OmniTool.jar in the plugins folder. Then you can either "restart the server" or "reload the plugin".
 
Configuration:
 
error_msg : "&c[Omni] : Some error occured."
Messages:
OmniOn: "&a[Omni] Tool %mode%ing is turned on!"
OmniOff: "&a[Omni] Tool %mode%ing is turned off!"

HelpMessages:
banner:
msg: "=== &e[&aOmniTool Commands List (%version%)&e] &r==="
help:
msg: "&a/omni help : display this help menu."
toggle:
msg: "/omni: toggles the omni mode."
premission: "omnitool.toggle"
give:
msg: "/omni give <player> <amount> [name:custom_name]: give <player> <amount> of omni tool with an optional custom_name."
permission: "omnitool.give"
info:
msg: "/omni info : display your current OmniTool status."
name:
msg: "/omni name <toolname> : name the currently holding omni tool as <toolname>."
premission: "omnitool.toggle"
reload:
msg: "&a/omni reload : reloads config.yml."
permission: "omnitool.reload"
debug:
msg: "&a/omni debug <true|false> : turn on / off the debug mode."
permission: "omnitool.debug"

CommandAliases:
- "omni"

# this option is for the target outlet of the messages to go. Previously, they were all sent to chat.
MessageOutlet:
Title: false
SubTitle: false
ActionBar: false
Chat: true

# adjust these event priority if those event processes from this plugin
# interfere with other plugins' event processes.
EventPriorityMap:
PlayerQuitEvent: "HIGHEST"
PlayerInteractEntityEvent: "NORMAL"
PlayerInteractEvent: "HIGHEST"
EntityDamageByEntityEvent: "HIGHEST"
InventoryClickEvent: "HIGHEST"

default_item: FISHING_ROD

# if this option is true, a player can toggle to morphing/switching with
# /omni command.
toggle: true

# if this option is true, (by default it is "true"), when you right click sheep and mushroomcow
# the tool will turn into shears
shears: true

# any worlds, or WorldGuard regions listed below will prevent the use of this plugin function
invalid_worlds:
- pvp

invalid_regions:
- lobby

# tools will be search in the following order atains the nominated block material.
# if you want DIRT, GRASS, GRASs_BLOCK/PATH to trigger a hoe, you should move HOE
# to above SHOVEL.
tool_search_order:
- SHEARS
- SHOVEL
- HOE
- AXE
- PICKAXE
- SWORD

# if the preferred tool selected by the Minecraft is not what you desire, you can
# override the default preference in this config section.
# the target tool description available are:
# AXE, PICKAXE, HOE, SWORD, SHOVEL and SHEARS
# the material name should be the upper case material name defined by bukkit API
# you can use the wild card '*' to represent multiple similar materials.
tool_preferences:
"*VINES": SHEARS
"VINE": SHEARS

# The OmniTool plugin now supports two different modes:
# morph: this is a traditional mode and the special omni tool will morph into an appropriate tool
# switch: this mode will allow you to switch the holding item to to the best tool in your hotbar.
omni_mode:
morph: true
switch: false

# when this option is true, each "morphed" tool will retain its own NBT data
# if this option is false, item's display name, enchants, lore, etc will be shared among morphed tools.
retain_NBT: true

#### configs for switch mode.
# tool will be search based on the order of material below.
# for example, a diamond tool will be used before gold, iron, stone or woold tool.
material_search_order:
- NETHERITE
- DIAMOND
- GOLD
- IRON
- STONE
- WOOD

#### configs for Morph mode.
# fixed slot number: (-1, 0 - 8), If this number if -1, the tool won't be fixed
# at the particular slot.
hot_bar_slot: -1

# to use each set, a player must have a permission node :
# omnitool.<setname> such ase omnitool.WOOD, omnitool.STONE
# if SHOVEL does not work, replace _SHOVEL with _SPADE
Sets:
WOOD:
axe: WOOD_AXE
pickaxe: WOOD_PICKAXE
sword: WOOD_SWORD
spade: WOOD_SHOVEL
hoe: WOOD_HOE
STONE:
axe: STONE_AXE
pickaxe: STONE_PICKAXE
sword: STONE_SWORD
spade: STONE_SHOVEL
hoe: STONE_HOE
IRON:
axe: IRON_AXE
pickaxe: IRON_PICKAXE
sword: IRON_SWORD
spade: IRON_SHOVEL
hoe: IRON_HOE
GOLD:
axe: GOLDEN_AXE
pickaxe: GOLDEN_PICKAXE
sword: GOLDEN_SWORD
spade: GOLDEN_SHOVEL
hoe: GOLDEN_HOE
DIAMOND:
axe: DIAMOND_AXE
pickaxe: DIAMOND_PICKAXE
sword: DIAMOND_SWORD
spade: DIAMOND_SHOVEL
hoe: DIAMOND_HOE
NETHERITE:
axe: NETHERITE_AXE
pickaxe: NETHERITE_PICKAXE
sword: NETHERITE_SWORD
spade: NETHERITE_SHOVEL
hoe: NETHERITE_HOE