public function getModifyAttackDamage(Entity $target)
{
$rec = $this->getAttackDamage();
$sharpL = $this->getEnchantmentLevel(Enchantment::TYPE_WEAPON_SHARPNESS);
if ($sharpL > 0) {
$rec += 0.5 * ($sharpL + 1);
}
if ($target instanceof Skeleton or $target instanceof Zombie or $target instanceof Witch or $target instanceof PigZombie) {
//SMITE wither skeletons
$rec += 2.5 * $this->getEnchantmentLevel(Enchantment::TYPE_WEAPON_SMITE);
} elseif ($target instanceof Spider or $target instanceof CaveSpider or $target instanceof Silverfish) {
//Bane of Arthropods wither skeletons
$rec += 2.5 * $this->getEnchantmentLevel(Enchantment::TYPE_WEAPON_ARTHROPODS);
}
return $rec;
}