Fixed proximity distance bug

This commit is contained in:
Auxilor 2021-08-22 18:30:41 +01:00
parent eef5c251d6
commit d9d62288fa

View File

@ -19,6 +19,10 @@ public class Proximity extends EcoEnchant {
@NotNull final LivingEntity victim,
final int level,
@NotNull final EntityDamageByEntityEvent event) {
if (!attacker.getWorld().equals(victim.getWorld())) {
return;
}
double distance = attacker.getLocation().distance(victim.getLocation());
double decreaseAfter = this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "when-closer-than-blocks");