/* _____ __ .__ / _ \ ________ ___________ _____/ |_| |__ / /_\ \\___ // __ \_ __ \/ _ \ __\ | \ / | \/ /\ ___/| | \( <_> ) | | Y \ \____|__ /_____ \\___ >__| \____/|__| |___| / \/ \/ \/ \/ Present's to you 'Paladin Routine 1.10b for bbot' **** Changes **** *** 1.00b *** - Started the Routine *** 1.10b *** - Merged with bobbyjayblacks routine - Added Multiple Type of Routines Eg protection etc *** BlizzWishes Notes *** - BW ver 1.1 - Cleaned up Member NeedRest() - Added Routine for Holy - Holy uses Divine Favor with Hammer of Wrath / Holy Shock - Added Shields to healing - Added LOH check **** Known Bugs **** Double Seal of the Crusader */ objectdef oToon inherits oToonBase { ; 1 = Grinding 2 = Protection variable int RoutineType = 3 variable int MinMana = 50 variable int MaxMana = 90 variable int MinBattleHeal = 20 variable int MinHealth = 20 variable int MaxHealth = 90 variable int MinSealMana = 5 variable int LevelBelow = 1 variable int LevelAbove = 2 variable int Interrupt = 1 variable string InterruptSpell = "Hammer of Justice" variable int MountDistance = 90 variable int RepairPct = 5 variable int CorpseCampLimit = 3 variable int PureMelee = 10 ;*** DO NOT TOUCH BELOW UNLESS U NO WAT YOU ARE DOING :P *** variable int JudgeTime = ${LavishScript.RunningTime} variable string Version = "1.10b" variable int PoisonCounter = 0 variable string Aura = "" variable int BuffNum = 0 variable string Blessing = "" ;TRUE=Attack all enemy on site, FALSE=only defend when attacked variable bool AutoPvP = FALSE member NeedBuff() { if !${Me.Buff[${This.Aura}](exists)} && ${Spell[${This.Aura}](exists)} { return TRUE } elseif !${Me.Buff[${This.Blessing}](exists)} && ${Spell[${This.Blessing}](exists)} { return TRUE } elseif !${Me.Buff["Righteous Fury"](exists)} && ${Spell["Righteous Fury"](exists)} { return TRUE } elseif ${Me.Buff["Redoubt"](exists)} && !${Me.Buff["Holy Shield"](exists)} && ${Spell["Holy Shield"](exists)} && ${Spell["Holy Shield"].Cooldown}<=0 { return TRUE } return FALSE } method BuffPulse() { if !${Me.Buff[${This.Aura}](exists)} && ${Spell[${This.Aura}](exists)} { Cast "${This.Aura}" } elseif !${Me.Buff[${This.Blessing}](exists)} && ${Spell[${This.Blessing}](exists)} { Cast "${This.Blessing}" } elseif !${Me.Buff["Righteous Fury"](exists)} && ${Spell["Righteous Fury"](exists)} { Cast "Righteous Fury" } elseif ${Me.Buff["Redoubt"](exists)} && !${Me.Buff["Holy Shield"](exists)} && ${Spell["Holy Shield"](exists)} && ${Spell["Holy Shield"].Cooldown}<=0 { Cast "Holy Shield" } } member NeedRest() { if ${Me.PctHPs} < ${This.MinHealth} { return TRUE } elseif ${Me.PctMana} < ${This.MinMana} { return TRUE } ;elseif ${Me.PctMana} == 100 && ${Me.PctHPs} == 100 ;{ ; return FALSE ; This:Echo["1"] ;} ;elseif ${Me.PctHPs} > ${This.MaxHealth} && ${Me.PctMana} > 10 ;{ ; return FALSE ;} return FALSE } method RestPulse() { if !${Me.Buff[Food](exists)} && ${Me.PctHPs} < ${This.MinHealth} && ${Consumable.GotFood} && !${Me.Buff["Eat"](exists)} && !${Me.Casting} { This:Echo["[Rest] Trying To Eat"] Consumable:Eat } elseif !${Me.Buff[Water](exists)} && ${Me.PctMana} < ${This.MinMana} && ${Consumable.GotDrink} && !${Me.Buff["Drink"](exists)} && !${Me.Casting} { This:Echo["[Rest] Trying To Drink"] Consumable:Drink } elseif ${Me.PctHPs}<${This.MinHealth} && !${Me.Casting} && ${Me.CurrentMana}>${Spell["Holy Light"].Mana} && ${Spell[Holy Light](exists)} { if !${Me.Buff[Water](exists)} && ${Me.Sitting} { wowpress SITORSTAND } This:Echo["[Rest] Casting Holy Light"] Cast "Holy Light" } } ;Check for poisons/curses member NeedCure() { BuffNum:Inc if ${BuffNum} > 56 || !${Me.Buff[${BuffNum}](exists)} { BuffNum:Set[1] if ${PoisonCounter} { return TRUE } } if ${Me.Buff[${BuffNum}].Harmful} { if ${Me.Buff[${BuffNum}].DispelType.Equal[Magic]} && ${Spell[Cleanse](exists)} { return TRUE } elseif ${Me.Buff[${BuffNum}].DispelType.Equal[Disease]} && ${Spell[Cleanse](exists)} { return TRUE } elseif ${Me.Buff[${BuffNum}].DispelType.Equal[Poison]} && ${Spell[Cleanse](exists)} { PoisonCounter:Inc return TRUE } } return FALSE } ;Cure stuff method CurePulse() { if ${Me.Buff[${BuffNum}].DispelType.Equal[Magic]} && ${Me.Action[Cleanse].Usable} { This:CastInstantSpell[Cleanse] } elseif ${Me.Buff[${BuffNum}].DispelType.Equal[Disease]} && ${Me.Action[Disease].Usable} { This:CastInstantSpell[Cleanse] } elseif ${PoisonCounter} { if ${PoisonCounter} == 1 && ${Me.Action[Cleanse].Usable} { Target ${Me.GUID} This:CastInstantSpell[Cleanse] } PoisonCounter:Set[0] } } member NeedHealing() { if ${Me.PctHPs}<${This.MinBattleHeal} { return TRUE } return FALSE } method HealingPulse() { ;BW: Lay on Hands if ${Me.PctHPs} < 10 && ${Spell[Lay on Hands](exists)} && ${Spell[Lay on Hands].Cooldown}<=0 && !${Me.Buff[Blessing of Protection](exists)} && !${Me.Buff[Divine Protection](exists)} && !${Me.Buff[Divine Shield](exists)} { if ${Me.Casting} { WoWScript SpellStopCasting() } Cast "Lay on Hands" This:Echo["[EMERGENCY] About to die, Lay on Hands!"] } ;BW: If we are very low on health we should shield elseif ${Me.PctHPs} < 20 && !${Me.Buff[Forbearance](exists)} { if ${Me.Casting} { WoWScript SpellStopCasting() } if ${Spell[Divine Shield](exists)} && ${Spell[Divine Shield].Cooldown}<=0 && ${Me.CurrentMana}>${Spell[Divine Shield].Mana} && !${Me.Buff[Forbearance](exists)} { Cast "Divine Shield" This:Echo["[Shield] Divine Shield"] } elseif ${Spell[Divine Protection](exists)} && ${Spell[Divine Protection].Cooldown}<=0 && ${Me.CurrentMana}>${Spell[Divine Protection].Mana} && !${Me.Buff[Forbearance](exists)} { Cast "Divine Protection" This:Echo["[Shield] Divine Protection"] } elseif ${Spell[Blessing of Protection](exists)} && ${Spell[Blessing of Protection].Cooldown}<=0 && ${Me.CurrentMana}>${Spell[Blessing of Protection].Mana} && !${Me.Buff[Forbearance](exists)} { Cast "Blessing of Protection" This:Echo["[Shield] Blessing of Protection"] } } elseif ${Me.PctHPs}<${This.MinBattleHeal} && !${Me.Casting} && ${Me.PctHPs} < 100 && ${Me.CurrentMana}>${Spell[Holy Light].Mana} && ${Spell[Holy Light](exists)} { This:Echo["[Heal] Casting Holy Light"] Cast "Holy Light" } elseif ${Spell[Flash of Light](exists)} { if ${Me.PctHPs}<${This.MinBattleHeal} && !${Me.Casting} && ${Me.PctHPs} < 100 && ${Me.CurrentMana}>${Spell[Flash of Light].Mana} && ${Me.CurrentMana}<${Spell[Holy Light].Mana} { This:Echo["[Heal] Casting Flash of Light"] Cast "Flash of Light" } } elseif ${Me.PctHPs} > 90 { This:Echo["[Heal] Interrupted Healing"] WoWScript SpellStopCasting() } } member NeedSealOfCrusader() { { if ${Spell["Seal of the Crusader"](exists)} && !${Me.Buff["Seal of the Crusader"](exists)} && !${Me.Buff["Seal of Righteousness"](exists)} && !${Target.Buff["Judgement of the Crusader"](exists)} { return TRUE } } return FALSE } method SealOfCrusaderPulse() { This:Echo["[Seals] Casting Seal of the Crusader."] This:CastInstantSpell["Seal of the Crusader"] } member NeedJudgement() { if ${Spell["Judgement"](exists)} && ${Me.Buff["Seal of the Crusader"](exists)} && ${JudgeTime} < ${LavishScript.RunningTime} { return TRUE } return FALSE } method JudgementPulse() { This:Echo["[Seals] Casting Judgement."] Cast "Judgement" } member NeedSealofRighteousness() { if ${Spell["Seal of Righteousness"](exists)} && !${Me.Buff["Seal of the Crusader"](exists)} && !${Me.Buff["Seal of Righteousness"](exists)} { return TRUE } return FALSE } method SealofRighteousnessPulse() { This:Echo["[Seals] Casting Seal of Righteousness"] Cast "Seal of Righteousness" } member NeedInterrupt() { if ${WoWScript[UnitCastingInfo("playertarget")].NotEqual[NULL]} && ${Spell[Arcane Torrent](exists)} && !${Spell[Arcane Torrent].Cooldown} && ${This.Interrupt} == 1 { return TRUE } elseif ${WoWScript[UnitCastingInfo("playertarget")].NotEqual[NULL]} && !${Spell[${This.InterruptSpell}].Cooldown} && ${This.Interrupt} == 1 { return TRUE } return FALSE } method InterruptPulse() { if ${WoWScript[UnitCastingInfo("playertarget")].NotEqual[NULL]} && ${Spell[Arcane Torrent](exists)} && !${Spell[Arcane Torrent].Cooldown} && ${This.Interrupt} == 1 { This:Echo["[Interupt] Casting Arcane Torrent!!"] Cast "Arcane Torrent" } elseif ${WoWScript[UnitCastingInfo("playertarget")].NotEqual[NULL]} && !${Spell[${This.InterruptSpell}].Cooldown} && ${This.Interrupt} == 1 { This:Echo["[Interupt] Casting ${This.InterruptSpell}!!"] Cast "${This.InterruptSpell}" } } method Routine() { if ${Me.InCombat} && ${Me.HoldingBreath} { WoWPress Jump } elseif ${This.NeedHealing} { This:SetStatus["HEALING"] This:HealingPulse } elseif ${This.NeedCure} { This:SetStatus["CURE"] This:CurePulse } elseif ${This.NeedBuff} { This:SetStatus["BUFF"] This:BuffPulse } elseif !${Me.Attacking} && ${Target.Distance} < 6 && !${Me.Casting} { This:SetStatus["MELEE"] WoWScript AttackTarget() } if ${This.JudgeTime} < ${LavishScript.RunningTime} { if ${This.RoutineType} == 1 { if ${This.NeedSealOfCrusader} { This:SetStatus["SEAL"] This:SealOfCrusaderPulse } elseif ${This.NeedJudgement} { This:SetStatus["SEAL"] This:JudgementPulse } elseif ${This.NeedSealofRighteousness} { This:SetStatus["SEAL"] This:SealofRighteousnessPulse } } elseif ${This.RoutineType} == 2 { This:Echo["Protection"] if !${Me.Buff[Seal of Light](exists)} && !${Me.Buff[Seal of Wisdom](exists)} && !${Me.Buff[Seal of the Crusader](exists)} && !${Me.Buff[Seal of Righteousness](exists)} { if ${Me.PctHPs}<=40 && ${Spell[Seal of Light](exists)} { Cast "Seal of Light" } elseif ${Me.PctMana}<=30 && ${Spell[Seal of Wisdom](exists)} { Cast "Seal of Wisdom" } elseif !${Target.Buff[Judgement of the Crusader](exists)} { Cast "Seal of the Crusader" } elseif ${Target.Buff[Judgement of the Crusader](exists)} { Cast "Seal of Righteousness" } } elseif ${Spell[Judgement].Cooldown}<=0 { if ${Me.Buff[Seal of Light](exists)} && !${Target.Buff[Judgement of Light](exists)} { Cast "Judgement" } elseif ${Me.Buff[Seal of Wisdom](exists)} && !${Target.Buff[Judgement of Wisdom](exists)} { Cast "Judgement" } elseif ${Me.Buff[Seal of the Crusader](exists)} || ${Me.Buff[Seal of Righteousness](exists)} { Cast "Judgement" } } elseif ${Target.PctHPs}<20 && ${Spell[Hammer of Wrath](exists)} && ${Spell[Hammer of Wrath].Cooldown}<=0 { Cast "Hammer of Wrath" } } elseif ${This.RoutineType} == 3 && ${Me.PctMana} > 20 { ;This:Echo["Holy"] if !${Me.Buff[Seal of Light](exists)} && !${Me.Buff[Seal of Wisdom](exists)} && !${Me.Buff[Seal of the Crusader](exists)} && !${Me.Buff[Seal of Righteousness](exists)} { if ${Me.PctHPs}<=40 && ${Spell[Seal of Light](exists)} { Cast "Seal of Light" } elseif ${Me.PctMana}<=30 && ${Spell[Seal of Wisdom](exists)} { Cast "Seal of Wisdom" } elseif !${Target.Buff[Judgement of the Crusader](exists)} { Cast "Seal of the Crusader" } elseif ${Target.Buff[Judgement of the Crusader](exists)} { Cast "Seal of Righteousness" } } elseif ${Spell[Judgement].Cooldown}<=0 { if ${Me.Buff[Seal of Light](exists)} && !${Target.Buff[Judgement of Light](exists)} { Cast "Judgement" } elseif ${Me.Buff[Seal of Wisdom](exists)} && !${Target.Buff[Judgement of Wisdom](exists)} { Cast "Judgement" } elseif ${Me.Buff[Seal of the Crusader](exists)} || ${Me.Buff[Seal of Righteousness](exists)} { Cast "Judgement" } } elseif ${Spell[Holy Shock](exists)} && ${Spell[Holy Shock].Cooldown}<=0 { if ${Spell[Divine Favor](exists)} && ${Spell[Devine Favor].Cooldown}<=0 { Cast "Divine Favor" } Cast "Holy Shock" } elseif ${Target.PctHPs}<20 && ${Spell[Hammer of Wrath](exists)} && ${Spell[Hammer of Wrath].Cooldown}<=0 { if ${Spell[Divine Favor](exists)} && ${Spell[Devine Favor].Cooldown}<=0 { Cast "Divine Favor" } Cast "Hammer of Wrath" } } JudgeTime:Set[${LavishScript.RunningTime} + 1000] } elseif ${This.NeedInterrupt} { This:Echo["1"] This:SetStatus["INTERRUPT"] This:InterruptPulse } } /*----CONFIG----*/ method ToonGUIChange(string Action) { switch ${Action} { /** Buff Settings **/ /** Battle Settings **/ case Interrupt if ${UIElement[cmbInterrupt@Battle@Pages@ToonGUI].SelectedItem.Value(exists)} { This.Interrupt:Set[${UIElement[cmbInterrupt@Battle@Pages@ToonGUI].SelectedItem.Value}] } break case minbattleheal if ${UIElement[cmbbattleheal@Battle@Pages@ToonGUI].SelectedItem.Value(exists)} { This.MinBattleHeal:Set[${UIElement[cmbbattleheal@Battle@Pages@ToonGUI].SelectedItem.Value}] } break case PureMelee if ${UIElement[cmbPureMelee@Battle@Pages@ToonGUI].SelectedItem.Value(exists)} { This.PureMelee:Set[${UIElement[cmbPureMelee@Battle@Pages@ToonGUI].SelectedItem.Value}] } break /** Generic **/ case RepairPct if ${UIElement[cmbRepairPct@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.RepairPct:Set[${UIElement[cmbRepairPct@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case MountDistance if ${UIElement[cmbMountDistance@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.MountDistance:Set[${UIElement[cmbMountDistance@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case minmana if ${UIElement[cmbMinMana@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.MinMana:Set[${UIElement[cmbMinMana@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case maxmana if ${UIElement[cmbMaxMana@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.MaxMana:Set[${UIElement[cmbMaxMana@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case minhealth if ${UIElement[cmbMinHealth@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.MinHealth:Set[${UIElement[cmbMinHealth@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case maxhealth if ${UIElement[cmbMaxHealth@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.MaxHealth:Set[${UIElement[cmbMaxHealth@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case levelbelow if ${UIElement[cmbLevelBelow@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.LevelBelow:Set[${UIElement[cmbLevelBelow@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case levelabove if ${UIElement[cmbLevelAbove@Generic@Pages@ToonGUI].SelectedItem.Value(exists)} { This.LevelAbove:Set[${UIElement[cmbLevelAbove@Generic@Pages@ToonGUI].SelectedItem.Value}] } break case defaultgeneric break } } /* * Config */ method LoadConfig() { This.Interrupt:Set[${This.ToonConfig.FindSetting["Interrupt",1]}] This.MountDistance:Set[${This.ToonConfig.FindSetting["MountDistance",90]}] This.RepairPct:Set[${This.ToonConfig.FindSetting["RepairPct",0]}] This.CorpseCampLimit:Set[${This.ToonConfig.FindSetting["CorpseCampLimit",3]}] This.SpamSpell:Set[${This.ToonConfig.FindSetting["SpamSpell","Frost Shock"]}] This.MinBattleHeal:Set[${This.ToonConfig.FindSetting["MinBattleHeal",20]}] This.PureMelee:Set[${This.ToonConfig.FindSetting["PureMelee",5]}] This.MinMana:Set[${This.ToonConfig.FindSetting["MinMana",0]}] This.MaxMana:Set[${This.ToonConfig.FindSetting["MaxMana",90]}] This.MinHealth:Set[${This.ToonConfig.FindSetting["MinHealth",20]}] This.MaxHealth:Set[${This.ToonConfig.FindSetting["MaxHealth",90]}] This.LevelBelow:Set[${This.ToonConfig.FindSetting["LevelBelow",8]}] This.LevelAbove:Set[${This.ToonConfig.FindSetting["LevelAbove",2]}] This:Echo["Loaded Config!"] } method SaveConfig() { This.ToonConfig.FindSetting["Interrupt"]:Set[${This.Interrupt}] This.ToonConfig.FindSetting["MountDistance"]:Set[${This.MountDistance}] This.ToonConfig.FindSetting["RepairPct"]:Set[${This.RepairPct}] This.ToonConfig.FindSetting["CorpseCampLimit"]:Set[${This.CorpseCampLimit}] This.ToonConfig.FindSetting["SpamSpell"]:Set[${This.SpamSpell}] This.ToonConfig.FindSetting["PureMelee"]:Set[${This.PureMelee}] This.ToonConfig.FindSetting["MinBattleHeal"]:Set[${This.MinBattleHeal}] This.ToonConfig.FindSetting["MinMana"]:Set[${This.MinMana}] This.ToonConfig.FindSetting["MaxMana"]:Set[${This.MaxMana}] This.ToonConfig.FindSetting["MinHealth"]:Set[${This.MinHealth}] This.ToonConfig.FindSetting["MaxHealth"]:Set[${This.MaxHealth}] This.ToonConfig.FindSetting["LevelBelow"]:Set[${This.LevelBelow}] This.ToonConfig.FindSetting["LevelAbove"]:Set[${This.LevelAbove}] This:Echo["Saved Config!"] } /* * */ method InitPaladinGui(string tab) { variable int i = 1 /** Buffs **/ /** Battle **/ for (i:Set[1] ; ${i}<=${UIElement[cmbInterrupt@Battle@Pages@ToonGUI].Items} ; i:Inc) { if ${This.Interrupt} == ${UIElement[cmbInterrupt@Battle@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbInterrupt@Battle@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbMinBattleHeal@Battle@Pages@ToonGUI].Items} ; i:Inc) { if ${This.MinBattleHeal} == ${UIElement[cmbMinBattleHeal@Battle@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbMinBattleHeal@Battle@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbPureMelee@Battle@Pages@ToonGUI].Items} ; i:Inc) { if ${This.PureMelee} == ${UIElement[cmbPureMelee@Battle@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbPureMelee@Battle@Pages@ToonGUI]:SelectItem[${i}] } } /** Generic **/ for (i:Set[1] ; ${i}<=${UIElement[cmbRepairPct@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.RepairPct} == ${UIElement[cmbRepairPct@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbRepairPct@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbMountDistance@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.MountDistance} == ${UIElement[cmbMountDistance@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbMountDistance@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbMinMana@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.MinMana} == ${UIElement[cmbMinMana@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbMinMana@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbMaxMana@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.MaxMana} == ${UIElement[cmbMaxMana@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbMaxMana@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbMinHealth@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.MinHealth} == ${UIElement[cmbMinHealth@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbMinHealth@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbMaxHealth@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.MaxHealth} == ${UIElement[cmbMaxHealth@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbMaxHealth@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbLevelBelow@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.LevelBelow} == ${UIElement[cmbLevelBelow@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbLevelBelow@Generic@Pages@ToonGUI]:SelectItem[${i}] } } for (i:Set[1] ; ${i}<=${UIElement[cmbLevelAbove@Generic@Pages@ToonGUI].Items} ; i:Inc) { if ${This.LevelAbove} == ${UIElement[cmbLevelAbove@Generic@Pages@ToonGUI].Item[${i}].Value} { UIElement[cmbLevelAbove@Generic@Pages@ToonGUI]:SelectItem[${i}] } } } method InitToon() { LavishScript:RegisterEvent[TOON_GUI_CHANGE] Event[TOON_GUI_CHANGE]:AttachAtom[${This.ObjectName}:ToonGUIChange] This:InitPaladinGui[] This:Echo["Azeroth's Paladin Routine ${Version}"] if ${This.RoutineType} == 1 { This.Blessing:Set["Devotion Aura"] This.Aura:Set["Blessing of Wisdom"] } elseif ${This.RoutineType} == 2 { This.Blessing:Set["Retribution Aura"] This.Aura:Set["Blessing of Sanctuary"] } elseif ${This.RoutineType} == 3 { This.Blessing:Set["Retribution Aura"] This.Aura:Set["Blessing of Wisdom"] } } method Shutdown() { This:SaveConfig LavishSettings["Class"]:Export["etc/class.xml"] Event[UI_ERROR_MESSAGE]:DetachAtom[${This.ObjectName}:ErrorMessage] Event[TOON_GUI_VISIBLE]:Unregister /* b7731 */ Event[TOON_GUI_CHANGE]:DetachAtom[${This.ObjectName}:ToonGUIChange] Event[TOON_GUI_CHANGE]:Unregister /* b7731 */ ui -unload "class/${Me.Class}.xml" } method Echo(string Text) { if ${UIElement[ConsoleGUI](exists)} { UIElement[Console@Console@Pages@ToonGUI]:Echo["${Time.Time24} ${Text.Escape}"] } else { echo "${Time.Time24} ${Text}" } } method SetStatus(string Text) { UIElement[Status@Console@Pages@ToonGUI]:SetText[${Text.Escape}] } }