/* Version 1.01 of Priest routine for Bytebot Changelog: 1.40 Mana mode added 1.30 Removed Echo's to prevent console spam Fixed & Improved Downtime codes Started using CastInstantSpell 1.20 Minor bug fixes Stands up before healing in downtime! Now only buffs fear ward if not in shadowform 1.10 Minor bug fixes Casts Fear Ward now before Shadowform 1.00 Release Credits to Glave */ objectdef oToon inherits oToonBase { variable string LastCast variable int ShadowPain = 5 variable int Manaconserve = 10 variable int HealTime = 0 variable int VampTime = 0 member NeedBuff() { if !${Me.Buff[Power Word: Fortitude](exists)} && ${Spell["Power Word: Fortitude"](exists)} { return TRUE } elseif !${Me.Buff[Fear Ward](exists)} && ${Spell["Fear Ward"](exists)} && !${Me.Buff[Shadowform](exists)} { return TRUE } elseif !${Me.Buff[Shadowform](exists)} && ${Spell["Shadowform"](exists)} { return TRUE } elseif !${Me.Buff[Inner Fire](exists)} && ${Spell["Inner Fire"](exists)} { return TRUE } return FALSE } method BuffPulse() { if ${Me.Casting} || ${Math.Calc[${LavishScript.RunningTime} - ${This.LastBuffCast}]} < 100 { return } if !${Me.Buff[Power Word: Fortitude](exists)} && !${Spell["Power Word: Fortitude"].Cooldown} { This:CastInstantSpell[Power Word: Fortitude] This.LastBuffCast:Set[${LavishScript.RunningTime} + 1200] } elseif !${Me.Buff[Fear Ward](exists)} && !${Spell["Fear Ward"].Cooldown} && ${Spell[Fear Ward](exists)} && !${Me.Buff[Shadowform](exists)} { This:CastInstantSpell[Fear Ward] This.LastBuffCast:Set[${LavishScript.RunningTime} + 1200] } elseif !${Me.Buff[Shadowform](exists)} && !${Spell["Shadowform"].Cooldown} && ${Spell[Shadowform](exists)} { This:CastInstantSpell[Shadowform] This.LastBuffCast:Set[${LavishScript.RunningTime} + 1200] } elseif !${Me.Buff[Inner Fire](exists)} && !${Spell["Inner Fire"].Cooldown} && ${Spell[Inner Fire](exists)} { This:CastInstantSpell[Inner Fire] This.LastBuffCast:Set[${LavishScript.RunningTime} + 1200] } } member NeedRest() { if ${Me.Buff[Drink](exists)} && ${Me.PctMana} < 99 return TRUE if ${Me.PctHPs} < 90 { return TRUE } if ${Me.PctMana} < 60 { return TRUE } return FALSE } method RestPulse() { if ${Me.PctMana} > 99 && ${Me.Buff[Drink](exists)} { This:Stand } if ${Me.PctHPs} < 90 && !${Me.Buff[Drink](exists)} { This:Stand if ${HealTime} < ${LavishScript.RunningTime} - 5000 HealTime:Set[${LavishScript.RunningTime} - 1000] if ${Me.Buff[Shadowform](exists)} { Me.Buff[Shadowform]:Remove } if ${Me.PctHPs} < 90 && ${Me.PctHPs} > 85 && !${Me.Buff[Renew](exists)} && !${Me.Buff[Shadowform](exists)} && ${HealTime} + 250 < ${LavishScript.RunningTime} { This:CastInstantSpell[Renew] } if ${Spell[Flash Heal](exists)} && ${Me.Action[Flash Heal].Usable} && ${Me.PctHPs} < 85 && !${Me.Buff[Shadowform](exists)} && ${HealTime} + 250 < ${LavishScript.RunningTime} { CastSpell "Flash Heal" } elseif ${Spell[Heal](exists)} && ${Me.Action[Heal].Usable} && !${Spell[Flash Heal](exists)} && ${Me.PctHPs} < 85 && ${HealTime} + 250 < ${LavishScript.RunningTime} { CastSpell "Heal" } elseif ${Spell[Lesser Heal](exists)} && ${Me.Action[Lesser Heal].Usable} && !${Spell[Flash Heal](exists)} && !${Spell[Heal](exists)} && ${Me.PctHPs} < 85 && ${HealTime} + 250 < ${LavishScript.RunningTime} { CastSpell "Lesser Heal" } } if !${Me.Buff[Drink](exists)} && ${Me.PctMana} < 60 { Consumable:Drink } } method CastSpell(string SpellName) { if ${Navigator.HaveDestination} { Navigator:ResetDestination } Cast "${SpellName}" LastCast:Set["${SpellName}"] } method Routine() { if ${Me.Casting} || ${Math.Calc[${LavishScript.RunningTime} - ${This.LastCastTime}]} < 100 || ${Me.GlobalCooldown} > 0 { return } if !${Me.Attacking} { WoWScript AttackTarget() } if ${VampTime} < ${LavishScript.RunningTime} - 5000 VampTime:Set[${LavishScript.RunningTime} - 1000] if ${Me.PctHPs} < 15 { if ${Spell[Power Word: Shield](exists)} && ${Me.Action[Power Word: Shield].Usable} && !${Me.Buff[Weakened Soul](exists)} { This:CastInstantSpell[Power Word: Shield] } if ${Me.PctHPs} < 5 && ${Spell[Psychic Scream](exists)} && ${Me.Action[Psychic Scream].Usable} { This:CastInstantSpell[Psychic Scream] } if ${Me.Buff[Shadowform](exists)} { Me.Buff[Shadowform]:Remove } if ${Spell[Desperate Prayer](exists)} && ${Me.Action[Desperate Prayer].Usable} { This:CastInstantSpell[Desperate Prayer] } if ${Spell[Flash Heal](exists)} && ${Me.Action[Flash Heal].Usable} { CastSpell "Flash Heal" } elseif ${Spell[Heal](exists)} && ${Me.Action[Heal].Usable} && !${Spell[Flash Heal](exists)} { CastSpell "Heal" } elseif ${Spell[Lesser Heal](exists)} && ${Me.Action[Lesser Heal].Usable} && !${Spell[Flash Heal](exists)} && !${Spell[Heal](exists)} { CastSpell "Lesser Heal" } return } if ${Target.PctHPs}<${This.ShadowPain} && ${Spell[Shadow Word: Death](exists)} && ${Me.Action[Shadow Word: Death].Usable} { This:CastInstantSpell[Shadow Word: Death] return } if ${Me.Buff[Surge Of Light](exists)} && ${Me.Action[Smite].Usable} && ${Target(exists)} { This:CastInstantSpell[Smite] return } if !${Target.Buff[Shadow Word: Pain](exists)} && ${Spell[Shadow Word: Pain](exists)} && ${Me.Action[Shadow Word: Pain].Usable} { This:CastInstantSpell[Shadow Word: Pain] return } if !${Target.Buff[Vampiric Embrance](exists)} && ${Spell[Vampiric Embrance](exists)} && ${Me.Action[Vampiric Embrance].Usable} { CastSpell "Vampiric Embrance" return } if !${Target.Buff[Vampiric Touch](exists)} && ${Spell[Vampiric Touch](exists)} && ${Me.Action[Vampiric Touch].Usable} && ${Me.PctMana}>${This.Manaconserve} && ${VampTime} + 250 < ${LavishScript.RunningTime} { This:CastInstantSpell[Vampiric Touch] This.LastCastTime:Set[${LavishScript.RunningTime} + 3000] return } if ${Spell[Power Word: Shield](exists)} && ${Me.Action[Power Word: Shield].Usable} && !${Me.Buff[Weakened Soul](exists)} { This:CastInstantSpell[Power Word: Shield] return } if ${Me.PctMana}<${This.Manaconserve} { CastSpell "Shoot" } if ${Spell[Mind Flay](exists)} && ${Me.Action[Mind Flay].Usable} && ${Me.Buff[Power Word: Shield](exists)} && ${Me.PctMana}>${This.Manaconserve} { CastSpell "Mind Flay" return } if ${Spell[Smite](exists)} && ${Me.Action[Smite].Usable} && !${Spell[Mind Blast](exists)} && ${Me.PctMana}>${This.Manaconserve} { CastSpell "Smite" return } if ${Spell[Mind Blast](exists)} && ${Me.Action[Mind Blast].Usable} && ${Me.PctMana}>${This.Manaconserve} { CastSpell "Mind Blast" return } } }