View Single Post
  #2  
Old 02-17-2010, 02:25 PM
incorect incorect is offline
Large Rat


Join Date: Feb 2010
Posts: 9
Default

Ok, I added an if check to make sure the pet is holding an item in its offhand.

bool Mob::CanThisClassDualWield(void) const //Dual wield not Duel, busy someone else fix it (fixed! bUsh)
{
// All npcs over level 13 can dual wield
if (this->IsNPC() && (this->GetLevel() >= 13))
return true;

if (IsPet() && GetOwner()->IsClient())
{
if (GetOwner()->GetClass() == MAGICIAN && GetLevel() >= MAGI_PET_DUAL_LEVEL
|| GetOwner()->GetClass() == NECROMANCER && GetLevel() >= NECRO_PET_DUAL_LEVEL)
{
if (GetEquipment(14)) // checks if pet has item in off hand
return true;
}
}
...