This custom enchantment allow a player to reduce the raw received damage.  If "full_armor", option is true, the player needs to wear all armor pieces to activate this effect.  If "full_armor" is false, any worn armor pieces with this enchantment will trigger the protection.

The amount of damage reduction is calculated based on the enchantment level of each armor piece.  Each armor piece can reduce the damage up to 1/4th of the original raw damage.  This means if you wear all armor pieces and if all pieces have the max enchantment level, you can effectively cancel the damage (if the "multiplier" option is set to 1.0).

This custom enchantment is a polymorphic enchantment and you can define many GodProtection variants in the GodProtection_config.yml with different sets of causes and multipliers and full_armor options.

 

 

  Sample Config