mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-23 13:46:46 +01:00
Fix issue #620
This commit is contained in:
parent
e9425625e2
commit
a16d5b62cf
@ -271,11 +271,6 @@ public final class CombatTools {
|
|||||||
AcrobaticsManager acrobaticsManager = new AcrobaticsManager(Users.getPlayer(player));
|
AcrobaticsManager acrobaticsManager = new AcrobaticsManager(Users.getPlayer(player));
|
||||||
acrobaticsManager.dodgeCheck(event);
|
acrobaticsManager.dodgeCheck(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Unarmed.pvpEnabled && heldItem.getType() == Material.AIR && Permissions.deflect(player)) {
|
|
||||||
UnarmedManager unarmedManager = new UnarmedManager(Users.getPlayer(player));
|
|
||||||
unarmedManager.deflectCheck(event);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (Swords.pveEnabled && damager instanceof LivingEntity && ItemChecks.isSword(heldItem) && Permissions.counterAttack(player)) {
|
if (Swords.pveEnabled && damager instanceof LivingEntity && ItemChecks.isSword(heldItem) && Permissions.counterAttack(player)) {
|
||||||
@ -308,8 +303,16 @@ public final class CombatTools {
|
|||||||
ArcheryManager archeryManager = new ArcheryManager(mcMMOPlayer);
|
ArcheryManager archeryManager = new ArcheryManager(mcMMOPlayer);
|
||||||
archeryManager.skillShot(event);
|
archeryManager.skillShot(event);
|
||||||
|
|
||||||
if (target instanceof Player && Permissions.daze(shooter)) {
|
if (target instanceof Player) {
|
||||||
archeryManager.dazeCheck((Player) target, event);
|
if (Unarmed.pvpEnabled && ((Player) target).getItemInHand().getType() == Material.AIR && Permissions.deflect((Player) target)) {
|
||||||
|
UnarmedManager unarmedManager = new UnarmedManager(Users.getPlayer((Player) target));
|
||||||
|
unarmedManager.deflectCheck(event);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (Permissions.daze(shooter)) {
|
||||||
|
archeryManager.dazeCheck((Player) target, event);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(shooter.getItemInHand().containsEnchantment(Enchantment.ARROW_INFINITE)) && Permissions.trackArrows(shooter)) {
|
if (!(shooter.getItemInHand().containsEnchantment(Enchantment.ARROW_INFINITE)) && Permissions.trackArrows(shooter)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user