Crystalite Armor additional effects

This commit is contained in:
Aleksey 2021-05-09 23:37:09 +03:00
parent 5d81d7b448
commit bc53748657
18 changed files with 252 additions and 116 deletions

View file

@ -16,7 +16,7 @@ public class EndPotions {
public final static Potion LONG_END_VEIL = registerPotion("long_end_veil", EndStatusEffects.END_VEIL, 9600);
public static Potion registerPotion(String name, MobEffect effect, int duration) {
return registerPotion(name, new Potion(name, new MobEffectInstance[]{ new MobEffectInstance(effect, duration) }));
return registerPotion(name, new Potion(name, new MobEffectInstance(effect, duration)));
}
public static Potion registerPotion(String name, Potion potion) {

View file

@ -2,13 +2,18 @@ package ru.betterend.effects;
import net.minecraft.core.Registry;
import net.minecraft.world.effect.MobEffect;
import net.minecraft.world.effect.MobEffectInstance;
import net.minecraft.world.effect.MobEffects;
import ru.betterend.BetterEnd;
import ru.betterend.effects.status.EndVeilEffect;
public class EndStatusEffects {
public final static MobEffectInstance CRYSTALITE_HEALTH_REGEN = new MobEffectInstance(MobEffects.REGENERATION, 40, 0, true, false, true);
public final static MobEffectInstance CRYSTALITE_DIG_SPEED = new MobEffectInstance(MobEffects.DIG_SPEED, 40, 0, true, false, true);
public final static MobEffectInstance CRYSTALITE_MOVE_SPEED = new MobEffectInstance(MobEffects.MOVEMENT_SPEED, 40, 0, true, false, true);
public final static MobEffect END_VEIL = registerEffect("end_veil", new EndVeilEffect());
public static <E extends MobEffect> MobEffect registerEffect(String name, E effect) {
return Registry.register(Registry.MOB_EFFECT, BetterEnd.makeID(name), effect);
}