Jump to content

Alive near mobs by Entry C#. Avoidmobs HB


happiness7

Recommended Posts

Hello.
In first I want to ask C# code for getting attackable and alive nearest mob by Entry.
Some like this, but need only alive.

wManager.Wow.ObjectManager.ObjectManager.GetNearestWoWUnit(wManager.Wow.ObjectManager.ObjectManager.GetWoWUnitByEntry())

 

And i'm interested in analog "AvoidMobs" from HB. I need fully blacklist one boss so as not touch him in combat and just ignore

<QuestsSorted Action="RunCode" NameClass="wManager.wManagerSetting.AddBlackListNpcEntry(111)" /> not work for it

and 

<QuestsSorted Action="RunCode" NameClass="wManager.Wow.Helpers.Conditions.ForceIgnoreIsAttacked = true;" /> not work for it when quest pulse

 

Link to comment
Share on other sites

WoWUnit unit = ObjectManager.GetObjectWoWUnit().OrderBy(u => u.GetDistance2D).FirstOrDefault(u => u.Entry == 1234 && u.IsAlive);

replace 1234 with your id you are looking for.

"Not working" means nothing happens or do you get errors?

Edited by iMod
Link to comment
Share on other sites

<QuestsSorted Action="RunCode" NameClass="wManager.wManagerSetting.AddBlackListNpcEntry(111)" /> nothing happens
"wManager.Wow.Helpers.Conditions.ForceIgnoreIsAttacked = true" - its stop ignore fight when pulse "KillAndLoot" quest and killing all who attacks bot

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...