<!-- Short Snippets -->
<!-- Most Useful to me -->
<!-- Interact -->
<CustomBehavior File="InteractWith" MobId="251676" X="768.5938" Y="3579.904" Z="141.5099" />
<!--Inline Log Quote-->
<CustomBehavior File="RunCode" Code="Bots.Professionbuddy.PBLog.Log(System.Windows.Media.Colors.Lime, "[ZephyrMMO]: ", System.Windows.Media.Colors.MintCream, " ChangeME ");" />
<!--UseItem-->
<CustomBehavior File="Misc\RunLua" Lua="UseItemByName(110560);" WaitTime="10000" /> <!-- Use [WoD] Garrison Hearthstone -->
<CustomBehavior File="Misc\RunLua" Lua="UseItemByName(140192);" WaitTime="10000" /> <!-- Use [Legion] Dalaran Hearthstone -->
<CustomBehavior File="Misc\RunLua" Lua="UseItemByName(141605);" WaitTime="10000" /> <!-- Use [Legion] Flight Master's Whistle -->
<CustomBehavior File="UseItem" ItemId="139893" WaitTime="1337" />
<!--FlyTo-->
<CustomBehavior File="FlyTo" X="" Y="" Z="" />
<!--PickUp-->
<PickUp Nav="Fly" QuestName="Quest Name" QuestId="1337" GiverName="NPC Name" GiverId="1" X="" Y="" Z="" />
<!--TurnIn-->
<TurnIn Nav="Fly" QuestName="Quest Name" QuestId="1337" TurnInName="NPC Name" TurnInId="1" X="" Y="" Z="" />
<!--WaitTime-->
<CustomBehavior File="WaitTimer" WaitTime="2000" />
<!--Taxi-->
<CustomBehavior File="TaxiRide" MobId="12345" DestName="Orgrimmar" WaitTime="1000" />
<!--PopupBox-->
<CustomBehavior File="UserDialog" QuestId="40715" AllowBotStop="True" SoundCue="Exclamation" SoundCueInterval="150" ExpiryTime="300" ExpiryAction="InputEnabled_Continue"
Text="Choose an artifact weapon.\n\nIf you do not choose within 5minutes, the bot will pick the one appropriate for your current specialization." />
<!--DoWhen-->
<CustomBehavior File="Hooks\DoWhen" UseWhen="HasItem(1234)" ActivityName="NameME" AllowUseWhileFlying="False" AllowUseWhileMounted="False">
</CustomBehavior>
<!-- Delete Items -->
<If Condition="HasItem(129178)" >
<CustomBehavior File="UseItem" ItemId="129178" />
</If>
<If Condition="HasItem(129178)" >
<CustomBehavior File="DeleteItems" Ids="129178" />
</If>
<!--Smelting Obsidium-->
<While Condition="GetItemCount(53038) > 1 && MiningSkill.CurrentValue > 424">
<CustomBehavior File="Misc\RunLua" Lua="for i=1,GetNumTradeSkills() do if GetTradeSkillInfo(i)=='Smelt Obsidium' then DoTradeSkill(i,GetItemCount('Obsidium Ore')/2) break end end " />
<CustomBehavior File="WaitTimer" WaitTime="15000"/>
</While>
<!--Smelting Elementium-->
<While Condition="GetItemCount(52185) > 1 && MiningSkill.CurrentValue > 474">
<CustomBehavior File="Misc\RunLua" Lua="for i=1,GetNumTradeSkills() do if GetTradeSkillInfo(i)=='Smelt Elementium' then DoTradeSkill(i,GetItemCount('Elementium Ore')/2) break end end " />
<CustomBehavior File="WaitTimer" WaitTime="15000"/>
</While>
<!--Smelting Pyrite-->
<While Condition="GetItemCount(52183) > 1 && MiningSkill.CurrentValue > 524">
<CustomBehavior File="Misc\RunLua" Lua="for i=1,GetNumTradeSkills() do if GetTradeSkillInfo(i)=='Smelt Pyrite' then DoTradeSkill(i,GetItemCount('Pyrite Ore')/2) break end end " />
<CustomBehavior File="WaitTimer" WaitTime="15000"/>
</While>
<CustomBehavior File="Misc\RunLua" Lua="CloseTradeSkill()" />
<!--PursueUnit-->
<PursuitList>
<PursueUnit Id="92957" PursueWhen="(UNIT.Z >= 371 && Me.Z >= 160) || (UNIT.Z > 141 && Me.Z < 160)" />
<!-- Only use the one the bot can easily navigate to. The zeppelin-boat-thing slowly descends so we're detecting the two stop positions. -->
</PursuitList>
<!--ReloadProfile-->
<CustomBehavior File="RunCode">
<![CDATA[
Logging.Write(System.Windows.Media.Colors.DeepSkyBlue, "[ProfileBase]: Reloading profile.");
ProfileManager.LoadNew(ProfileManager.XmlLocation);
]]>
</CustomBehavior>
<!--Long Snippets-->
<Follow> <!--Start-->
<CustomBehavior File="RunCode">
<![CDATA[
var ethelPoi = ObjectManager.GetObjectsOfType<WoWUnit>().FirstOrDefault(x => x.Entry == 107726);
Random rnd = new Random();
while (ethelPoi != null && !QuestDone(42590))
{
while (ethelPoi.Distance > 6)
{
Navigator.MoveTo(ethelPoi.Location);
await Coroutine.Yield();
}
WoWMovement.ClickToMove(WoWMathHelper.CalculatePointInFront(ethelPoi.Location, ethelPoi.Rotation, 3.5f));
await Coroutine.Wait(rnd.Next(2000, 2500), () => ethelPoi.IsMoving);
if (!ethelPoi.IsMoving)
{
WoWMovement.ClickToMove(WoWMathHelper.CalculatePointBehind(ethelPoi.Location, ethelPoi.Rotation, 2.5f));
await Coroutine.Sleep(2000);
}
else
await Coroutine.Sleep(rnd.Next(500, 1000));
await Coroutine.Yield();
}
]]>
</CustomBehavior>