:WaitForMob
/if (${Target.ID} && ${FaceTimer}==0) /face nolook
/look 0
/doevents
/if (${MercOn} && !${MercAssisting} && ${MyTargetID} && ${Mercenary.State.Equal[Active]} && ${Spawn[${MyTargetID}].Distance}<=${CampRadius}) /call MercsDoWhat
/call MobRadar ${CampRadius}
/if (${MobCount}>=2 || ${MobCount}==1 && ${AddsArray[1,1]}!=${MyTargetID}) {
/varset MyTargetID 0
/varset MyTargetName
/call CheckForAdds WaitForMob
}
|- Make sure pet is returning to camp with me if not!
:BringBackThePet
/if (${Select[${Role},pullerpettank]} && ${Me.Pet.ID} && ${Math.Distance[${Me.Pet.Y},${Me.Pet.X}:${CampYLoc},${CampXLoc}]}>${CampRadius} && ${Math.Distance[${Me.Pet.Y},${Me.Pet.X}:${Me.Y},${Me.X}]}>20) {
/pet back off
/delay 10 (${Math.Distance[${Me.Pet.Y},${Me.Pet.X}:${CampYLoc},${CampXLoc}]}<=${CampRadius})
/if (${Math.Distance[${Me.Pet.Y},${Me.Pet.X}:${CampYLoc},${CampXLoc}]}>${CampRadius} && ${Math.Distance[${Me.Pet.Y},${Me.Pet.X}:${Me.Y},${Me.X}]}>20) /goto :BringBackThePet
}
| if target lost somehow add to ignore list and continue pulls
/if (!${AggroTargetID} || ${WaitTimer}==0) {
/if (${DebugPull}) /echo DEBUGPULL WaitForMob /return no AggroTargetID
/varset PullTempIgnoreList ${Target.ID},${PullTempIgnoreList}
/squelch /alert add 1 id ${Target.ID}
/call PullReset
/return
}
/if (${Math.Distance[${Me.Pet.Y},${Me.Pet.X}:${Spawn[${MyTargetID}].Y},${Spawn[${MyTargetID}].X}]}<=${PetAttackRange}) /call CombatPet
/varset FaceTimer 1s
/if (${Spawn[${MyTargetID}].Distance}<=${MeleeDistance}) /call AggroCheck
/if (${PetTanking} && ${Select[${Role},pullerpettank]} && ${Math.Distance[${CampYLoc},${CampXLoc}]}<=${CampRadius} && ${Spawn[${MyTargetID}].Distance}>=${MeleeDistance}) /goto :WaitForMob
/if (!${PetTanking} && ${Spawn[${MyTargetID}].Distance}>=${CampRadius}) /goto :WaitForMob
}