63 protected static function setup() :
void{
65 KnownTranslationFactory::enchantment_protect_all(),
70 fn(
int $level) :
int => 11 * ($level - 1) + 1,
74 KnownTranslationFactory::enchantment_protect_fire(),
79 EntityDamageEvent::CAUSE_FIRE,
80 EntityDamageEvent::CAUSE_FIRE_TICK,
81 EntityDamageEvent::CAUSE_LAVA
84 fn(
int $level) :
int => 8 * ($level - 1) + 10,
88 KnownTranslationFactory::enchantment_protect_fall(),
93 EntityDamageEvent::CAUSE_FALL
95 fn(
int $level) :
int => 6 * ($level - 1) + 5,
99 KnownTranslationFactory::enchantment_protect_explosion(),
104 EntityDamageEvent::CAUSE_BLOCK_EXPLOSION,
105 EntityDamageEvent::CAUSE_ENTITY_EXPLOSION
107 fn(
int $level) :
int => 8 * ($level - 1) + 5,
111 KnownTranslationFactory::enchantment_protect_projectile(),
116 EntityDamageEvent::CAUSE_PROJECTILE
118 fn(
int $level) :
int => 6 * ($level - 1) + 3,
122 KnownTranslationFactory::enchantment_thorns(),
125 fn(
int $level) :
int => 20 * ($level - 1) + 10,
129 KnownTranslationFactory::enchantment_oxygen(),
132 fn(
int $level) :
int => 10 * $level,
137 KnownTranslationFactory::enchantment_frostwalker(),
140 fn(
int $level) :
int => 10 * $level,
144 KnownTranslationFactory::enchantment_waterWorker(),
152 KnownTranslationFactory::enchantment_damage_all(),
155 fn(
int $level) :
int => 11 * ($level - 1) + 1,
159 KnownTranslationFactory::enchantment_knockback(),
162 fn(
int $level) :
int => 20 * ($level - 1) + 5,
166 KnownTranslationFactory::enchantment_fire(),
169 fn(
int $level) :
int => 20 * ($level - 1) + 10,
175 KnownTranslationFactory::enchantment_digging(),
178 fn(
int $level) :
int => 10 * ($level - 1) + 1,
182 KnownTranslationFactory::enchantment_lootBonusDigger(),
185 fn(
int $level) :
int => 9 * ($level - 1) + 15,
189 KnownTranslationFactory::enchantment_untouching(),
192 fn(
int $level) :
int => 15,
196 KnownTranslationFactory::enchantment_durability(),
199 fn(
int $level) :
int => 8 * ($level - 1) + 5,
204 KnownTranslationFactory::enchantment_arrowDamage(),
207 fn(
int $level) :
int => 10 * ($level - 1) + 1,
211 KnownTranslationFactory::enchantment_arrowKnockback(),
214 fn(
int $level) :
int => 20 * ($level - 1) + 12,
218 KnownTranslationFactory::enchantment_arrowFire(),
221 fn(
int $level) :
int => 20,
225 KnownTranslationFactory::enchantment_arrowInfinite(),
228 fn(
int $level) :
int => 20,
233 KnownTranslationFactory::enchantment_mending(),
236 fn(
int $level) :
int => 25,
241 KnownTranslationFactory::enchantment_curse_vanishing(),
244 fn(
int $level) :
int => 25,
249 KnownTranslationFactory::enchantment_swift_sneak(),
252 fn(
int $level) :
int => 10 * $level,
257 protected static function register(
string $name,
Enchantment $member) :
void{
258 self::_registryRegister($name, $member);
270 $result = self::_registryGetAll();