diff --git a/eco-api/src/main/java/com/willfp/eco/util/LightningUtils.java b/eco-api/src/main/java/com/willfp/eco/util/LightningUtils.java index e60a77624..3f63392fe 100644 --- a/eco-api/src/main/java/com/willfp/eco/util/LightningUtils.java +++ b/eco-api/src/main/java/com/willfp/eco/util/LightningUtils.java @@ -3,7 +3,6 @@ import lombok.experimental.UtilityClass; import org.bukkit.Location; import org.bukkit.Sound; -import org.bukkit.SoundCategory; import org.bukkit.entity.LivingEntity; import org.jetbrains.annotations.NotNull; @@ -21,21 +20,26 @@ public class LightningUtils { * @param silent If the lightning sound should be played locally */ public void strike(@NotNull final LivingEntity victim, - final double damage, boolean silent) { + final double damage, + final boolean silent) { Location loc = victim.getLocation(); if (silent) { victim.getWorld().spigot().strikeLightningEffect(loc, true); victim.getWorld().playSound(loc, Sound.ENTITY_LIGHTNING_BOLT_IMPACT, 1, 1); - } - else { + } else { victim.getWorld().strikeLightningEffect(loc); } victim.damage(damage); } - + /** + * Strike lightning on a victim without fire. + * + * @param victim The entity to smite. + * @param damage The damage to deal. + */ public void strike(@NotNull final LivingEntity victim, final double damage) { strike(victim, damage, false);