HR.RightSuggestedIconFrame:SetPoint("BOTTOM",HR.MainIconFrame,"RIGHT",HR.LeftIconFrame:GetWidth()/2,HR.LeftIconFrame:GetHeight()/2+(HR.GUISettings.General.BlackBorderIconand3*Multiplieror4*Multiplier));-- todo matt fix this location
CreatePanelOption("Slider",CP_General,"General.SetAlpha",{0,1,0.05},"Addon Alpha","Change the addon's alpha setting.");
CreatePanelOption("Button",CP_General,"ButtonMove","Lock/Unlock","Enable the moving of the frames.",function()HR.MainFrame:ToggleLock();end);
CreatePanelOption("Button",CP_General,"ButtonReset","Reset Buttons","Resets the anchor of buttons.",function()HR.ToggleIconFrame:ResetAnchor();end);
end
localCP_Scaling=GUI.GetPanelByName("Scaling")
ifCP_Scalingthen
CreatePanelOption("Slider",CP_Scaling,"Scaling.ScaleUI",{0.5,5,0.1},"UI Scale","Scale of the Icons.",function(value)HR.MainFrame:ResizeUI(value);end);
CreatePanelOption("Slider",CP_Scaling,"Scaling.ScaleButtons",{0.5,5,0.1},"Buttons Scale","Scale of the Buttons.",function(value)HR.MainFrame:ResizeButtons(value);end);
CreatePanelOption("Slider",CP_Scaling,"Scaling.ScaleHotkey",{0.5,5,0.1},"Hotkey Scale","Scale of the Hotkeys.");
end
-- Modules
C_Timer.After(2,function()
HR.MainFrame:UnregisterEvent("ADDON_LOADED");
HR.PulsePreInit();
HR.PulseInit();
end
);
end
end
end
);
--- ======= MAIN =======
functionHR.PulsePreInit()
HR.MainFrame:Lock();
end
localEnabledRotation={
-- Death Knight
[250]="HeroRotation_DeathKnight",-- Blood
[251]="HeroRotation_DeathKnight",-- Frost
[252]="HeroRotation_DeathKnight",-- Unholy
-- Demon Hunter
[577]="HeroRotation_DemonHunter",-- Havoc
[581]="HeroRotation_DemonHunter",-- Vengeance
-- Druid
[102]="HeroRotation_Druid",-- Balance
[103]="HeroRotation_Druid",-- Feral
[104]="HeroRotation_Druid",-- Guardian
--[105] = "HeroRotation_Druid", -- Restoration
-- Evoker
[1467]="HeroRotation_Evoker",-- Devastation
--[1468] = "HeroRotation_Evoker", -- Preservation
-- Hunter
[253]="HeroRotation_Hunter",-- Beast Mastery
[254]="HeroRotation_Hunter",-- Marksmanship
[255]="HeroRotation_Hunter",-- Survival
-- Mage
[62]="HeroRotation_Mage",-- Arcane
--[63] = "HeroRotation_Mage", -- Fire
[64]="HeroRotation_Mage",-- Frost
-- Monk
--[268] = "HeroRotation_Monk", -- Brewmaster
[269]="HeroRotation_Monk",-- Windwalker
--[270] = "HeroRotation_Monk", -- Mistweaver
-- Paladin
--[65] = "HeroRotation_Paladin", -- Holy
[66]="HeroRotation_Paladin",-- Protection
[70]="HeroRotation_Paladin",-- Retribution
-- Priest
--[256] = "HeroRotation_Priest", -- Discipline
--[257] = "HeroRotation_Priest", -- Holy
[258]="HeroRotation_Priest",-- Shadow
-- Rogue
[259]="HeroRotation_Rogue",-- Assassination
[260]="HeroRotation_Rogue",-- Outlaw
[261]="HeroRotation_Rogue",-- Subtlety
-- Shaman
[262]="HeroRotation_Shaman",-- Elemental
[263]="HeroRotation_Shaman",-- Enhancement
--[264] = "HeroRotation_Shaman", -- Restoration
-- Warlock
[265]="HeroRotation_Warlock",-- Affliction
[266]="HeroRotation_Warlock",-- Demonology
[267]="HeroRotation_Warlock",-- Destruction
-- Warrior
[71]="HeroRotation_Warrior",-- Arms
[72]="HeroRotation_Warrior",-- Fury
[73]="HeroRotation_Warrior"-- Protection
};
localLatestSpecIDChecked=0;
functionHR.PulseInit()
localSpec=GetSpecialization();
-- Delay by 1 second until the WoW API returns a valid value.
ifSpec==nilthen
HL.PulseInitialized=false;
C_Timer.After(1,function()
HR.PulseInit();
end
);
else
-- Force a refresh from the Core
-- TODO: Make it a function instead of copy/paste from Core Events.lua
HR.Print("It looks like enemy nameplates are disabled. This may cause the addon to operate incorrectly, leading to incorrect or missing spell suggestions.");
HR.Print("No Rotation found for this class/spec (SpecID: "..SpecID.."), addon disabled. This is likely due to the rotation being unsupported at this time. Please check supported rotations here: https://github.com/herotc/hero-rotation#supported-rotations");