Skip to content

Commit

Permalink
Merge pull request #8 from HaooooZhang/master
Browse files Browse the repository at this point in the history
小修改
  • Loading branch information
Yuqi154 authored Apr 30, 2024
2 parents f74bf29 + 70c6395 commit 8c15abf
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
import net.minecraft.world.entity.LivingEntity;
import org.jetbrains.annotations.NotNull;

import java.util.Objects;

public class VomitingMobEffect extends MobEffect {

protected VomitingMobEffect() {
Expand All @@ -17,7 +19,7 @@ protected VomitingMobEffect() {
public void applyEffectTick(@NotNull LivingEntity entity, int level) {
if (!entity.hasEffect(MobEffects.CONFUSION)) {
entity.addEffect(new MobEffectInstance(MobEffects.CONFUSION,
entity.getEffect(com.gensokyo.nucleardelight.world.effect.MobEffects.VOMITING.get()).getDuration(), 1));
Objects.requireNonNull(entity.getEffect(com.gensokyo.nucleardelight.world.effect.MobEffects.VOMITING.get())).getDuration(), 1));
}
}

Expand Down

0 comments on commit 8c15abf

Please sign in to comment.