Fixed probable BeeHive pet NPE.
This commit is contained in:
@@ -83,7 +83,7 @@ public class BeeHive extends AbstractNpcAI
|
|||||||
}
|
}
|
||||||
|
|
||||||
final Pet pet = attacker.getPet();
|
final Pet pet = attacker.getPet();
|
||||||
if ((pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
if ((pet == null) || (pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
||||||
{
|
{
|
||||||
return super.onAttack(npc, attacker, damage, isSummon);
|
return super.onAttack(npc, attacker, damage, isSummon);
|
||||||
}
|
}
|
||||||
|
@@ -83,7 +83,7 @@ public class BeeHive extends AbstractNpcAI
|
|||||||
}
|
}
|
||||||
|
|
||||||
final Pet pet = attacker.getPet();
|
final Pet pet = attacker.getPet();
|
||||||
if ((pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
if ((pet == null) || (pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
||||||
{
|
{
|
||||||
return super.onAttack(npc, attacker, damage, isSummon);
|
return super.onAttack(npc, attacker, damage, isSummon);
|
||||||
}
|
}
|
||||||
|
@@ -83,7 +83,7 @@ public class BeeHive extends AbstractNpcAI
|
|||||||
}
|
}
|
||||||
|
|
||||||
final Pet pet = attacker.getPet();
|
final Pet pet = attacker.getPet();
|
||||||
if ((pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
if ((pet == null) || (pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
||||||
{
|
{
|
||||||
return super.onAttack(npc, attacker, damage, isSummon);
|
return super.onAttack(npc, attacker, damage, isSummon);
|
||||||
}
|
}
|
||||||
|
@@ -83,7 +83,7 @@ public class BeeHive extends AbstractNpcAI
|
|||||||
}
|
}
|
||||||
|
|
||||||
final Pet pet = attacker.getPet();
|
final Pet pet = attacker.getPet();
|
||||||
if ((pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
if ((pet == null) || (pet.getCurrentFed() == 0) || pet.isDead() || pet.isAffectedBySkill(SKILLS[0]) || pet.isAffectedBySkill(SKILLS[1]))
|
||||||
{
|
{
|
||||||
return super.onAttack(npc, attacker, damage, isSummon);
|
return super.onAttack(npc, attacker, damage, isSummon);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user