forked from Upstream/mmocore
Fixed an issue with perm drop table condition
This commit is contained in:
parent
8525a1c56d
commit
d5d75fe697
@ -1,8 +1,7 @@
|
||||
package net.Indyuce.mmocore.api.droptable.condition;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import io.lumine.mythic.lib.api.MMOLineConfig;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
public class PermissionCondition extends Condition {
|
||||
private final String perm;
|
||||
@ -17,7 +16,7 @@ public class PermissionCondition extends Condition {
|
||||
@Override
|
||||
public boolean isMet(ConditionInstance entity) {
|
||||
if (entity.getEntity() instanceof Player)
|
||||
return ((Player) entity).hasPermission(perm);
|
||||
return entity.getEntity().hasPermission(perm);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
@ -75,10 +75,6 @@ public class MythicMobSkill extends Skill {
|
||||
return antiCheat;
|
||||
}
|
||||
|
||||
public String getInternalName() {
|
||||
return skill.getInternalName();
|
||||
}
|
||||
|
||||
public io.lumine.xikage.mythicmobs.skills.Skill getSkill() {
|
||||
return skill;
|
||||
}
|
||||
@ -94,7 +90,7 @@ public class MythicMobSkill extends Skill {
|
||||
|
||||
AbstractEntity trigger = BukkitAdapter.adapt(caster.getPlayer());
|
||||
SkillCaster skillCaster = new GenericCaster(trigger);
|
||||
io.lumine.xikage.mythicmobs.skills.SkillMetadata skillMeta = new io.lumine.xikage.mythicmobs.skills.SkillMetadata(SkillTrigger.API, skillCaster, trigger, BukkitAdapter.adapt(caster.getPlayer().getEyeLocation()), targetEntities, targetLocations, 1);
|
||||
io.lumine.xikage.mythicmobs.skills.SkillMetadata skillMeta = new io.lumine.xikage.mythicmobs.skills.SkillMetadata(SkillTrigger.API, skillCaster, trigger, BukkitAdapter.adapt(caster.getPlayer().getLocation()), targetEntities, targetLocations, 1);
|
||||
|
||||
// Disable anticheat
|
||||
if (MMOCore.plugin.hasAntiCheat())
|
||||
|
Loading…
Reference in New Issue
Block a user