|
@@ -188,17 +188,18 @@ public class Combat {
|
|
|
}
|
|
|
}
|
|
|
else if (damager instanceof Arrow) {
|
|
|
- if (!configInstance.getArcheryPVP() && ((Arrow) damager).getShooter().getType().equals(EntityType.PLAYER)) {
|
|
|
- if (targetIsPlayer || targetIsTamedPet) {
|
|
|
- return;
|
|
|
- }
|
|
|
+ if (((Arrow) damager).getShooter().getType() != EntityType.PLAYER) {
|
|
|
+ return;
|
|
|
}
|
|
|
|
|
|
- if (!configInstance.getArcheryPVE() && !((Arrow) damager).getShooter().getType().equals(EntityType.PLAYER)) {
|
|
|
- if (!targetIsPlayer || !targetIsTamedPet) {
|
|
|
+ if (targetIsPlayer || targetIsTamedPet) {
|
|
|
+ if (!configInstance.getArcheryPVP()) {
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
+ else if (!configInstance.getArcheryPVE()) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
|
|
|
archeryCheck(event, plugin);
|
|
|
}
|