diff --git a/HealBotBlue.toc b/HealBotBlue.toc
index 95b3e63..a12fee4 100644
--- a/HealBotBlue.toc
+++ b/HealBotBlue.toc
@@ -1,6 +1,6 @@
## Interface: 11200
## Title: HealBotBlue
-## Version: 1.2
+## Version: 1.3
## Author: Bluewhale
## Notes: Adds panel with skinable bars for healing and decursive
## SavedVariables: HealBot_Config
@@ -13,3 +13,11 @@ HealBot_Model.lua
HealBot.xml
HealBot_Action.xml
HealBot_Options.xml
+HealBot_Options_General.xml
+HealBot_Options_Spells.xml
+HealBot_Options_Healing.xml
+HealBot_Options_CDC.xml
+HealBot_Options_Skins.xml
+HealBot_Options_Buffs.xml
+HealBot_Options_Chat.xml
+
diff --git a/HealBot_Localization.en.lua b/HealBot_Localization.en.lua
index 3b0f439..59c2f57 100644
--- a/HealBot_Localization.en.lua
+++ b/HealBot_Localization.en.lua
@@ -1,4 +1,4 @@
-HEALBOT_VERSION = "1.2";
+HEALBOT_VERSION = "1.3";
-------------
-- ENGLISH --
diff --git a/HealBot_Options.lua b/HealBot_Options.lua
index 6a1d596..7c8ffd9 100644
--- a/HealBot_Options.lua
+++ b/HealBot_Options.lua
@@ -1,4 +1,27 @@
-local HealBot_Options_ComboButtons_Button=1;
+-- HealBot Options panel file: HealBot_Options.lua
+-- Split from original HealBot_Options.lua
+
+HealBot_Options_ComboButtons_Button=1;
+
+HealBot_ColourObjWaiting = nil
+
+HealBot_Options_EmergencyFilter_List = {
+ HEALBOT_OPTIONS_MONITORNO,
+ HEALBOT_OPTIONS_MONITORALL,
+ HEALBOT_DRUID,
+ HEALBOT_HUNTER,
+ HEALBOT_MAGE,
+ HEALBOT_PALADIN,
+ HEALBOT_PRIEST,
+ HEALBOT_ROGUE,
+ HEALBOT_SHAMAN,
+ HEALBOT_WARLOCK,
+ HEALBOT_WARRIOR,
+ HEALBOT_OPTIONS_MONITORMELEE,
+ HEALBOT_OPTIONS_MONITORRANGE,
+ HEALBOT_OPTIONS_MONITORHEALERS,
+ HEALBOT_OPTIONS_MONITORCUSTOM,
+}
function HealBot_Options_AddDebug(msg)
HealBot_AddDebug("Options: " .. msg);
@@ -44,454 +67,52 @@ function HealBot_Options_Pct_OnValueChanged(this)
end
-function HealBot_Options_NewSkin_OnTextChanged(this)
- local text= this:GetText()
- if string.len(text)>0 then
- HealBot_Options_NewSkinb:Enable();
- else
- HealBot_Options_NewSkinb:Disable();
- end
-end
-function HealBot_Options_NewSkinb_OnClick(this)
- HealBot_Config.numcols[HealBot_Options_NewSkin:GetText()] = HealBot_Config.numcols[HealBot_Config.Current_Skin]
- HealBot_Config.btexture[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btexture[HealBot_Config.Current_Skin]
- HealBot_Config.bcspace[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bcspace[HealBot_Config.Current_Skin]
- HealBot_Config.brspace[HealBot_Options_NewSkin:GetText()] = HealBot_Config.brspace[HealBot_Config.Current_Skin]
- HealBot_Config.bwidth[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bwidth[HealBot_Config.Current_Skin]
- HealBot_Config.bheight[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bheight[HealBot_Config.Current_Skin]
- HealBot_Config.btextenabledcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcolr[HealBot_Config.Current_Skin]
- HealBot_Config.btextenabledcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcolg[HealBot_Config.Current_Skin]
- HealBot_Config.btextenabledcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcolb[HealBot_Config.Current_Skin]
- HealBot_Config.btextenabledcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcola[HealBot_Config.Current_Skin]
- HealBot_Config.btextdisbledcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcolr[HealBot_Config.Current_Skin]
- HealBot_Config.btextdisbledcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcolg[HealBot_Config.Current_Skin]
- HealBot_Config.btextdisbledcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcolb[HealBot_Config.Current_Skin]
- HealBot_Config.btextdisbledcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcola[HealBot_Config.Current_Skin]
- HealBot_Config.btextcursecolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecolr[HealBot_Config.Current_Skin]
- HealBot_Config.btextcursecolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecolg[HealBot_Config.Current_Skin]
- HealBot_Config.btextcursecolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecolb[HealBot_Config.Current_Skin]
- HealBot_Config.btextcursecola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecola[HealBot_Config.Current_Skin]
- HealBot_Config.backcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcola[HealBot_Config.Current_Skin]
- HealBot_Config.Barcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.Barcola[HealBot_Config.Current_Skin]
- HealBot_Config.BarcolaInHeal[HealBot_Options_NewSkin:GetText()] = HealBot_Config.BarcolaInHeal[HealBot_Config.Current_Skin]
- HealBot_Config.backcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcolr[HealBot_Config.Current_Skin]
- HealBot_Config.backcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcolg[HealBot_Config.Current_Skin]
- HealBot_Config.backcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcolb[HealBot_Config.Current_Skin]
- HealBot_Config.borcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcolr[HealBot_Config.Current_Skin]
- HealBot_Config.borcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcolg[HealBot_Config.Current_Skin]
- HealBot_Config.borcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcolb[HealBot_Config.Current_Skin]
- HealBot_Config.borcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcola[HealBot_Config.Current_Skin]
- HealBot_Config.btextheight[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextheight[HealBot_Config.Current_Skin]
- HealBot_Config.bardisa[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bardisa[HealBot_Config.Current_Skin]
- HealBot_Config.abortsize[HealBot_Options_NewSkin:GetText()] = HealBot_Config.abortsize[HealBot_Config.Current_Skin]
- HealBot_Config.babortcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcolr[HealBot_Config.Current_Skin]
- HealBot_Config.babortcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcolg[HealBot_Config.Current_Skin]
- HealBot_Config.babortcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcolb[HealBot_Config.Current_Skin]
- HealBot_Config.babortcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcola[HealBot_Config.Current_Skin]
- HealBot_Config.ShowHeader[HealBot_Options_NewSkin:GetText()] = HealBot_Config.ShowHeader[HealBot_Config.Current_Skin]
- table.insert(HealBot_Skins,2,HealBot_Options_NewSkin:GetText())
- HealBot_Config.Skin_ID = 2;
- HealBot_Config.Skins = HealBot_Skins; HealBot_Config.Current_Skin = HealBot_Options_NewSkin:GetText();
- HealBot_Options_SetSkins()
- HealBot_Options_NewSkin:SetText("")
-end
-function HealBot_Options_DeleteSkin_OnClick(this)
- if HealBot_Config.Current_Skin~=HEALBOT_SKINS_STD then
- HealBot_Config.numcols[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btexture[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.bcspace[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.brspace[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.bwidth[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.bheight[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextenabledcolr[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextenabledcolg[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextenabledcolb[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextenabledcola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextdisbledcolr[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextdisbledcolg[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextdisbledcolb[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextdisbledcola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextcursecolr[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextcursecolg[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextcursecolb[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextcursecola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.backcola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.Barcola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.BarcolaInHeal[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.backcolr[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.backcolg[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.backcolb[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.borcolr[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.borcolg[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.borcolb[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.borcola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.btextheight[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.bardisa[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.abortsize[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.babortcolr[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.babortcolg[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.babortcolb[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.babortcola[HealBot_Options_SkinsText:GetText()] = nil
- HealBot_Config.ShowHeader[HealBot_Options_SkinsText:GetText()] = nil
- table.remove(HealBot_Skins,HealBot_Config.Skin_ID)
- HealBot_Config.Skin_ID = 1;
- HealBot_Config.Skins = HealBot_Skins;
- HealBot_Config.Current_Skin = HEALBOT_SKINS_STD;
- HealBot_Options_SetSkins()
- end
-end
-function HealBot_Options_ShowHeaders_OnLoad(this)
- getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_SHOWHEADERS);
-end
-
-function HealBot_Options_ShowHeaders_OnClick(this)
- HealBot_Config.ShowHeader[HealBot_Config.Current_Skin] = this:GetChecked();
- HealBot_Action_ResetSkin()
-end
-function HealBot_Options_BarTextureS_OnValueChanged(this)
- HealBot_Config.btexture[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarHeightS_OnValueChanged(this)
- HealBot_Config.bheight[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarWidthS_OnValueChanged(this)
- HealBot_Config.bwidth[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarNumColsS_OnValueChanged(this)
- HealBot_Config.numcols[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarBRSpaceS_OnValueChanged(this)
- HealBot_Config.brspace[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarBCSpaceS_OnValueChanged(this)
- HealBot_Config.bcspace[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_FontHeight_OnValueChanged(this)
- HealBot_Config.btextheight[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_AbortBarSize_OnValueChanged(this)
- HealBot_Config.abortsize[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_ActionAlpha_OnValueChanged(this)
- HealBot_Config.backcola[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
-end
-
-function HealBot_Options_BarAlpha_OnValueChanged(this)
- HealBot_Config.Barcola[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarAlphaInHeal_OnValueChanged(this)
- HealBot_Config.BarcolaInHeal[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BarAlphaDis_OnValueChanged(this)
- HealBot_Config.bardisa[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
- HealBot_Action_ResetSkin()
-end
-
-local HealBot_ColourObjWaiting
-function HealBot_SkinColorpick_OnClick(SkinType)
- HealBot_ColourObjWaiting=SkinType;
-
- if SkinType=="En" then
- HealBot_UseColourPick(HealBot_Config.btextenabledcolr[HealBot_Config.Current_Skin],
- HealBot_Config.btextenabledcolg[HealBot_Config.Current_Skin],
- HealBot_Config.btextenabledcolb[HealBot_Config.Current_Skin],
- HealBot_Config.btextenabledcola[HealBot_Config.Current_Skin]);
- elseif SkinType=="Dis" then
- HealBot_UseColourPick(HealBot_Config.btextdisbledcolr[HealBot_Config.Current_Skin],
- HealBot_Config.btextdisbledcolg[HealBot_Config.Current_Skin],
- HealBot_Config.btextdisbledcolb[HealBot_Config.Current_Skin],
- HealBot_Config.btextdisbledcola[HealBot_Config.Current_Skin])
- elseif SkinType=="Debuff" then
- HealBot_UseColourPick(HealBot_Config.btextcursecolr[HealBot_Config.Current_Skin],
- HealBot_Config.btextcursecolg[HealBot_Config.Current_Skin],
- HealBot_Config.btextcursecolb[HealBot_Config.Current_Skin],
- HealBot_Config.btextcursecola[HealBot_Config.Current_Skin])
- elseif SkinType=="Back" then
- HealBot_UseColourPick(HealBot_Config.backcolr[HealBot_Config.Current_Skin],
- HealBot_Config.backcolg[HealBot_Config.Current_Skin],
- HealBot_Config.backcolb[HealBot_Config.Current_Skin],
- HealBot_Config.backcola[HealBot_Config.Current_Skin])
- elseif SkinType=="Bor" then
- HealBot_UseColourPick(HealBot_Config.borcolr[HealBot_Config.Current_Skin],
- HealBot_Config.borcolg[HealBot_Config.Current_Skin],
- HealBot_Config.borcolb[HealBot_Config.Current_Skin],
- HealBot_Config.borcola[HealBot_Config.Current_Skin])
- elseif SkinType=="Abort" then
- HealBot_UseColourPick(HealBot_Config.babortcolr[HealBot_Config.Current_Skin],
- HealBot_Config.babortcolg[HealBot_Config.Current_Skin],
- HealBot_Config.babortcolb[HealBot_Config.Current_Skin],
- HealBot_Config.babortcola[HealBot_Config.Current_Skin])
- end
-end
-
-function HealBot_SetSkinColours()
- local btextheight=HealBot_Config.btextheight[HealBot_Config.Current_Skin] or 10;
-
- HealBot_EnTextColorpick:SetStatusBarColor(0,1,0,HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
- HealBot_EnTextColorpickin:SetStatusBarColor(0,1,0,HealBot_Config.Barcola[HealBot_Config.Current_Skin]*HealBot_Config.BarcolaInHeal[HealBot_Config.Current_Skin]);
- HealBot_DisTextColorpick:SetStatusBarColor(0,1,0,HealBot_Config.bardisa[HealBot_Config.Current_Skin]);
- HealBot_EnTextColorpickt:SetTextColor(
- HealBot_Config.btextenabledcolr[HealBot_Config.Current_Skin],
- HealBot_Config.btextenabledcolg[HealBot_Config.Current_Skin],
- HealBot_Config.btextenabledcolb[HealBot_Config.Current_Skin],
- HealBot_Config.btextenabledcola[HealBot_Config.Current_Skin]);
- HealBot_DisTextColorpickt:SetTextColor(
- HealBot_Config.btextdisbledcolr[HealBot_Config.Current_Skin],
- HealBot_Config.btextdisbledcolg[HealBot_Config.Current_Skin],
- HealBot_Config.btextdisbledcolb[HealBot_Config.Current_Skin],
- HealBot_Config.btextdisbledcola[HealBot_Config.Current_Skin]);
- HealBot_DebTextColorpickt:SetTextColor(
- HealBot_Config.btextcursecolr[HealBot_Config.Current_Skin],
- HealBot_Config.btextcursecolg[HealBot_Config.Current_Skin],
- HealBot_Config.btextcursecolb[HealBot_Config.Current_Skin],
- HealBot_Config.btextcursecola[HealBot_Config.Current_Skin]);
- HealBot_BackgroundColorpick:SetStatusBarColor(
- HealBot_Config.backcolr[HealBot_Config.Current_Skin],
- HealBot_Config.backcolg[HealBot_Config.Current_Skin],
- HealBot_Config.backcolb[HealBot_Config.Current_Skin],
- HealBot_Config.backcola[HealBot_Config.Current_Skin]);
- HealBot_BorderColorpick:SetStatusBarColor(
- HealBot_Config.borcolr[HealBot_Config.Current_Skin],
- HealBot_Config.borcolg[HealBot_Config.Current_Skin],
- HealBot_Config.borcolb[HealBot_Config.Current_Skin],
- HealBot_Config.borcola[HealBot_Config.Current_Skin]);
- HealBot_AbortColorpick:SetStatusBarColor(
- HealBot_Config.babortcolr[HealBot_Config.Current_Skin],
- HealBot_Config.babortcolg[HealBot_Config.Current_Skin],
- HealBot_Config.babortcolb[HealBot_Config.Current_Skin],
- HealBot_Config.babortcola[HealBot_Config.Current_Skin]);
-
- local borderStyle = HealBot_Config.bborder[HealBot_Config.Current_Skin] or 2
- if borderStyle == 0 then
- HealBot_Action:SetBackdropBorderColor(0,0,0,0);
- elseif borderStyle == 1 then
- local bboffset = (HealBot_Config.bboffset and HealBot_Config.bboffset[HealBot_Config.Current_Skin]) or 1
- local bpadding = (HealBot_Config.bpadding and HealBot_Config.bpadding[HealBot_Config.Current_Skin]) or 10
- HealBot_Action:SetBackdrop({
- bgFile = "Interface\\Tooltips\\UI-Tooltip-Background",
- edgeFile = "Interface\\Buttons\\WHITE8X8",
- tile = true, tileSize = 8, edgeSize = bboffset,
- insets = { left = bpadding, right = bpadding, top = bpadding, bottom = bpadding }
- })
- HealBot_Action:SetBackdropColor(
- HealBot_Config.backcolr[HealBot_Config.Current_Skin],
- HealBot_Config.backcolg[HealBot_Config.Current_Skin],
- HealBot_Config.backcolb[HealBot_Config.Current_Skin],
- HealBot_Config.backcola[HealBot_Config.Current_Skin]);
- HealBot_Action:SetBackdropBorderColor(
- HealBot_Config.borcolr[HealBot_Config.Current_Skin],
- HealBot_Config.borcolg[HealBot_Config.Current_Skin],
- HealBot_Config.borcolb[HealBot_Config.Current_Skin],
- HealBot_Config.borcola[HealBot_Config.Current_Skin]);
- else
- HealBot_Action:SetBackdrop({
- bgFile = "Interface\\Tooltips\\UI-Tooltip-Background",
- edgeFile = "Interface\\Tooltips\\UI-Tooltip-Border",
- tile = true, tileSize = 8, edgeSize = 16,
- insets = { left = 4, right = 4, top = 4, bottom = 4 }
- })
- HealBot_Action:SetBackdropColor(
- HealBot_Config.backcolr[HealBot_Config.Current_Skin],
- HealBot_Config.backcolg[HealBot_Config.Current_Skin],
- HealBot_Config.backcolb[HealBot_Config.Current_Skin],
- HealBot_Config.backcola[HealBot_Config.Current_Skin]);
- HealBot_Action:SetBackdropBorderColor(
- HealBot_Config.borcolr[HealBot_Config.Current_Skin],
- HealBot_Config.borcolg[HealBot_Config.Current_Skin],
- HealBot_Config.borcolb[HealBot_Config.Current_Skin],
- HealBot_Config.borcola[HealBot_Config.Current_Skin]);
- end
-
- HealBot_EnTextColorpickt:SetTextHeight(btextheight);
- HealBot_DisTextColorpickt:SetTextHeight(btextheight);
- HealBot_DebTextColorpickt:SetTextHeight(btextheight);
- HealBot_EnTextColorpickt:SetText(HEALBOT_SKIN_ENTEXT);
- HealBot_DisTextColorpickt:SetText(HEALBOT_SKIN_DISTEXT);
- HealBot_DebTextColorpickt:SetText(HEALBOT_SKIN_DEBTEXT);
- local barScale = HealBot_EnTextColorpick:GetScale();
- HealBot_EnTextColorpick:SetScale(barScale + 0.01);
- HealBot_EnTextColorpick:SetScale(barScale);
- HealBot_DisTextColorpick:SetScale(barScale + 0.01);
- HealBot_DisTextColorpick:SetScale(barScale);
- HealBot_DebTextColorpick:SetScale(barScale + 0.01);
- HealBot_DebTextColorpick:SetScale(barScale);
-
- HealBot_Action_PartyChanged()
-end
-
-function HealBot_Options_AlertLevel_OnValueChanged(this)
- HealBot_Config.AlertLevel = HealBot_Options_Pct_OnValueChanged(this);
- HealBot_Action_Refresh();
-end
-function HealBot_Options_AutoShow_OnLoad(this)
- getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_AUTOSHOW);
-end
-
-function HealBot_Options_AutoShow_OnClick(this)
- HealBot_Config.AutoClose = this:GetChecked() or 0;
- HealBot_Action_Refresh();
-end
-function HealBot_Options_PanelSounds_OnLoad(this)
- getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_PANELSOUNDS);
-end
-
-function HealBot_Options_PanelSounds_OnClick(this)
- HealBot_Config.PanelSounds = this:GetChecked() or 0;
-end
-
-function HealBot_Options_ActionMouseover_OnLoad(this, text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_ActionMouseover_OnClick(this)
- HealBot_Config.ActionMouseover = this:GetChecked() or 0;
-end
-function HealBot_Options_ActionLocked_OnLoad(this)
- getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_ACTIONLOCKED);
-end
-
-function HealBot_Options_ActionLocked_OnClick(this)
- HealBot_Config.ActionLocked = this:GetChecked() or 0;
-end
-function HealBot_Options_GroupHeals_OnLoad(this,text)
- this.text = text
- getglobal(this:GetName().."Text"):SetText(text);
-end
-function HealBot_Options_GroupHeals_OnClick(this)
- HealBot_Config.GroupHeals = this:GetChecked() or 0;
- HealBot_RecalcParty();
-end
-function HealBot_Options_TankHeals_OnLoad(this,text)
- this.text = text
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_TankHeals_OnClick(this)
- HealBot_Config.TankHeals = this:GetChecked() or 0;
- HealBot_RecalcParty();
-end
-function HealBot_Options_TargetHeals_OnLoad(this,text)
- this.text = text
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_TargetHeals_OnClick(this)
- HealBot_Config.TargetHeals = this:GetChecked() or 0;
- HealBot_RecalcParty();
-end
-function HealBot_Options_EmergencyHeals_OnLoad(this,text)
- this.text = text
- getglobal(this:GetName().."Text"):SetText(text);
-end
-function HealBot_Options_EmergencyHeals_OnClick(this)
- HealBot_Config.EmergencyHeals = this:GetChecked() or 0;
- HealBot_RecalcParty();
-end
-function HealBot_Options_OverHeal_OnValueChanged(this)
- HealBot_Config.OverHeal = HealBot_Options_Pct_OnValueChanged(this);
-end
-function HealBot_Options_EFClass_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-function HealBot_Options_EFClass_OnClick(this)
- if HealBot_Config.EmergencyFClass==1 then
- HealBot_Config.EmergIncMelee[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
- HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
- elseif HealBot_Config.EmergencyFClass==2 then
- HealBot_Config.EmergIncRange[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
- HealBot_Config.EmergIncRange[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
- elseif HealBot_Config.EmergencyFClass==3 then
- HealBot_Config.EmergIncHealers[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
- HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
- elseif HealBot_Config.EmergencyFClass==4 then
- HealBot_Config.EmergIncCustom[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
- HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
- end
- if HealBot_Config.EmergIncMonitor>10 then
- HealBot_Action_PartyChanged();
- end
-end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
function HealBot_Options_CastNotify_OnLoad(this,text)
@@ -502,753 +123,39 @@ function HealBot_Options_CastNotify_OnClick(this,id)
-- CastNotify UI elements were removed and replaced by Custom Chat Messages
end
-function HealBot_ComboButtons_Button_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_ComboButtons_Button_OnClick(this,id)
- if HealBot_Options_ComboButtons_Button>0 then
- getglobal("HealBot_ComboButtons_Button"..HealBot_Options_ComboButtons_Button):SetChecked(nil);
- end
- HealBot_Options_ComboButtons_Button = id;
- if HealBot_Options_ComboButtons_Button>0 then
- getglobal("HealBot_ComboButtons_Button"..HealBot_Options_ComboButtons_Button):SetChecked(1);
- end
- HealBot_Options_ComboClass_Text()
-end
-
-function HealBot_Options_HideOptions_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_HideOptions_OnClick(this)
- HealBot_Config.HideOptions = this:GetChecked() or 0;
- HealBot_Action_PartyChanged();
-end
-
-function HealBot_Options_HideAbort_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_HideAbort_OnClick(this)
- HealBot_Config.HideAbort = this:GetChecked() or 0;
- HealBot_Action_PartyChanged();
-end
-
-function HealBot_Options_ShowTooltip_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_ShowTooltip_OnClick(this)
- HealBot_Config.ShowTooltip = this:GetChecked() or 0;
-end
-
-function HealBot_Options_ShowTooltipTarget_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_ShowTooltipTarget_OnClick(this)
- HealBot_Config.Tooltip_ShowTarget = this:GetChecked() or 0;
-end
-
-function HealBot_Options_ShowTooltipSpellDetail_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_ShowTooltipSpellDetail_OnClick(this)
- HealBot_Config.Tooltip_ShowSpellDetail = this:GetChecked() or 0;
-end
-
-function HealBot_Options_ShowTooltipInstant_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_ShowTooltipInstant_OnClick(this)
- HealBot_Config.Tooltip_Recommend = this:GetChecked() or 0;
-end
-
-function HealBot_Options_ShowDebuffWarning_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_ShowDebuffWarning_OnClick(this)
- HealBot_Config.ShowDebuffWarning = this:GetChecked() or 0;
-end
-
-function HealBot_Options_SoundDebuffWarning_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_SoundDebuffWarning_OnClick(this)
- HealBot_Config.SoundDebuffWarning = this:GetChecked() or 0;
- if HealBot_Config.SoundDebuffWarning==0 then
- HealBot_WarningSound1:Disable();
- HealBot_WarningSound2:Disable();
- HealBot_WarningSound3:Disable();
- else
- HealBot_WarningSound1:Enable();
- HealBot_WarningSound2:Enable();
- HealBot_WarningSound3:Enable();
- end
-end
-
-function HealBot_WarningSound_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_WarningSound_OnClick(this,id)
- if HealBot_Config.SoundDebuffPlay>0 then
- getglobal("HealBot_WarningSound"..HealBot_Config.SoundDebuffPlay):SetChecked(nil);
- end
- HealBot_Config.SoundDebuffPlay = id;
- if HealBot_Config.SoundDebuffPlay>0 then
- getglobal("HealBot_WarningSound"..HealBot_Config.SoundDebuffPlay):SetChecked(1);
- if this then
- HealBot_PlaySound(HealBot_Config.SoundDebuffPlay)
- end
- end
-end
-function HealBot_Options_GrowUpwards_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_GrowUpwards_OnClick(this)
- HealBot_Config.GrowUpwards = this:GetChecked() or 0;
- HealBot_Action_PartyChanged();
-end
-function HealBot_Options_QualityRange_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-function HealBot_Options_QualityRange_OnClick(this)
- HealBot_Config.QualityRange = this:GetChecked() or 0;
- HealBot_Action_PartyChanged();
-end
-function HealBot_Options_ProtectPvP_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-function HealBot_Options_ProtectPvP_OnClick(this)
- HealBot_Config.ProtectPvP = this:GetChecked() or 0;
- HealBot_Action_Refresh();
-end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
-local HealBot_Options_EmergencyFClass_List = {
- HEALBOT_CLASSES_MELEE,
- HEALBOT_CLASSES_RANGES,
- HEALBOT_CLASSES_HEALERS,
- HEALBOT_CLASSES_CUSTOM,
-}
-
-function HealBot_Options_EmergencyFClass_DropDown()
- for i=1, getn(HealBot_Options_EmergencyFClass_List), 1 do
- local info = {};
- info.text = HealBot_Options_EmergencyFClass_List[i];
- info.func = HealBot_Options_EmergencyFClass_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
-end
-
-function HealBot_Options_EmergencyFClass_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_EmergencyFClass,HealBot_Options_EmergencyFClass_DropDown)
-end
-
-function HealBot_Options_EmergencyFClass_Refresh(onselect)
- if not HealBot_Config.EmergencyFClass then return end
- if not onselect then HealBot_Options_EmergencyFClass_Initialize() end -- or wrong menu may be used !
- UIDropDownMenu_SetSelectedID(HealBot_Options_EmergencyFClass,HealBot_Config.EmergencyFClass)
-end
-
-function HealBot_Options_EmergencyFClass_OnLoad(this)
- HealBot_Options_EmergencyFClass_Initialize()
- UIDropDownMenu_SetWidth(100)
-end
-
-function HealBot_Options_EmergencyFClass_OnSelect()
- HealBot_Config.EmergencyFClass = this:GetID()
- HealBot_Options_EmergencyFClass_Refresh(true)
- HealBot_Options_EFClass_Reset()
-end
-
-function HealBot_Options_EFClass_Reset()
- if HealBot_Config.EmergencyFClass==1 then
- HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_DRUID]);
- HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_HUNTER]);
- HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_MAGE]);
- HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_PALADIN]);
- HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_PRIEST]);
- HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_ROGUE]);
- HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN]);
- HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK]);
- HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR]);
- elseif HealBot_Config.EmergencyFClass==2 then
- HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_DRUID]);
- HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_HUNTER]);
- HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_MAGE]);
- HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_PALADIN]);
- HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_PRIEST]);
- HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_ROGUE]);
- HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_SHAMAN]);
- HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_WARLOCK]);
- HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_WARRIOR]);
- elseif HealBot_Config.EmergencyFClass==3 then
- HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_DRUID]);
- HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_HUNTER]);
- HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_MAGE]);
- HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_PALADIN]);
- HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_PRIEST]);
- HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_ROGUE]);
- HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN]);
- HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK]);
- HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR]);
- elseif HealBot_Config.EmergencyFClass==4 then
- HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_DRUID]);
- HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_HUNTER]);
- HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_MAGE]);
- HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_PALADIN]);
- HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_PRIEST]);
- HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_ROGUE]);
- HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN]);
- HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK]);
- HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR]);
- end
-end
-
---------------------------------------------------------------------------------
-
-local HealBot_Options_ExtraSort_List = {
- HEALBOT_SORTBY_NAME,
- HEALBOT_SORTBY_CLASS,
- HEALBOT_SORTBY_GROUP,
- HEALBOT_SORTBY_MAXHEALTH,
-}
-
-function HealBot_Options_ExtraSort_DropDown()
- for i=1, getn(HealBot_Options_ExtraSort_List), 1 do
- local info = {};
- info.text = HealBot_Options_ExtraSort_List[i];
- info.func = HealBot_Options_ExtraSort_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
-end
-
-function HealBot_Options_ExtraSort_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_ExtraSort,HealBot_Options_ExtraSort_DropDown)
-end
-
-function HealBot_Options_ExtraSort_Refresh(onselect)
- if not HealBot_Config.ExtraOrder then return end
- if not onselect then HealBot_Options_ExtraSort_Initialize() end -- or wrong menu may be used !
- UIDropDownMenu_SetSelectedID(HealBot_Options_ExtraSort,HealBot_Config.ExtraOrder)
-end
-
-function HealBot_Options_ExtraSort_OnLoad(this)
- HealBot_Options_ExtraSort_Initialize()
- UIDropDownMenu_SetWidth(100)
-end
-
-function HealBot_Options_ExtraSort_OnSelect()
- HealBot_Config.ExtraOrder = this:GetID()
- HealBot_Options_ExtraSort_Refresh(true)
- HealBot_Action_PartyChanged()
-end
-
---------------------------------------------------------------------------------
-
-local HealBot_Options_EmergencyFilter_List = {
- HEALBOT_CLASSES_ALL,
- HEALBOT_DRUID,
- HEALBOT_HUNTER,
- HEALBOT_MAGE,
- HEALBOT_PALADIN,
- HEALBOT_PRIEST,
- HEALBOT_ROGUE,
- HEALBOT_SHAMAN,
- HEALBOT_WARLOCK,
- HEALBOT_WARRIOR,
- HEALBOT_CLASSES_MELEE,
- HEALBOT_CLASSES_RANGES,
- HEALBOT_CLASSES_HEALERS,
- HEALBOT_CLASSES_CUSTOM,
-}
-
-function HealBot_Options_EmergencyFilter_DropDown()
- for i=1, getn(HealBot_Options_EmergencyFilter_List), 1 do
- local info = {};
- info.text = HealBot_Options_EmergencyFilter_List[i];
- info.func = HealBot_Options_EmergencyFilter_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
-end
-
-function HealBot_Options_CDCMonitor_DropDown()
- for i=1, getn(HealBot_Options_EmergencyFilter_List), 1 do
- local info = {};
- info.text = HealBot_Options_EmergencyFilter_List[i];
- info.func = HealBot_Options_CDCMonitor_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
-end
-
-function HealBot_Options_EmergencyFilter_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_EmergencyFilter,HealBot_Options_EmergencyFilter_DropDown)
-end
-
-function HealBot_Options_CDCMonitor_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_CDCMonitor,HealBot_Options_CDCMonitor_DropDown)
-end
-
-function HealBot_Options_EmergencyFilter_Refresh(onselect)
- if not HealBot_Config.EmergIncMonitor then return end
- if not onselect then HealBot_Options_EmergencyFilter_Initialize() end -- or wrong menu may be used !
- UIDropDownMenu_SetSelectedID(HealBot_Options_EmergencyFilter,HealBot_Config.EmergIncMonitor)
-end
-
-function HealBot_Options_CDCMonitor_Refresh(onselect)
- if not HealBot_Config.CDCMonitor then return end
- if not onselect then HealBot_Options_CDCMonitor_Initialize() end -- or wrong menu may be used !
- UIDropDownMenu_SetSelectedID(HealBot_Options_CDCMonitor,HealBot_Config.CDCMonitor)
-end
-
-function HealBot_Options_EmergencyFilter_OnLoad(this)
- HealBot_Options_EmergencyFilter_Initialize()
- UIDropDownMenu_SetWidth(100)
-end
-
-function HealBot_Options_CDCMonitor_OnLoad(this)
- HealBot_Options_CDCMonitor_Initialize()
- UIDropDownMenu_SetWidth(100)
-end
-
-function HealBot_Options_EmergencyFilter_OnSelect()
- HealBot_Config.EmergIncMonitor = this:GetID()
- HealBot_Options_EmergencyFilter_Refresh(true)
- HealBot_Options_EmergencyFilter_Reset()
-end
-
-function HealBot_Options_EmergencyFilter_Reset()
-
- HealBot_EmergInc[HEALBOT_DRUID] = 0;
- HealBot_EmergInc[HEALBOT_HUNTER] = 0;
- HealBot_EmergInc[HEALBOT_MAGE] = 0;
- HealBot_EmergInc[HEALBOT_PALADIN] = 0;
- HealBot_EmergInc[HEALBOT_PRIEST] = 0;
- HealBot_EmergInc[HEALBOT_ROGUE] = 0;
- HealBot_EmergInc[HEALBOT_SHAMAN] = 0;
- HealBot_EmergInc[HEALBOT_WARLOCK] = 0;
- HealBot_EmergInc[HEALBOT_WARRIOR] = 0;
- if HealBot_Config.EmergIncMonitor==1 then
- HealBot_EmergInc[HEALBOT_DRUID] = 1;
- HealBot_EmergInc[HEALBOT_HUNTER] = 1;
- HealBot_EmergInc[HEALBOT_MAGE] = 1;
- HealBot_EmergInc[HEALBOT_PALADIN] = 1;
- HealBot_EmergInc[HEALBOT_PRIEST] = 1;
- HealBot_EmergInc[HEALBOT_ROGUE] = 1;
- HealBot_EmergInc[HEALBOT_SHAMAN] = 1;
- HealBot_EmergInc[HEALBOT_WARLOCK] = 1;
- HealBot_EmergInc[HEALBOT_WARRIOR] = 1;
- elseif HealBot_Config.EmergIncMonitor==2 then
- HealBot_EmergInc[HEALBOT_DRUID] = 1;
- elseif HealBot_Config.EmergIncMonitor==3 then
- HealBot_EmergInc[HEALBOT_HUNTER] = 1;
- elseif HealBot_Config.EmergIncMonitor==4 then
- HealBot_EmergInc[HEALBOT_MAGE] = 1;
- elseif HealBot_Config.EmergIncMonitor==5 then
- HealBot_EmergInc[HEALBOT_PALADIN] = 1;
- elseif HealBot_Config.EmergIncMonitor==6 then
- HealBot_EmergInc[HEALBOT_PRIEST] = 1;
- elseif HealBot_Config.EmergIncMonitor==7 then
- HealBot_EmergInc[HEALBOT_ROGUE] = 1;
- elseif HealBot_Config.EmergIncMonitor==8 then
- HealBot_EmergInc[HEALBOT_SHAMAN] = 1;
- elseif HealBot_Config.EmergIncMonitor==9 then
- HealBot_EmergInc[HEALBOT_WARLOCK] = 1;
- elseif HealBot_Config.EmergIncMonitor==10 then
- HealBot_EmergInc[HEALBOT_WARRIOR] = 1;
- elseif HealBot_Config.EmergIncMonitor==11 then
- HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncMelee[HEALBOT_DRUID];
- HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncMelee[HEALBOT_HUNTER];
- HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncMelee[HEALBOT_MAGE];
- HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncMelee[HEALBOT_PALADIN];
- HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncMelee[HEALBOT_PRIEST];
- HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncMelee[HEALBOT_ROGUE];
- HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN];
- HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK];
- HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR];
- elseif HealBot_Config.EmergIncMonitor==12 then
- HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncRange[HEALBOT_DRUID];
- HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncRange[HEALBOT_HUNTER];
- HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncRange[HEALBOT_MAGE];
- HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncRange[HEALBOT_PALADIN];
- HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncRange[HEALBOT_PRIEST];
- HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncRange[HEALBOT_ROGUE];
- HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncRange[HEALBOT_SHAMAN];
- HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncRange[HEALBOT_WARLOCK];
- HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncRange[HEALBOT_WARRIOR];
- elseif HealBot_Config.EmergIncMonitor==13 then
- HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncHealers[HEALBOT_DRUID];
- HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncHealers[HEALBOT_HUNTER];
- HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncHealers[HEALBOT_MAGE];
- HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncHealers[HEALBOT_PALADIN];
- HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncHealers[HEALBOT_PRIEST];
- HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncHealers[HEALBOT_ROGUE];
- HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN];
- HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK];
- HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR];
- elseif HealBot_Config.EmergIncMonitor==14 then
- HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncCustom[HEALBOT_DRUID];
- HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncCustom[HEALBOT_HUNTER];
- HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncCustom[HEALBOT_MAGE];
- HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncCustom[HEALBOT_PALADIN];
- HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncCustom[HEALBOT_PRIEST];
- HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncCustom[HEALBOT_ROGUE];
- HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN];
- HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK];
- HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR];
- end
-
- HealBot_Action_PartyChanged()
-end
-
-function HealBot_Options_CDCMonitor_OnSelect()
- HealBot_Config.CDCMonitor = this:GetID()
- HealBot_Options_CDCMonitor_Refresh(true)
- HealBot_Options_CDCMonitor_Reset()
-end
-
-function HealBot_Options_CDCMonitor_Reset()
-
- HealBot_CDCInc[HEALBOT_DRUID] = 0;
- HealBot_CDCInc[HEALBOT_HUNTER] = 0;
- HealBot_CDCInc[HEALBOT_MAGE] = 0;
- HealBot_CDCInc[HEALBOT_PALADIN] = 0;
- HealBot_CDCInc[HEALBOT_PRIEST] = 0;
- HealBot_CDCInc[HEALBOT_ROGUE] = 0;
- HealBot_CDCInc[HEALBOT_SHAMAN] = 0;
- HealBot_CDCInc[HEALBOT_WARLOCK] = 0;
- HealBot_CDCInc[HEALBOT_WARRIOR] = 0;
- if HealBot_Config.CDCMonitor==1 then
- HealBot_CDCInc[HEALBOT_DRUID] = 1;
- HealBot_CDCInc[HEALBOT_HUNTER] = 1;
- HealBot_CDCInc[HEALBOT_MAGE] = 1;
- HealBot_CDCInc[HEALBOT_PALADIN] = 1;
- HealBot_CDCInc[HEALBOT_PRIEST] = 1;
- HealBot_CDCInc[HEALBOT_ROGUE] = 1;
- HealBot_CDCInc[HEALBOT_SHAMAN] = 1;
- HealBot_CDCInc[HEALBOT_WARLOCK] = 1;
- HealBot_CDCInc[HEALBOT_WARRIOR] = 1;
- elseif HealBot_Config.CDCMonitor==2 then
- HealBot_CDCInc[HEALBOT_DRUID] = 1;
- elseif HealBot_Config.CDCMonitor==3 then
- HealBot_CDCInc[HEALBOT_HUNTER] = 1;
- elseif HealBot_Config.CDCMonitor==4 then
- HealBot_CDCInc[HEALBOT_MAGE] = 1;
- elseif HealBot_Config.CDCMonitor==5 then
- HealBot_CDCInc[HEALBOT_PALADIN] = 1;
- elseif HealBot_Config.CDCMonitor==6 then
- HealBot_CDCInc[HEALBOT_PRIEST] = 1;
- elseif HealBot_Config.CDCMonitor==7 then
- HealBot_CDCInc[HEALBOT_ROGUE] = 1;
- elseif HealBot_Config.CDCMonitor==8 then
- HealBot_CDCInc[HEALBOT_SHAMAN] = 1;
- elseif HealBot_Config.CDCMonitor==9 then
- HealBot_CDCInc[HEALBOT_WARLOCK] = 1;
- elseif HealBot_Config.CDCMonitor==10 then
- HealBot_CDCInc[HEALBOT_WARRIOR] = 1;
- elseif HealBot_Config.CDCMonitor==11 then
- HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncMelee[HEALBOT_DRUID];
- HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncMelee[HEALBOT_HUNTER];
- HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncMelee[HEALBOT_MAGE];
- HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncMelee[HEALBOT_PALADIN];
- HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncMelee[HEALBOT_PRIEST];
- HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncMelee[HEALBOT_ROGUE];
- HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN];
- HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK];
- HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR];
- elseif HealBot_Config.CDCMonitor==12 then
- HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncRange[HEALBOT_DRUID];
- HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncRange[HEALBOT_HUNTER];
- HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncRange[HEALBOT_MAGE];
- HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncRange[HEALBOT_PALADIN];
- HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncRange[HEALBOT_PRIEST];
- HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncRange[HEALBOT_ROGUE];
- HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncRange[HEALBOT_SHAMAN];
- HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncRange[HEALBOT_WARLOCK];
- HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncRange[HEALBOT_WARRIOR];
- elseif HealBot_Config.CDCMonitor==13 then
- HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncHealers[HEALBOT_DRUID];
- HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncHealers[HEALBOT_HUNTER];
- HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncHealers[HEALBOT_MAGE];
- HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncHealers[HEALBOT_PALADIN];
- HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncHealers[HEALBOT_PRIEST];
- HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncHealers[HEALBOT_ROGUE];
- HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN];
- HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK];
- HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR];
- elseif HealBot_Config.CDCMonitor==14 then
- HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncCustom[HEALBOT_DRUID];
- HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncCustom[HEALBOT_HUNTER];
- HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncCustom[HEALBOT_MAGE];
- HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncCustom[HEALBOT_PALADIN];
- HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncCustom[HEALBOT_PRIEST];
- HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncCustom[HEALBOT_ROGUE];
- HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN];
- HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK];
- HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR];
- end
-
- HealBot_Action_PartyChanged()
-end
-
---------------------------------------------------------------------------------
-
-function HealBot_Options_Skins_DropDown()
- for i=1, getn(HealBot_Skins), 1 do
- local info = {};
- info.text = HealBot_Skins[i];
- info.func = HealBot_Options_Skins_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
-end
-
-function HealBot_Options_Skins_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_Skins,HealBot_Options_Skins_DropDown)
-end
-
-function HealBot_Options_Skins_Refresh(onselect)
- if not HealBot_Config.Skin_ID then return end
- if not onselect then HealBot_Options_Skins_Initialize() end -- or wrong menu may be used !
- UIDropDownMenu_SetSelectedID(HealBot_Options_Skins,HealBot_Config.Skin_ID)
-end
-
-function HealBot_Options_Skins_OnLoad(this)
- HealBot_Options_Skins_Initialize()
- UIDropDownMenu_SetWidth(100)
-end
-
-function HealBot_Options_Skins_OnSelect()
- HealBot_Config.Skin_ID = this:GetID()
- HealBot_Options_Skins_Refresh(true)
- if this:GetID()>=1 then
- HealBot_Config.Current_Skin = this:GetText()
- HealBot_Options_SetSkins()
- end
-end
-
---------------------------------------------------------------------------------
-
-local HealBot_Options_TooltipPos_List = {
- HEALBOT_TOOLTIP_POSDEFAULT,
- HEALBOT_TOOLTIP_POSLEFT,
- HEALBOT_TOOLTIP_POSRIGHT,
- HEALBOT_TOOLTIP_POSABOVE,
- HEALBOT_TOOLTIP_POSBELOW,
-}
-
-function HealBot_Options_TooltipPos_DropDown()
- for i=1, getn(HealBot_Options_TooltipPos_List), 1 do
- local info = {};
- info.text = HealBot_Options_TooltipPos_List[i];
- info.func = HealBot_Options_TooltipPos_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
-end
-
-function HealBot_Options_TooltipPos_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_TooltipPos,HealBot_Options_TooltipPos_DropDown)
-end
-
-function HealBot_Options_TooltipPos_Refresh(onselect)
- if not HealBot_Config.TooltipPos then return end
- if not onselect then HealBot_Options_TooltipPos_Initialize() end -- or wrong menu may be used !
- UIDropDownMenu_SetSelectedID(HealBot_Options_TooltipPos,HealBot_Config.TooltipPos)
-end
-
-function HealBot_Options_TooltipPos_OnLoad(this)
- HealBot_Options_TooltipPos_Initialize()
- UIDropDownMenu_SetWidth(128)
-end
-
-function HealBot_Options_TooltipPos_OnSelect()
- HealBot_Config.TooltipPos = this:GetID()
- HealBot_Options_TooltipPos_Refresh(true)
-end
-
---------------------------------------------------------------------------------
-
-local HealBot_Options_ComboClass_List = {
- HEALBOT_DRUID,
- HEALBOT_PALADIN,
- HEALBOT_PRIEST,
- HEALBOT_SHAMAN,
-}
-
-function HealBot_Options_GetDebuffSpells_List(class)
- local DebuffSpells = HealBot_Debuff_Spells[class];
- return DebuffSpells;
-end
-
-function HealBot_Options_CDCButLeft_DropDown()
- local classEN=HealBot_UnitClass("player")
- if classEN=="PRIEST" or classEN=="DRUID" or classEN=="PALADIN" or classEN=="SHAMAN" then
- local class=UnitClass("Player");
- local DebuffSpells_List = HealBot_Options_GetDebuffSpells_List(class)
- local info = {};
- info.text = "None";
- info.func = HealBot_Options_CDCButLeft_OnSelect;
- UIDropDownMenu_AddButton(info);
- for i=1, getn(DebuffSpells_List), 1 do
- local spell=HealBot_GetSpellName(HealBot_GetSpellId(DebuffSpells_List[i]));
- if spell then
- local info = {};
- info.text = spell;
- info.func = HealBot_Options_CDCButLeft_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
- end
- end
-end
-
-function HealBot_Options_CDCButRight_DropDown()
- local classEN=HealBot_UnitClass("player")
- if classEN=="PRIEST" or classEN=="DRUID" or classEN=="PALADIN" or classEN=="SHAMAN" then
- local class=UnitClass("Player");
- local DebuffSpells_List = HealBot_Options_GetDebuffSpells_List(class)
- local info = {};
- info.text = "None";
- info.func = HealBot_Options_CDCButRight_OnSelect;
- UIDropDownMenu_AddButton(info);
- for i=1, getn(DebuffSpells_List), 1 do
- local spell=HealBot_GetSpellName(HealBot_GetSpellId(DebuffSpells_List[i]));
- if spell then
- local info = {};
- info.text = spell;
- info.func = HealBot_Options_CDCButRight_OnSelect;
- UIDropDownMenu_AddButton(info);
- end
- end
- end
-end
-
-function HealBot_Options_CDCButLeft_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_CDCButLeft,HealBot_Options_CDCButLeft_DropDown)
-end
-
-function HealBot_Options_CDCButRight_Initialize()
- UIDropDownMenu_Initialize(HealBot_Options_CDCButRight,HealBot_Options_CDCButRight_DropDown)
-end
-
-function HealBot_Options_CDCButLeft_Refresh(onselect)
- local set_id=1;
- local class=UnitClass("Player");
- if not onselect then HealBot_Options_CDCButLeft_Initialize() end
- set_id = HealBot_Config.Debuff_Left[class];
- UIDropDownMenu_SetSelectedID(HealBot_Options_CDCButLeft,set_id)
-end
-
-function HealBot_Options_CDCButRight_Refresh(onselect)
- local set_id;
- local class=UnitClass("Player");
- if not onselect then HealBot_Options_CDCButRight_Initialize() end
- set_id = HealBot_Config.Debuff_Right[class];
- UIDropDownMenu_SetSelectedID(HealBot_Options_CDCButRight,set_id)
-end
-
-function HealBot_Options_ComboClass_Text()
- local class=UnitClass("Player");
- local combo = HealBot_Config.KeyCombo[class]
- local button = HealBot_Options_ComboClass_Button()
- if combo then
- HealBot_Options_Click:SetText(combo[button] or "")
- HealBot_Options_Shift:SetText(combo["Shift"..button] or "")
- HealBot_Options_Ctrl:SetText(combo["Ctrl"..button] or "")
- HealBot_Options_ShiftCtrl:SetText(combo["ShiftCtrl"..button] or "")
- end
-end
-
-function HealBot_Options_CDCButLeft_OnLoad(this)
- HealBot_Options_CDCButLeft_Initialize()
- UIDropDownMenu_SetWidth(140)
-end
-
-function HealBot_Options_CDCButRight_OnLoad(this)
- HealBot_Options_CDCButRight_Initialize()
- UIDropDownMenu_SetWidth(140)
-end
-
-function HealBot_Options_CDCButLeft_OnSelect()
- local class=UnitClass("Player");
- HealBot_Config.Debuff_Left[class] = this:GetID();
- HealBot_Options_CDCButLeft_Refresh(true)
- HealBot_Config.CDCLeftText[class]=HealBot_Options_CDCButLeftText:GetText();
- if this:GetID()>1 then
- HealBot_Options_CDC_SetCombo(HealBot_Options_CDCButLeftText:GetText(), "Left", class)
- end
- HealBot_DebuffPriority = HealBot_Debuff_Types[HealBot_Options_CDCButLeftText:GetText()];
- HealBot_Options_Debuff_Reset()
-end
-
-function HealBot_Options_CDCButRight_OnSelect()
- local class=UnitClass("Player");
- HealBot_Config.Debuff_Right[class] = this:GetID();
- HealBot_Options_CDCButRight_Refresh(true)
- HealBot_Config.CDCRightText[class]=HealBot_Options_CDCButRightText:GetText();
- if this:GetID()>1 then
- HealBot_Options_CDC_SetCombo(HealBot_Options_CDCButRightText:GetText(), "Right", class)
- end
- HealBot_Options_Debuff_Reset()
-end
-
-function HealBot_Options_CDC_SetCombo(spell, button, class)
- local combo = HealBot_Config.KeyCombo[class]
- combo["Alt"..button] = spell
- HealBot_Options_KeyCombo_Change()
-end
-
-function HealBot_Options_ComboClass_Button()
- local button = "Left"
- if HealBot_Options_ComboButtons_Button==2 then button = "Middle"; end
- if HealBot_Options_ComboButtons_Button==3 then button = "Right"; end
- if HealBot_Options_ComboButtons_Button==4 then button = "Button4"; end
- if HealBot_Options_ComboButtons_Button==5 then button = "Button5"; end
- return button;
-end
-
-
-function HealBot_Options_Debuff_Reset()
- local classEN=HealBot_UnitClass("player")
- if classEN=="PRIEST" or classEN=="DRUID" or classEN=="PALADIN" or classEN=="SHAMAN" then
- local spell = HealBot_Config.CDCLeftText[UnitClass("player")];
- HealBot_DebuffWatch = {[HEALBOT_DISEASE_en]="NO", [HEALBOT_MAGIC_en]="NO", [HEALBOT_POISON_en]="NO", [HEALBOT_CURSE_en]="NO" }
- if spell ~= "None" then
- table.foreach(HealBot_Debuff_Types[spell], function (index,debuff)
- HealBot_DebuffWatch[debuff]="YES";
- end)
- end
- spell = HealBot_Config.CDCRightText[UnitClass("player")];
- if spell ~= "None" then
- table.foreach(HealBot_Debuff_Types[spell], function (index,debuff)
- HealBot_DebuffWatch[debuff]="YES";
- end)
- end
- end
-end
-
-function HealBot_Colorpick_OnClick(CDCType)
- HealBot_ColourObjWaiting=CDCType;
- HealBot_UseColourPick(HealBot_Config.CDCBarColour[CDCType].R,HealBot_Config.CDCBarColour[CDCType].G,HealBot_Config.CDCBarColour[CDCType].B, nil)
-end
-
function HealBot_Returned_Colours()
local A = OpacitySliderFrame:GetValue();
A = ((0-A)+1);
@@ -1290,8 +197,6 @@ function HealBot_Returned_Colours()
HealBot_SetSkinColours()
HealBot_SetCDCBarColours()
end
-ColorPickerFrame.func = HealBot_Returned_Colours
-
function HealBot_UseColourPick(R, G, B, A)
if ColorPickerFrame:IsVisible() then
ColorPickerFrame:Hide();
@@ -1312,87 +217,6 @@ function HealBot_UseColourPick(R, G, B, A)
end
return ColorPickerFrame:GetColorRGB();
end
-
-
-
-function HealBot_SetCDCBarColours()
- HealBot_DiseaseColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].R,
- HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].G,
- HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].B,
- HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
- HealBot_MagicColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_MAGIC_en].R,
- HealBot_Config.CDCBarColour[HEALBOT_MAGIC_en].G,
- HealBot_Config.CDCBarColour[HEALBOT_MAGIC_en].B,
- HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
- HealBot_PoisonColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_POISON_en].R,
- HealBot_Config.CDCBarColour[HEALBOT_POISON_en].G,
- HealBot_Config.CDCBarColour[HEALBOT_POISON_en].B,
- HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
- HealBot_CurseColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_CURSE_en].R,
- HealBot_Config.CDCBarColour[HEALBOT_CURSE_en].G,
- HealBot_Config.CDCBarColour[HEALBOT_CURSE_en].B,
- HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
- HealBot_DebTextColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].R,
- HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].G,
- HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].B,
- HealBot_Config.Barcola[HealBot_Config.Current_Skin])
-end
-
---------------------------------------------------------------------------------
-
-function HealBot_Options_EditBox_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_Click_OnTextChanged(this)
- local class=UnitClass("Player");
- local combo = HealBot_Config.KeyCombo[class]
- local button = HealBot_Options_ComboClass_Button()
- combo[button] = this:GetText()
- HealBot_Options_KeyCombo_Change()
-end
-
-function HealBot_Options_Shift_OnTextChanged(this)
- local class=UnitClass("Player");
- local combo = HealBot_Config.KeyCombo[class]
- local button = HealBot_Options_ComboClass_Button()
- combo["Shift"..button] = this:GetText()
- HealBot_Options_KeyCombo_Change()
-end
-
-function HealBot_Options_Ctrl_OnTextChanged(this)
- local class=UnitClass("Player");
- local combo = HealBot_Config.KeyCombo[class]
- local button = HealBot_Options_ComboClass_Button()
- combo["Ctrl"..button] = this:GetText()
- HealBot_Options_KeyCombo_Change()
-end
-
-function HealBot_Options_ShiftCtrl_OnTextChanged(this)
- local class=UnitClass("Player");
- local combo = HealBot_Config.KeyCombo[class]
- local button = HealBot_Options_ComboClass_Button()
- combo["ShiftCtrl"..button] = this:GetText()
- HealBot_Options_KeyCombo_Change()
-end
-
-function HealBot_Options_KeyCombo_Change()
- local class=UnitClass("Player");
- HealBot_Config.KeyCombo[class]=HealBot_Config.KeyCombo[class];
-
-end
-
-function HealBot_Options_EnableHealthy_OnLoad(this,text)
- getglobal(this:GetName().."Text"):SetText(text);
-end
-
-function HealBot_Options_EnableHealthy_OnClick(this)
- HealBot_Config.EnableHealthy = this:GetChecked() or 0;
- HealBot_Action_EnableButtons();
-end
-
---------------------------------------------------------------------------------
-
function HealBot_Options_Defaults_OnClick(this)
HealBot_Options_CastNotify_OnClick(nil,0);
-- HealBot_Config = HealBot_ConfigDefaults;
@@ -1404,7 +228,6 @@ function HealBot_Options_Defaults_OnClick(this)
HealBot_Action_Reset();
HealBot_Config.ActionVisible = HealBot_Action:IsVisible();
end
-
function HealBot_Options_OnLoad(this)
table.insert(UISpecialFrames,this:GetName());
@@ -1414,7 +237,6 @@ function HealBot_Options_OnLoad(this)
PanelTemplates_UpdateTabs(this);
HealBot_Options_ShowPanel(this.selectedTab);
end
-
function HealBot_Options_OnShow(this)
HealBot_Skins = HealBot_Config.Skins;
HealBot_Options_SetSkins()
@@ -1472,7 +294,6 @@ function HealBot_Options_OnShow(this)
HealBot_Options_TooltipPos_Refresh();
HealBot_Options_SetChatMessages();
end
-
function HealBot_Options_SetSkins()
HealBot_Options_Skins_Refresh()
HealBot_Options_BarAlpha:SetValue(HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
@@ -1482,8 +303,8 @@ function HealBot_Options_SetSkins()
HealBot_Options_BarWidthS:SetValue(HealBot_Config.bwidth[HealBot_Config.Current_Skin])
HealBot_Options_BarNumColsS:SetValue(HealBot_Config.numcols[HealBot_Config.Current_Skin])
HealBot_Options_BarBRSpaceS:SetValue(HealBot_Config.brspace[HealBot_Config.Current_Skin])
- HealBot_Options_BarBCSpaceS:SetValue(HealBot_Config.bcspace[HealBot_Config.Current_Skin])
- HealBot_Options_FramePaddingS:SetValue((HealBot_Config.bpadding and HealBot_Config.bpadding[HealBot_Config.Current_Skin]) or 10)
+ HealBot_Options_BarBCSpaceS:SetValue(HealBot_Config.bcspace[HealBot_Config.Current_Skin])
+ HealBot_Options_FramePaddingS:SetValue((HealBot_Config.bpadding and HealBot_Config.bpadding[HealBot_Config.Current_Skin]) or 10)
HealBot_Options_BorderThicknessS:SetValue((HealBot_Config.bboffset and HealBot_Config.bboffset[HealBot_Config.Current_Skin]) or 1)
HealBot_Options_FontHeight:SetValue(HealBot_Config.btextheight[HealBot_Config.Current_Skin])
HealBot_Options_BarAlphaDis:SetValue(HealBot_Config.bardisa[HealBot_Config.Current_Skin])
@@ -1506,9 +327,6 @@ function HealBot_Options_SetSkins()
HealBot_Options_DeleteSkin:Enable();
end
end
-
-HealBot_Options_CurrentPanel = 0;
-
function HealBot_Options_ShowPanel(id)
if HealBot_Options_CurrentPanel>0 then
getglobal("HealBot_Options_Panel"..HealBot_Options_CurrentPanel):Hide();
@@ -1518,263 +336,3 @@ function HealBot_Options_ShowPanel(id)
getglobal("HealBot_Options_Panel"..HealBot_Options_CurrentPanel):Show();
end
end
-
-
---------------------------------------------------------------------------------
--- Chat Custom Messages UI Logic
---------------------------------------------------------------------------------
-
-local HealBot_PlayerSpells = nil
-
-local function HealBot_GetPlayerSpells()
- if HealBot_PlayerSpells then return HealBot_PlayerSpells end
- local spellSet = {}
- local i = 1
- while true do
- local spellName, spellRank = GetSpellName(i, BOOKTYPE_SPELL)
- if not spellName then
- break
- end
- spellSet[spellName] = true
- i = i + 1
- end
- local sortedSpells = {}
- for k, _ in pairs(spellSet) do
- table.insert(sortedSpells, k)
- end
- table.sort(sortedSpells)
- HealBot_PlayerSpells = sortedSpells
- return sortedSpells
-end
-
-function HealBot_Options_ChatMsg_Spell_Initialize()
- local info
-
- info = { text = "None", func = HealBot_Options_ChatMsg_Spell_OnClick, value = "None" }
- UIDropDownMenu_AddButton(info)
-
- local spells = HealBot_GetPlayerSpells()
- for _, spellName in ipairs(spells) do
- info = {
- text = spellName,
- func = HealBot_Options_ChatMsg_Spell_OnClick,
- value = spellName
- }
- UIDropDownMenu_AddButton(info)
- end
-end
-
-function HealBot_Options_ChatMsg_Spell_OnClick()
- local frameName = UIDROPDOWNMENU_OPEN_MENU
- local frame = getglobal(frameName)
- local id = frame:GetID()
-
- if not HealBot_Config.ChatMessages then HealBot_Config.ChatMessages = {} end
- if not HealBot_Config.ChatMessages[id] then
- HealBot_Config.ChatMessages[id] = { Spell = "None", Message = "Casting #Spell# on #Target#", Channel = "None" }
- end
-
- HealBot_Config.ChatMessages[id].Spell = this.value
-
- local text = this.value
- if text == "None" then text = "None" end
-
- UIDropDownMenu_SetSelectedValue(frame, this.value)
- UIDropDownMenu_SetText(text, frame)
-end
-
-function HealBot_Options_ChatMsg_Channel_OnClick(id, buttonFrame)
- if not HealBot_Config.ChatMessages then HealBot_Config.ChatMessages = {} end
- if not HealBot_Config.ChatMessages[id] then
- HealBot_Config.ChatMessages[id] = { Spell = "None", Message = "Casting #Spell# on #Target#", Channel = "None" }
- end
-
- local current = HealBot_Config.ChatMessages[id].Channel
- local nextChan = "None"
-
- if current == "None" then
- nextChan = "Say"
- elseif current == "Say" then
- nextChan = "Party"
- elseif current == "Party" then
- nextChan = "Raid"
- elseif current == "Raid" then
- nextChan = "Whisper"
- elseif current == "Whisper" then
- nextChan = "None"
- end
-
- HealBot_Config.ChatMessages[id].Channel = nextChan
- buttonFrame:SetText(nextChan)
-end
-
-function HealBot_Options_SetChatMessages()
- if not HealBot_Config.ChatMessages then
- HealBot_Config.ChatMessages = {}
- end
- for i = 1, 5 do
- if not HealBot_Config.ChatMessages[i] then
- HealBot_Config.ChatMessages[i] = { Spell = "None", Message = "Casting #Spell# on #Target#", Channel = "None" }
- end
- end
- for i = 1, 5 do
- local msgConfig = HealBot_Config.ChatMessages[i]
- if msgConfig then
- local dropDown = getglobal("HealBot_Options_ChatMsg"..i)
- local editBox = getglobal("HealBot_Options_ChatMsg"..i.."_Text")
- local chanButton = getglobal("HealBot_Options_ChatMsg"..i.."_Channel")
-
- if dropDown then
- UIDropDownMenu_Initialize(dropDown, HealBot_Options_ChatMsg_Spell_Initialize)
- UIDropDownMenu_SetSelectedValue(dropDown, msgConfig.Spell)
- UIDropDownMenu_SetWidth(110, dropDown)
- UIDropDownMenu_SetText(msgConfig.Spell, dropDown)
- end
- if editBox then
- editBox:SetText(msgConfig.Message or "")
- end
- if chanButton then
- chanButton:SetText(msgConfig.Channel or "None")
- end
- end
- end
-end
-
-
-
-function HealBot_Options_BuffWatch_OnClick(self)
- local frame = self or this
- HealBot_Config.BuffWatch = frame:GetChecked() or 0;
- if HealBot_Config.BuffWatch == 0 then
- HealBot_Options_BuffWatchInCombat:Disable()
- else
- HealBot_Options_BuffWatchInCombat:Enable()
- end
-end
-
-function HealBot_Options_BuffWatchInCombat_OnClick(self)
- local frame = self or this
- HealBot_Config.BuffWatchInCombat = frame:GetChecked() or 0;
-end
-
-function HealBot_Options_BuffSelf_OnLoad(self)
- local frame = self or this
- getglobal(this:GetName().."Text"):SetText("Self Only")
- local id = this:GetID()
- if HealBot_Config.BuffWatchSelf and HealBot_Config.BuffWatchSelf[id] then
- this:SetChecked(HealBot_Config.BuffWatchSelf[id])
- else
- this:SetChecked(0)
- end
-end
-
-function HealBot_Options_BuffSelf_OnClick(self)
- local frame = self or this
- local id = this:GetID()
- if not HealBot_Config.BuffWatchSelf then
- HealBot_Config.BuffWatchSelf = {0,0,0,0,0,0,0,0}
- end
- if frame:GetChecked() then
- HealBot_Config.BuffWatchSelf[id] = 1
- else
- HealBot_Config.BuffWatchSelf[id] = 0
- end
-end
-
-function HealBot_Options_Buff_OnLoad(self)
- local frame = self or this
- UIDropDownMenu_Initialize(frame, HealBot_Options_Buff_Initialize)
- UIDropDownMenu_SetWidth(110, frame)
-end
-
-function HealBot_Options_Buff_Initialize()
- local myClass = UnitClass("player")
- local info
-
- info = { text = "None", func = HealBot_Options_Buff_OnClick, value = 0 }
- UIDropDownMenu_AddButton(info)
-
- if HealBot_Buff_Spells[myClass] then
- for i, spellName in ipairs(HealBot_Buff_Spells[myClass]) do
- info = {
- text = spellName,
- func = HealBot_Options_Buff_OnClick,
- value = i
- }
- UIDropDownMenu_AddButton(info)
- end
- end
-end
-
-
-function HealBot_Options_Buff_OnClick()
- local frameName = UIDROPDOWNMENU_OPEN_MENU
- local frame = getglobal(frameName)
- local myClass = UnitClass("player")
- local id = frame:GetID()
-
- if not HealBot_Config.BuffDropDowns then HealBot_Config.BuffDropDowns = {} end
- if not HealBot_Config.BuffDropDowns[myClass] then HealBot_Config.BuffDropDowns[myClass] = {} end
- HealBot_Config.BuffDropDowns[myClass][id] = this.value
-
- local text = "None"
- if this.value > 0 then
- text = HealBot_Buff_Spells[myClass][this.value]
- end
-
- UIDropDownMenu_SetSelectedID(frame, this.value + 1)
- UIDropDownMenu_SetText(text, frame)
-end
-
-function HealBot_Options_SetBuffs()
- local myClass = UnitClass("player")
- if HealBot_Options_BuffWatch then
- HealBot_Options_BuffWatch:SetChecked(HealBot_Config.BuffWatch)
- HealBot_Options_BuffWatchInCombat:SetChecked(HealBot_Config.BuffWatchInCombat)
- if HealBot_Config.BuffWatch == 0 then
- HealBot_Options_BuffWatchInCombat:Disable()
- else
- HealBot_Options_BuffWatchInCombat:Enable()
- end
- end
-
- if not HealBot_Config.BuffDropDowns then HealBot_Config.BuffDropDowns = {} end
- if not HealBot_Config.BuffDropDowns[myClass] then HealBot_Config.BuffDropDowns[myClass] = {} end
-
- for i = 1, 8 do
- local dropDown = getglobal("HealBot_Options_Buff" .. i)
- if dropDown then
- local val = HealBot_Config.BuffDropDowns[myClass][i] or 0
- UIDropDownMenu_Initialize(dropDown, HealBot_Options_Buff_Initialize)
- UIDropDownMenu_SetSelectedID(dropDown, val + 1)
- end
-
- local selfCheck = getglobal("HealBot_Options_BuffSelf" .. i)
- if selfCheck then
- if HealBot_Config.BuffWatchSelf and HealBot_Config.BuffWatchSelf[i] then
- selfCheck:SetChecked(HealBot_Config.BuffWatchSelf[i])
- else
- selfCheck:SetChecked(0)
- end
- end
- end
-end
-
-
-
-
-
-function HealBot_Options_FramePaddingS_OnValueChanged(this)
- if not HealBot_Config.bpadding then HealBot_Config.bpadding = {} end
- HealBot_Config.bpadding[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
-function HealBot_Options_BorderThicknessS_OnValueChanged(this)
- if not HealBot_Config.bboffset then HealBot_Config.bboffset = {} end
- HealBot_Config.bboffset[HealBot_Config.Current_Skin] = this:GetValue();
- getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
- HealBot_Action_ResetSkin()
-end
-
diff --git a/HealBot_Options.xml b/HealBot_Options.xml
index aab421d..31db38a 100644
--- a/HealBot_Options.xml
+++ b/HealBot_Options.xml
@@ -143,2636 +143,6 @@
-
-
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ActionLocked_OnLoad(this)
- HealBot_Options_ActionLocked_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_GrowUpwards_OnLoad(this,HEALBOT_OPTIONS_GROWUPWARDS)
- HealBot_Options_GrowUpwards_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
- getglobal(this:GetName().."Text"):SetText("Show Mana Bars");
- this:SetChecked(HealBot_Config.ShowManaBars);
-
-
- if (this:GetChecked()) then
- HealBot_Config.ShowManaBars = 1;
- else
- HealBot_Config.ShowManaBars = 0;
- end
- HealBot_Action_Refresh();
-
-
-
-
-
-
-
-
-
-
-
-
-
- getglobal(this:GetName().."Text"):SetText("For Healers Only");
- this:SetChecked(HealBot_Config.ManaBarsHealersOnly);
-
-
- if (this:GetChecked()) then
- HealBot_Config.ManaBarsHealersOnly = 1;
- else
- HealBot_Config.ManaBarsHealersOnly = 0;
- end
- HealBot_Action_Refresh();
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_AutoShow_OnLoad(this)
- HealBot_Options_AutoShow_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_PanelSounds_OnLoad(this)
- HealBot_Options_PanelSounds_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ActionMouseover_OnLoad(this,"Enable Action Bar Mouseover")
- HealBot_Options_ActionMouseover_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_HideOptions_OnLoad(this,HEALBOT_OPTIONS_HIDEOPTIONS)
-
- HealBot_Options_HideOptions_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_HideAbort_OnLoad(this,HEALBOT_OPTIONS_HIDEABORT)
- HealBot_Options_HideAbort_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_QualityRange_OnLoad(this,HEALBOT_OPTIONS_QUALITYRANGE)
- HealBot_Options_QualityRange_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ProtectPvP_OnLoad(this,HEALBOT_OPTIONS_PROTECTPVP)
- HealBot_Options_ProtectPvP_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTONLEFT)
- HealBot_ComboButtons_Button_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTONMIDDLE)
- HealBot_ComboButtons_Button_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
- HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTONRIGHT)
- HealBot_ComboButtons_Button_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
- HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTON4)
- HealBot_ComboButtons_Button_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
- HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTON5)
- HealBot_ComboButtons_Button_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_CLICK)
-
-
- HealBot_Options_Click_OnTextChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_SHIFT)
-
-
- HealBot_Options_Shift_OnTextChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_CTRL)
-
-
- HealBot_Options_Ctrl_OnTextChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_SHIFTCTRL)
-
-
- HealBot_Options_ShiftCtrl_OnTextChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EnableHealthy_OnLoad(this,HEALBOT_OPTIONS_ENABLEHEALTHY)
- HealBot_Options_EnableHealthy_OnClick(this)
-
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ShowTooltip_OnLoad(this,HEALBOT_OPTIONS_SHOWTOOLTIP)
- HealBot_Options_ShowTooltip_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_TooltipPos_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ShowTooltipTarget_OnLoad(this,HEALBOT_OPTIONS_SHOWUNITTOOLTIP)
- HealBot_Options_ShowTooltipTarget_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ShowTooltipSpellDetail_OnLoad(this,HEALBOT_OPTIONS_SHOWDETTOOLTIP)
- HealBot_Options_ShowTooltipSpellDetail_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ShowTooltipInstant_OnLoad(this,HEALBOT_OPTIONS_SHOWRECTOOLTIP)
- HealBot_Options_ShowTooltipInstant_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_GroupHeals_OnLoad(this,HEALBOT_OPTIONS_GROUPHEALS)
- HealBot_Options_GroupHeals_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_TankHeals_OnLoad(this,HEALBOT_OPTIONS_TANKHEALS)
- HealBot_Options_TankHeals_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_TargetHeals_OnLoad(this,HEALBOT_OPTIONS_TARGETHEALS)
- HealBot_Options_TargetHeals_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EmergencyHeals_OnLoad(this,HEALBOT_OPTIONS_EMERGENCYHEALS)
- HealBot_Options_EmergencyHeals_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Pct_OnLoad(this,HEALBOT_OPTIONS_ALERTLEVEL)
- HealBot_Options_AlertLevel_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Pct_OnLoad(this,HEALBOT_OPTIONS_OVERHEAL)
- HealBot_Options_OverHeal_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EmergencyFilter_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ExtraSort_OnLoad(this)
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EmergencyFClass_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_DRUID)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_HUNTER)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_MAGE)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_PALADIN)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_PRIEST)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_ROGUE)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_SHAMAN)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_WARLOCK)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_EFClass_OnLoad(this,HEALBOT_WARRIOR)
- HealBot_Options_EFClass_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_CDCMonitor_OnLoad(this)
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_CDCButLeft_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_CDCButRight_OnLoad(this)
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ShowDebuffWarning_OnLoad(this,HEALBOT_OPTIONS_SHOWDEBUFFWARNING)
- HealBot_Options_ShowDebuffWarning_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_SoundDebuffWarning_OnLoad(this,HEALBOT_OPTIONS_SOUNDDEBUFFWARNING)
- HealBot_Options_SoundDebuffWarning_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_SOUND1)
- HealBot_WarningSound_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
- HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_SOUND2)
- HealBot_WarningSound_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
- HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_SOUND3)
- HealBot_WarningSound_OnClick(this,this:GetID())
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Skins_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_NewSkin_OnTextChanged(this)
-
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_ShowHeaders_OnLoad(this,HEALBOT_OPTIONS_SHOWHEADERS)
- HealBot_Options_ShowHeaders_OnClick(this)
-
-
-
-
-
- getglobal(this:GetName().."Text"):SetText("Class Colors")
- HealBot_Config.bcolormode[HealBot_Config.Current_Skin] = (this:GetChecked() and 2 or 1); HealBot_Action_ResetSkin()
-
-
-
-
-
- getglobal(this:GetName().."Text"):SetText("Font Outline")
- HealBot_Config.bfontoutline[HealBot_Config.Current_Skin] = (this:GetChecked() and 1 or 0); HealBot_Action_ResetSkin()
-
-
-
-
-
- getglobal(this:GetName().."Text"):SetText("1px Borders")
- HealBot_Config.bborder[HealBot_Config.Current_Skin] = (this:GetChecked() and 1 or 2); HealBot_Action_ResetSkin()
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINTEXTURE,1,14)
- HealBot_Options_BarTextureS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINNUMCOLS,1,8)
- HealBot_Options_BarNumColsS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINHEIGHT,10,100)
- HealBot_Options_BarHeightS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINWIDTH,50,225)
- HealBot_Options_BarWidthS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINBRSPACE,0,10)
- HealBot_Options_BarBRSpaceS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINBCSPACE,0,25)
- HealBot_Options_BarBCSpaceS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,"Frame Padding",0,50)
- HealBot_Options_FramePaddingS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,"Solid Border",1,10)
- HealBot_Options_BorderThicknessS_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Pct_OnLoad_MinMax(this,HEALBOT_OPTIONS_BARALPHA,0.25,1)
- HealBot_Options_BarAlpha_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Pct_OnLoad_MinMax(this,HEALBOT_OPTIONS_BARALPHAINHEAL,0.05,0.75)
- HealBot_Options_BarAlphaInHeal_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Pct_OnLoad(this,HEALBOT_OPTIONS_BARALPHADIS)
- HealBot_Options_BarAlphaDis_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINFHEIGHT,7,18)
- HealBot_Options_FontHeight_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_ABORTSIZE,0,15)
- HealBot_Options_AbortBarSize_OnValueChanged(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(70);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetMinMaxValues(0,100); this:SetValue(100);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- this:SetBackdropBorderColor(0.4, 0.4, 0.4);
- this:SetBackdropColor(0, 0, 0, 0);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_BUFFWATCH)
- HealBot_Options_BuffWatch_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_BUFFWATCHINCOMBAT)
- HealBot_Options_BuffWatchInCombat_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_Buff_OnLoad(this)
-
-
-
-
-
-
-
-
-
-
- HealBot_Options_BuffSelf_OnLoad(this)
- HealBot_Options_BuffSelf_OnClick(this)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- if HealBot_Config.ChatMessages then
- HealBot_Config.ChatMessages[1].Message = this:GetText();
- end
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- if HealBot_Config.ChatMessages then
- HealBot_Config.ChatMessages[2].Message = this:GetText();
- end
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- if HealBot_Config.ChatMessages then
- HealBot_Config.ChatMessages[3].Message = this:GetText();
- end
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- if HealBot_Config.ChatMessages then
- HealBot_Config.ChatMessages[4].Message = this:GetText();
- end
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- if HealBot_Config.ChatMessages then
- HealBot_Config.ChatMessages[5].Message = this:GetText();
- end
-
-
-
-
-
-
+
+
HealBot_Options_OnLoad(this);
diff --git a/HealBot_Options_Buffs.lua b/HealBot_Options_Buffs.lua
new file mode 100644
index 0000000..f779fe7
--- /dev/null
+++ b/HealBot_Options_Buffs.lua
@@ -0,0 +1,112 @@
+-- HealBot Options panel file: HealBot_Options_Buffs.lua
+-- Split from original HealBot_Options.lua
+
+function HealBot_Options_BuffWatch_OnClick(self)
+ local frame = self or this
+ HealBot_Config.BuffWatch = frame:GetChecked() or 0;
+ if HealBot_Config.BuffWatch == 0 then
+ HealBot_Options_BuffWatchInCombat:Disable()
+ else
+ HealBot_Options_BuffWatchInCombat:Enable()
+ end
+end
+function HealBot_Options_BuffWatchInCombat_OnClick(self)
+ local frame = self or this
+ HealBot_Config.BuffWatchInCombat = frame:GetChecked() or 0;
+end
+function HealBot_Options_BuffSelf_OnLoad(self)
+ local frame = self or this
+ getglobal(this:GetName().."Text"):SetText("Self Only")
+ local id = this:GetID()
+ if HealBot_Config.BuffWatchSelf and HealBot_Config.BuffWatchSelf[id] then
+ this:SetChecked(HealBot_Config.BuffWatchSelf[id])
+ else
+ this:SetChecked(0)
+ end
+end
+function HealBot_Options_BuffSelf_OnClick(self)
+ local frame = self or this
+ local id = this:GetID()
+ if not HealBot_Config.BuffWatchSelf then
+ HealBot_Config.BuffWatchSelf = {0,0,0,0,0,0,0,0}
+ end
+ if frame:GetChecked() then
+ HealBot_Config.BuffWatchSelf[id] = 1
+ else
+ HealBot_Config.BuffWatchSelf[id] = 0
+ end
+end
+function HealBot_Options_Buff_OnLoad(self)
+ local frame = self or this
+ UIDropDownMenu_Initialize(frame, HealBot_Options_Buff_Initialize)
+ UIDropDownMenu_SetWidth(110, frame)
+end
+function HealBot_Options_Buff_Initialize()
+ local myClass = UnitClass("player")
+ local info
+
+ info = { text = "None", func = HealBot_Options_Buff_OnClick, value = 0 }
+ UIDropDownMenu_AddButton(info)
+
+ if HealBot_Buff_Spells[myClass] then
+ for i, spellName in ipairs(HealBot_Buff_Spells[myClass]) do
+ info = {
+ text = spellName,
+ func = HealBot_Options_Buff_OnClick,
+ value = i
+ }
+ UIDropDownMenu_AddButton(info)
+ end
+ end
+end
+function HealBot_Options_Buff_OnClick()
+ local frameName = UIDROPDOWNMENU_OPEN_MENU
+ local frame = getglobal(frameName)
+ local myClass = UnitClass("player")
+ local id = frame:GetID()
+
+ if not HealBot_Config.BuffDropDowns then HealBot_Config.BuffDropDowns = {} end
+ if not HealBot_Config.BuffDropDowns[myClass] then HealBot_Config.BuffDropDowns[myClass] = {} end
+ HealBot_Config.BuffDropDowns[myClass][id] = this.value
+
+ local text = "None"
+ if this.value > 0 then
+ text = HealBot_Buff_Spells[myClass][this.value]
+ end
+
+ UIDropDownMenu_SetSelectedID(frame, this.value + 1)
+ UIDropDownMenu_SetText(text, frame)
+end
+function HealBot_Options_SetBuffs()
+ local myClass = UnitClass("player")
+ if HealBot_Options_BuffWatch then
+ HealBot_Options_BuffWatch:SetChecked(HealBot_Config.BuffWatch)
+ HealBot_Options_BuffWatchInCombat:SetChecked(HealBot_Config.BuffWatchInCombat)
+ if HealBot_Config.BuffWatch == 0 then
+ HealBot_Options_BuffWatchInCombat:Disable()
+ else
+ HealBot_Options_BuffWatchInCombat:Enable()
+ end
+ end
+
+ if not HealBot_Config.BuffDropDowns then HealBot_Config.BuffDropDowns = {} end
+ if not HealBot_Config.BuffDropDowns[myClass] then HealBot_Config.BuffDropDowns[myClass] = {} end
+
+ for i = 1, 8 do
+ local dropDown = getglobal("HealBot_Options_Buff" .. i)
+ if dropDown then
+ local val = HealBot_Config.BuffDropDowns[myClass][i] or 0
+ UIDropDownMenu_Initialize(dropDown, HealBot_Options_Buff_Initialize)
+ UIDropDownMenu_SetSelectedID(dropDown, val + 1)
+ end
+
+ local selfCheck = getglobal("HealBot_Options_BuffSelf" .. i)
+ if selfCheck then
+ if HealBot_Config.BuffWatchSelf and HealBot_Config.BuffWatchSelf[i] then
+ selfCheck:SetChecked(HealBot_Config.BuffWatchSelf[i])
+ else
+ selfCheck:SetChecked(0)
+ end
+ end
+ end
+end
diff --git a/HealBot_Options_Buffs.xml b/HealBot_Options_Buffs.xml
new file mode 100644
index 0000000..4688ebf
--- /dev/null
+++ b/HealBot_Options_Buffs.xml
@@ -0,0 +1,372 @@
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_BUFFWATCH)
+ HealBot_Options_BuffWatch_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_BUFFWATCHINCOMBAT)
+ HealBot_Options_BuffWatchInCombat_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Buff_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_BuffSelf_OnLoad(this)
+ HealBot_Options_BuffSelf_OnClick(this)
+
+
+
+
+
+
+
diff --git a/HealBot_Options_CDC.lua b/HealBot_Options_CDC.lua
new file mode 100644
index 0000000..974185f
--- /dev/null
+++ b/HealBot_Options_CDC.lua
@@ -0,0 +1,289 @@
+-- HealBot Options panel file: HealBot_Options_CDC.lua
+-- Split from original HealBot_Options.lua
+
+function HealBot_Options_ShowDebuffWarning_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ShowDebuffWarning_OnClick(this)
+ HealBot_Config.ShowDebuffWarning = this:GetChecked() or 0;
+end
+function HealBot_Options_SoundDebuffWarning_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_SoundDebuffWarning_OnClick(this)
+ HealBot_Config.SoundDebuffWarning = this:GetChecked() or 0;
+ if HealBot_Config.SoundDebuffWarning==0 then
+ HealBot_WarningSound1:Disable();
+ HealBot_WarningSound2:Disable();
+ HealBot_WarningSound3:Disable();
+ else
+ HealBot_WarningSound1:Enable();
+ HealBot_WarningSound2:Enable();
+ HealBot_WarningSound3:Enable();
+ end
+end
+function HealBot_WarningSound_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_WarningSound_OnClick(this,id)
+ if HealBot_Config.SoundDebuffPlay>0 then
+ getglobal("HealBot_WarningSound"..HealBot_Config.SoundDebuffPlay):SetChecked(nil);
+ end
+ HealBot_Config.SoundDebuffPlay = id;
+ if HealBot_Config.SoundDebuffPlay>0 then
+ getglobal("HealBot_WarningSound"..HealBot_Config.SoundDebuffPlay):SetChecked(1);
+ if this then
+ HealBot_PlaySound(HealBot_Config.SoundDebuffPlay)
+ end
+ end
+end
+function HealBot_Options_CDCMonitor_DropDown()
+ for i=1, getn(HealBot_Options_EmergencyFilter_List), 1 do
+ local info = {};
+ info.text = HealBot_Options_EmergencyFilter_List[i];
+ info.func = HealBot_Options_CDCMonitor_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+end
+function HealBot_Options_CDCMonitor_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_CDCMonitor,HealBot_Options_CDCMonitor_DropDown)
+end
+function HealBot_Options_CDCMonitor_Refresh(onselect)
+ if not HealBot_Config.CDCMonitor then return end
+ if not onselect then HealBot_Options_CDCMonitor_Initialize() end -- or wrong menu may be used !
+ UIDropDownMenu_SetSelectedID(HealBot_Options_CDCMonitor,HealBot_Config.CDCMonitor)
+end
+function HealBot_Options_CDCMonitor_OnLoad(this)
+ HealBot_Options_CDCMonitor_Initialize()
+ UIDropDownMenu_SetWidth(100)
+end
+function HealBot_Options_CDCMonitor_OnSelect()
+ HealBot_Config.CDCMonitor = this:GetID()
+ HealBot_Options_CDCMonitor_Refresh(true)
+ HealBot_Options_CDCMonitor_Reset()
+end
+function HealBot_Options_CDCMonitor_Reset()
+
+ HealBot_CDCInc[HEALBOT_DRUID] = 0;
+ HealBot_CDCInc[HEALBOT_HUNTER] = 0;
+ HealBot_CDCInc[HEALBOT_MAGE] = 0;
+ HealBot_CDCInc[HEALBOT_PALADIN] = 0;
+ HealBot_CDCInc[HEALBOT_PRIEST] = 0;
+ HealBot_CDCInc[HEALBOT_ROGUE] = 0;
+ HealBot_CDCInc[HEALBOT_SHAMAN] = 0;
+ HealBot_CDCInc[HEALBOT_WARLOCK] = 0;
+ HealBot_CDCInc[HEALBOT_WARRIOR] = 0;
+ if HealBot_Config.CDCMonitor==1 then
+ HealBot_CDCInc[HEALBOT_DRUID] = 1;
+ HealBot_CDCInc[HEALBOT_HUNTER] = 1;
+ HealBot_CDCInc[HEALBOT_MAGE] = 1;
+ HealBot_CDCInc[HEALBOT_PALADIN] = 1;
+ HealBot_CDCInc[HEALBOT_PRIEST] = 1;
+ HealBot_CDCInc[HEALBOT_ROGUE] = 1;
+ HealBot_CDCInc[HEALBOT_SHAMAN] = 1;
+ HealBot_CDCInc[HEALBOT_WARLOCK] = 1;
+ HealBot_CDCInc[HEALBOT_WARRIOR] = 1;
+ elseif HealBot_Config.CDCMonitor==2 then
+ HealBot_CDCInc[HEALBOT_DRUID] = 1;
+ elseif HealBot_Config.CDCMonitor==3 then
+ HealBot_CDCInc[HEALBOT_HUNTER] = 1;
+ elseif HealBot_Config.CDCMonitor==4 then
+ HealBot_CDCInc[HEALBOT_MAGE] = 1;
+ elseif HealBot_Config.CDCMonitor==5 then
+ HealBot_CDCInc[HEALBOT_PALADIN] = 1;
+ elseif HealBot_Config.CDCMonitor==6 then
+ HealBot_CDCInc[HEALBOT_PRIEST] = 1;
+ elseif HealBot_Config.CDCMonitor==7 then
+ HealBot_CDCInc[HEALBOT_ROGUE] = 1;
+ elseif HealBot_Config.CDCMonitor==8 then
+ HealBot_CDCInc[HEALBOT_SHAMAN] = 1;
+ elseif HealBot_Config.CDCMonitor==9 then
+ HealBot_CDCInc[HEALBOT_WARLOCK] = 1;
+ elseif HealBot_Config.CDCMonitor==10 then
+ HealBot_CDCInc[HEALBOT_WARRIOR] = 1;
+ elseif HealBot_Config.CDCMonitor==11 then
+ HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncMelee[HEALBOT_DRUID];
+ HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncMelee[HEALBOT_HUNTER];
+ HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncMelee[HEALBOT_MAGE];
+ HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncMelee[HEALBOT_PALADIN];
+ HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncMelee[HEALBOT_PRIEST];
+ HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncMelee[HEALBOT_ROGUE];
+ HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN];
+ HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK];
+ HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR];
+ elseif HealBot_Config.CDCMonitor==12 then
+ HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncRange[HEALBOT_DRUID];
+ HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncRange[HEALBOT_HUNTER];
+ HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncRange[HEALBOT_MAGE];
+ HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncRange[HEALBOT_PALADIN];
+ HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncRange[HEALBOT_PRIEST];
+ HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncRange[HEALBOT_ROGUE];
+ HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncRange[HEALBOT_SHAMAN];
+ HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncRange[HEALBOT_WARLOCK];
+ HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncRange[HEALBOT_WARRIOR];
+ elseif HealBot_Config.CDCMonitor==13 then
+ HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncHealers[HEALBOT_DRUID];
+ HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncHealers[HEALBOT_HUNTER];
+ HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncHealers[HEALBOT_MAGE];
+ HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncHealers[HEALBOT_PALADIN];
+ HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncHealers[HEALBOT_PRIEST];
+ HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncHealers[HEALBOT_ROGUE];
+ HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN];
+ HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK];
+ HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR];
+ elseif HealBot_Config.CDCMonitor==14 then
+ HealBot_CDCInc[HEALBOT_DRUID] = HealBot_Config.EmergIncCustom[HEALBOT_DRUID];
+ HealBot_CDCInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncCustom[HEALBOT_HUNTER];
+ HealBot_CDCInc[HEALBOT_MAGE] = HealBot_Config.EmergIncCustom[HEALBOT_MAGE];
+ HealBot_CDCInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncCustom[HEALBOT_PALADIN];
+ HealBot_CDCInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncCustom[HEALBOT_PRIEST];
+ HealBot_CDCInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncCustom[HEALBOT_ROGUE];
+ HealBot_CDCInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN];
+ HealBot_CDCInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK];
+ HealBot_CDCInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR];
+ end
+
+ HealBot_Action_PartyChanged()
+end
+function HealBot_Options_GetDebuffSpells_List(class)
+ local DebuffSpells = HealBot_Debuff_Spells[class];
+ return DebuffSpells;
+end
+function HealBot_Options_CDCButLeft_DropDown()
+ local classEN=HealBot_UnitClass("player")
+ if classEN=="PRIEST" or classEN=="DRUID" or classEN=="PALADIN" or classEN=="SHAMAN" then
+ local class=UnitClass("Player");
+ local DebuffSpells_List = HealBot_Options_GetDebuffSpells_List(class)
+ local info = {};
+ info.text = "None";
+ info.func = HealBot_Options_CDCButLeft_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ for i=1, getn(DebuffSpells_List), 1 do
+ local spell=HealBot_GetSpellName(HealBot_GetSpellId(DebuffSpells_List[i]));
+ if spell then
+ local info = {};
+ info.text = spell;
+ info.func = HealBot_Options_CDCButLeft_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+ end
+ end
+end
+function HealBot_Options_CDCButRight_DropDown()
+ local classEN=HealBot_UnitClass("player")
+ if classEN=="PRIEST" or classEN=="DRUID" or classEN=="PALADIN" or classEN=="SHAMAN" then
+ local class=UnitClass("Player");
+ local DebuffSpells_List = HealBot_Options_GetDebuffSpells_List(class)
+ local info = {};
+ info.text = "None";
+ info.func = HealBot_Options_CDCButRight_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ for i=1, getn(DebuffSpells_List), 1 do
+ local spell=HealBot_GetSpellName(HealBot_GetSpellId(DebuffSpells_List[i]));
+ if spell then
+ local info = {};
+ info.text = spell;
+ info.func = HealBot_Options_CDCButRight_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+ end
+ end
+end
+function HealBot_Options_CDCButLeft_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_CDCButLeft,HealBot_Options_CDCButLeft_DropDown)
+end
+function HealBot_Options_CDCButRight_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_CDCButRight,HealBot_Options_CDCButRight_DropDown)
+end
+function HealBot_Options_CDCButLeft_Refresh(onselect)
+ local set_id=1;
+ local class=UnitClass("Player");
+ if not onselect then HealBot_Options_CDCButLeft_Initialize() end
+ set_id = HealBot_Config.Debuff_Left[class];
+ UIDropDownMenu_SetSelectedID(HealBot_Options_CDCButLeft,set_id)
+end
+function HealBot_Options_CDCButRight_Refresh(onselect)
+ local set_id;
+ local class=UnitClass("Player");
+ if not onselect then HealBot_Options_CDCButRight_Initialize() end
+ set_id = HealBot_Config.Debuff_Right[class];
+ UIDropDownMenu_SetSelectedID(HealBot_Options_CDCButRight,set_id)
+end
+function HealBot_Options_CDCButLeft_OnLoad(this)
+ HealBot_Options_CDCButLeft_Initialize()
+ UIDropDownMenu_SetWidth(140)
+end
+function HealBot_Options_CDCButRight_OnLoad(this)
+ HealBot_Options_CDCButRight_Initialize()
+ UIDropDownMenu_SetWidth(140)
+end
+function HealBot_Options_CDCButLeft_OnSelect()
+ local class=UnitClass("Player");
+ HealBot_Config.Debuff_Left[class] = this:GetID();
+ HealBot_Options_CDCButLeft_Refresh(true)
+ HealBot_Config.CDCLeftText[class]=HealBot_Options_CDCButLeftText:GetText();
+ if this:GetID()>1 then
+ HealBot_Options_CDC_SetCombo(HealBot_Options_CDCButLeftText:GetText(), "Left", class)
+ end
+ HealBot_DebuffPriority = HealBot_Debuff_Types[HealBot_Options_CDCButLeftText:GetText()];
+ HealBot_Options_Debuff_Reset()
+end
+function HealBot_Options_CDCButRight_OnSelect()
+ local class=UnitClass("Player");
+ HealBot_Config.Debuff_Right[class] = this:GetID();
+ HealBot_Options_CDCButRight_Refresh(true)
+ HealBot_Config.CDCRightText[class]=HealBot_Options_CDCButRightText:GetText();
+ if this:GetID()>1 then
+ HealBot_Options_CDC_SetCombo(HealBot_Options_CDCButRightText:GetText(), "Right", class)
+ end
+ HealBot_Options_Debuff_Reset()
+end
+function HealBot_Options_CDC_SetCombo(spell, button, class)
+ local combo = HealBot_Config.KeyCombo[class]
+ combo["Alt"..button] = spell
+ HealBot_Options_KeyCombo_Change()
+end
+function HealBot_Options_Debuff_Reset()
+ local classEN=HealBot_UnitClass("player")
+ if classEN=="PRIEST" or classEN=="DRUID" or classEN=="PALADIN" or classEN=="SHAMAN" then
+ local spell = HealBot_Config.CDCLeftText[UnitClass("player")];
+ HealBot_DebuffWatch = {[HEALBOT_DISEASE_en]="NO", [HEALBOT_MAGIC_en]="NO", [HEALBOT_POISON_en]="NO", [HEALBOT_CURSE_en]="NO" }
+ if spell ~= "None" then
+ table.foreach(HealBot_Debuff_Types[spell], function (index,debuff)
+ HealBot_DebuffWatch[debuff]="YES";
+ end)
+ end
+ spell = HealBot_Config.CDCRightText[UnitClass("player")];
+ if spell ~= "None" then
+ table.foreach(HealBot_Debuff_Types[spell], function (index,debuff)
+ HealBot_DebuffWatch[debuff]="YES";
+ end)
+ end
+ end
+end
+function HealBot_Colorpick_OnClick(CDCType)
+ HealBot_ColourObjWaiting=CDCType;
+ HealBot_UseColourPick(HealBot_Config.CDCBarColour[CDCType].R,HealBot_Config.CDCBarColour[CDCType].G,HealBot_Config.CDCBarColour[CDCType].B, nil)
+end
+function HealBot_SetCDCBarColours()
+ HealBot_DiseaseColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].R,
+ HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].G,
+ HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].B,
+ HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
+ HealBot_MagicColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_MAGIC_en].R,
+ HealBot_Config.CDCBarColour[HEALBOT_MAGIC_en].G,
+ HealBot_Config.CDCBarColour[HEALBOT_MAGIC_en].B,
+ HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
+ HealBot_PoisonColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_POISON_en].R,
+ HealBot_Config.CDCBarColour[HEALBOT_POISON_en].G,
+ HealBot_Config.CDCBarColour[HEALBOT_POISON_en].B,
+ HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
+ HealBot_CurseColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_CURSE_en].R,
+ HealBot_Config.CDCBarColour[HEALBOT_CURSE_en].G,
+ HealBot_Config.CDCBarColour[HEALBOT_CURSE_en].B,
+ HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
+ HealBot_DebTextColorpick:SetStatusBarColor(HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].R,
+ HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].G,
+ HealBot_Config.CDCBarColour[HEALBOT_DISEASE_en].B,
+ HealBot_Config.Barcola[HealBot_Config.Current_Skin])
+end
diff --git a/HealBot_Options_CDC.xml b/HealBot_Options_CDC.xml
new file mode 100644
index 0000000..f2bd49a
--- /dev/null
+++ b/HealBot_Options_CDC.xml
@@ -0,0 +1,450 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_CDCMonitor_OnLoad(this)
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_CDCButLeft_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_CDCButRight_OnLoad(this)
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ShowDebuffWarning_OnLoad(this,HEALBOT_OPTIONS_SHOWDEBUFFWARNING)
+ HealBot_Options_ShowDebuffWarning_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_SoundDebuffWarning_OnLoad(this,HEALBOT_OPTIONS_SOUNDDEBUFFWARNING)
+ HealBot_Options_SoundDebuffWarning_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_SOUND1)
+ HealBot_WarningSound_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_SOUND2)
+ HealBot_WarningSound_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_WarningSound_OnLoad(this,HEALBOT_OPTIONS_SOUND3)
+ HealBot_WarningSound_OnClick(this,this:GetID())
+
+
+
+
+
+
diff --git a/HealBot_Options_Chat.lua b/HealBot_Options_Chat.lua
new file mode 100644
index 0000000..d95eb7f
--- /dev/null
+++ b/HealBot_Options_Chat.lua
@@ -0,0 +1,136 @@
+-- HealBot Options panel file: HealBot_Options_Chat.lua
+-- Split from original HealBot_Options.lua
+
+local HealBot_PlayerSpells = nil
+
+function HealBot_GetPlayerSpells()
+ if HealBot_PlayerSpells then return HealBot_PlayerSpells end
+ local spellSet = {}
+ local i = 1
+ while true do
+ local spellName, spellRank = GetSpellName(i, BOOKTYPE_SPELL)
+ if not spellName then
+ break
+ end
+ spellSet[spellName] = true
+ i = i + 1
+ end
+ local sortedSpells = {}
+ for k, _ in pairs(spellSet) do
+ table.insert(sortedSpells, k)
+ end
+ table.sort(sortedSpells)
+ HealBot_PlayerSpells = sortedSpells
+ return sortedSpells
+end
+
+function HealBot_Options_ChatMsg_Spell_Initialize()
+ local info
+
+ info = { text = "None", func = HealBot_Options_ChatMsg_Spell_OnClick, value = "None" }
+ UIDropDownMenu_AddButton(info)
+
+ local spells = HealBot_GetPlayerSpells()
+ for _, spellName in ipairs(spells) do
+ info = {
+ text = spellName,
+ func = HealBot_Options_ChatMsg_Spell_OnClick,
+ value = spellName
+ }
+ UIDropDownMenu_AddButton(info)
+ end
+end
+
+function HealBot_Options_ChatMsg_Spell_OnClick()
+ local frameName = UIDROPDOWNMENU_OPEN_MENU
+ local frame = getglobal(frameName)
+ local id = frame:GetID()
+
+ if not HealBot_Config.ChatMessages then HealBot_Config.ChatMessages = {} end
+ if not HealBot_Config.ChatMessages[id] then
+ HealBot_Config.ChatMessages[id] = { Spell = "None", Message = "Casting #Spell# on #Target#", Channel = "None" }
+ end
+
+ HealBot_Config.ChatMessages[id].Spell = this.value
+
+ local text = this.value
+ if text == "None" then text = "None" end
+
+ UIDropDownMenu_SetSelectedValue(frame, this.value)
+ UIDropDownMenu_SetText(text, frame)
+end
+
+function HealBot_Options_ChatMsg_Channel_OnClick(id, buttonFrame)
+ if not HealBot_Config.ChatMessages then HealBot_Config.ChatMessages = {} end
+ if not HealBot_Config.ChatMessages[id] then
+ HealBot_Config.ChatMessages[id] = { Spell = "None", Message = "Casting #Spell# on #Target#", Channel = "None" }
+ end
+
+ local current = HealBot_Config.ChatMessages[id].Channel
+ local nextChan = "None"
+
+ if current == "None" then
+ nextChan = "Say"
+ elseif current == "Say" then
+ nextChan = "Party"
+ elseif current == "Party" then
+ nextChan = "Raid"
+ elseif current == "Raid" then
+ nextChan = "Whisper"
+ elseif current == "Whisper" then
+ nextChan = "None"
+ end
+
+ HealBot_Config.ChatMessages[id].Channel = nextChan
+ buttonFrame:SetText(nextChan)
+end
+
+function HealBot_Options_SetChatMessages()
+ if not HealBot_Config.ChatMessages then
+ HealBot_Config.ChatMessages = {}
+ end
+ for i = 1, 5 do
+ if not HealBot_Config.ChatMessages[i] then
+ HealBot_Config.ChatMessages[i] = { Spell = "None", Message = "Casting #Spell# on #Target#", Channel = "None" }
+ end
+ end
+ for i = 1, 5 do
+ local msgConfig = HealBot_Config.ChatMessages[i]
+ if msgConfig then
+ local dropDown = getglobal("HealBot_Options_ChatMsg"..i)
+ local editBox = getglobal("HealBot_Options_ChatMsg"..i.."_Text")
+ local chanButton = getglobal("HealBot_Options_ChatMsg"..i.."_Channel")
+
+ if dropDown then
+ UIDropDownMenu_Initialize(dropDown, HealBot_Options_ChatMsg_Spell_Initialize)
+ UIDropDownMenu_SetSelectedValue(dropDown, msgConfig.Spell)
+ UIDropDownMenu_SetWidth(110, dropDown)
+ UIDropDownMenu_SetText(msgConfig.Spell, dropDown)
+ end
+ if editBox then
+ editBox:SetText(msgConfig.Message or "")
+ end
+ if chanButton then
+ chanButton:SetText(msgConfig.Channel or "None")
+ end
+ end
+ end
+end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/HealBot_Options_Chat.xml b/HealBot_Options_Chat.xml
new file mode 100644
index 0000000..ee51447
--- /dev/null
+++ b/HealBot_Options_Chat.xml
@@ -0,0 +1,240 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ if HealBot_Config.ChatMessages then
+ HealBot_Config.ChatMessages[1].Message = this:GetText();
+ end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ if HealBot_Config.ChatMessages then
+ HealBot_Config.ChatMessages[2].Message = this:GetText();
+ end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ if HealBot_Config.ChatMessages then
+ HealBot_Config.ChatMessages[3].Message = this:GetText();
+ end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ if HealBot_Config.ChatMessages then
+ HealBot_Config.ChatMessages[4].Message = this:GetText();
+ end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ if HealBot_Config.ChatMessages then
+ HealBot_Config.ChatMessages[5].Message = this:GetText();
+ end
+
+
+
+
+
+
+
+
diff --git a/HealBot_Options_General.lua b/HealBot_Options_General.lua
new file mode 100644
index 0000000..253906f
--- /dev/null
+++ b/HealBot_Options_General.lua
@@ -0,0 +1,270 @@
+-- HealBot Options panel file: HealBot_Options_General.lua
+-- Split from original HealBot_Options.lua
+
+function HealBot_Options_ShowHeaders_OnLoad(this)
+ getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_SHOWHEADERS);
+end
+function HealBot_Options_ShowHeaders_OnClick(this)
+ HealBot_Config.ShowHeader[HealBot_Config.Current_Skin] = this:GetChecked();
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarTextureS_OnValueChanged(this)
+ HealBot_Config.btexture[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarHeightS_OnValueChanged(this)
+ HealBot_Config.bheight[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarWidthS_OnValueChanged(this)
+ HealBot_Config.bwidth[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarNumColsS_OnValueChanged(this)
+ HealBot_Config.numcols[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarBRSpaceS_OnValueChanged(this)
+ HealBot_Config.brspace[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarBCSpaceS_OnValueChanged(this)
+ HealBot_Config.bcspace[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_FontHeight_OnValueChanged(this)
+ HealBot_Config.btextheight[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_AbortBarSize_OnValueChanged(this)
+ HealBot_Config.abortsize[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_ActionAlpha_OnValueChanged(this)
+ HealBot_Config.backcola[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
+end
+function HealBot_Options_BarAlpha_OnValueChanged(this)
+ HealBot_Config.Barcola[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarAlphaInHeal_OnValueChanged(this)
+ HealBot_Config.BarcolaInHeal[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BarAlphaDis_OnValueChanged(this)
+ HealBot_Config.bardisa[HealBot_Config.Current_Skin] = HealBot_Options_Pct_OnValueChanged(this);
+ HealBot_Action_ResetSkin()
+end
+function HealBot_SkinColorpick_OnClick(SkinType)
+ HealBot_ColourObjWaiting=SkinType;
+
+ if SkinType=="En" then
+ HealBot_UseColourPick(HealBot_Config.btextenabledcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.btextenabledcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.btextenabledcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.btextenabledcola[HealBot_Config.Current_Skin]);
+ elseif SkinType=="Dis" then
+ HealBot_UseColourPick(HealBot_Config.btextdisbledcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.btextdisbledcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.btextdisbledcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.btextdisbledcola[HealBot_Config.Current_Skin])
+ elseif SkinType=="Debuff" then
+ HealBot_UseColourPick(HealBot_Config.btextcursecolr[HealBot_Config.Current_Skin],
+ HealBot_Config.btextcursecolg[HealBot_Config.Current_Skin],
+ HealBot_Config.btextcursecolb[HealBot_Config.Current_Skin],
+ HealBot_Config.btextcursecola[HealBot_Config.Current_Skin])
+ elseif SkinType=="Back" then
+ HealBot_UseColourPick(HealBot_Config.backcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.backcola[HealBot_Config.Current_Skin])
+ elseif SkinType=="Bor" then
+ HealBot_UseColourPick(HealBot_Config.borcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.borcola[HealBot_Config.Current_Skin])
+ elseif SkinType=="Abort" then
+ HealBot_UseColourPick(HealBot_Config.babortcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.babortcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.babortcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.babortcola[HealBot_Config.Current_Skin])
+ end
+end
+function HealBot_SetSkinColours()
+ local btextheight=HealBot_Config.btextheight[HealBot_Config.Current_Skin] or 10;
+
+ HealBot_EnTextColorpick:SetStatusBarColor(0,1,0,HealBot_Config.Barcola[HealBot_Config.Current_Skin]);
+ HealBot_EnTextColorpickin:SetStatusBarColor(0,1,0,HealBot_Config.Barcola[HealBot_Config.Current_Skin]*HealBot_Config.BarcolaInHeal[HealBot_Config.Current_Skin]);
+ HealBot_DisTextColorpick:SetStatusBarColor(0,1,0,HealBot_Config.bardisa[HealBot_Config.Current_Skin]);
+ HealBot_EnTextColorpickt:SetTextColor(
+ HealBot_Config.btextenabledcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.btextenabledcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.btextenabledcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.btextenabledcola[HealBot_Config.Current_Skin]);
+ HealBot_DisTextColorpickt:SetTextColor(
+ HealBot_Config.btextdisbledcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.btextdisbledcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.btextdisbledcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.btextdisbledcola[HealBot_Config.Current_Skin]);
+ HealBot_DebTextColorpickt:SetTextColor(
+ HealBot_Config.btextcursecolr[HealBot_Config.Current_Skin],
+ HealBot_Config.btextcursecolg[HealBot_Config.Current_Skin],
+ HealBot_Config.btextcursecolb[HealBot_Config.Current_Skin],
+ HealBot_Config.btextcursecola[HealBot_Config.Current_Skin]);
+ HealBot_BackgroundColorpick:SetStatusBarColor(
+ HealBot_Config.backcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.backcola[HealBot_Config.Current_Skin]);
+ HealBot_BorderColorpick:SetStatusBarColor(
+ HealBot_Config.borcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.borcola[HealBot_Config.Current_Skin]);
+ HealBot_AbortColorpick:SetStatusBarColor(
+ HealBot_Config.babortcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.babortcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.babortcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.babortcola[HealBot_Config.Current_Skin]);
+
+ local borderStyle = HealBot_Config.bborder[HealBot_Config.Current_Skin] or 2
+ if borderStyle == 0 then
+ HealBot_Action:SetBackdropBorderColor(0,0,0,0);
+ elseif borderStyle == 1 then
+ local bboffset = (HealBot_Config.bboffset and HealBot_Config.bboffset[HealBot_Config.Current_Skin]) or 1
+ local bpadding = (HealBot_Config.bpadding and HealBot_Config.bpadding[HealBot_Config.Current_Skin]) or 10
+ HealBot_Action:SetBackdrop({
+ bgFile = "Interface\\Tooltips\\UI-Tooltip-Background",
+ edgeFile = "Interface\\Buttons\\WHITE8X8",
+ tile = true, tileSize = 8, edgeSize = bboffset,
+ insets = { left = bpadding, right = bpadding, top = bpadding, bottom = bpadding }
+ })
+ HealBot_Action:SetBackdropColor(
+ HealBot_Config.backcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.backcola[HealBot_Config.Current_Skin]);
+ HealBot_Action:SetBackdropBorderColor(
+ HealBot_Config.borcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.borcola[HealBot_Config.Current_Skin]);
+ else
+ HealBot_Action:SetBackdrop({
+ bgFile = "Interface\\Tooltips\\UI-Tooltip-Background",
+ edgeFile = "Interface\\Tooltips\\UI-Tooltip-Border",
+ tile = true, tileSize = 8, edgeSize = 16,
+ insets = { left = 4, right = 4, top = 4, bottom = 4 }
+ })
+ HealBot_Action:SetBackdropColor(
+ HealBot_Config.backcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.backcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.backcola[HealBot_Config.Current_Skin]);
+ HealBot_Action:SetBackdropBorderColor(
+ HealBot_Config.borcolr[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolg[HealBot_Config.Current_Skin],
+ HealBot_Config.borcolb[HealBot_Config.Current_Skin],
+ HealBot_Config.borcola[HealBot_Config.Current_Skin]);
+ end
+
+ HealBot_EnTextColorpickt:SetTextHeight(btextheight);
+ HealBot_DisTextColorpickt:SetTextHeight(btextheight);
+ HealBot_DebTextColorpickt:SetTextHeight(btextheight);
+ HealBot_EnTextColorpickt:SetText(HEALBOT_SKIN_ENTEXT);
+ HealBot_DisTextColorpickt:SetText(HEALBOT_SKIN_DISTEXT);
+ HealBot_DebTextColorpickt:SetText(HEALBOT_SKIN_DEBTEXT);
+ local barScale = HealBot_EnTextColorpick:GetScale();
+ HealBot_EnTextColorpick:SetScale(barScale + 0.01);
+ HealBot_EnTextColorpick:SetScale(barScale);
+ HealBot_DisTextColorpick:SetScale(barScale + 0.01);
+ HealBot_DisTextColorpick:SetScale(barScale);
+ HealBot_DebTextColorpick:SetScale(barScale + 0.01);
+ HealBot_DebTextColorpick:SetScale(barScale);
+
+ HealBot_Action_PartyChanged()
+end
+function HealBot_Options_AlertLevel_OnValueChanged(this)
+ HealBot_Config.AlertLevel = HealBot_Options_Pct_OnValueChanged(this);
+ HealBot_Action_Refresh();
+end
+function HealBot_Options_AutoShow_OnLoad(this)
+ getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_AUTOSHOW);
+end
+function HealBot_Options_AutoShow_OnClick(this)
+ HealBot_Config.AutoClose = this:GetChecked() or 0;
+ HealBot_Action_Refresh();
+end
+function HealBot_Options_PanelSounds_OnLoad(this)
+ getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_PANELSOUNDS);
+end
+function HealBot_Options_PanelSounds_OnClick(this)
+ HealBot_Config.PanelSounds = this:GetChecked() or 0;
+end
+function HealBot_Options_ActionMouseover_OnLoad(this, text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ActionMouseover_OnClick(this)
+ HealBot_Config.ActionMouseover = this:GetChecked() or 0;
+end
+function HealBot_Options_ActionLocked_OnLoad(this)
+ getglobal(this:GetName().."Text"):SetText(HEALBOT_OPTIONS_ACTIONLOCKED);
+end
+function HealBot_Options_ActionLocked_OnClick(this)
+ HealBot_Config.ActionLocked = this:GetChecked() or 0;
+end
+function HealBot_Options_HideOptions_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_HideOptions_OnClick(this)
+ HealBot_Config.HideOptions = this:GetChecked() or 0;
+ HealBot_Action_PartyChanged();
+end
+function HealBot_Options_HideAbort_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_HideAbort_OnClick(this)
+ HealBot_Config.HideAbort = this:GetChecked() or 0;
+ HealBot_Action_PartyChanged();
+end
+function HealBot_Options_GrowUpwards_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_GrowUpwards_OnClick(this)
+ HealBot_Config.GrowUpwards = this:GetChecked() or 0;
+ HealBot_Action_PartyChanged();
+end
+function HealBot_Options_QualityRange_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_QualityRange_OnClick(this)
+ HealBot_Config.QualityRange = this:GetChecked() or 0;
+ HealBot_Action_PartyChanged();
+end
+function HealBot_Options_ProtectPvP_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ProtectPvP_OnClick(this)
+ HealBot_Config.ProtectPvP = this:GetChecked() or 0;
+ HealBot_Action_Refresh();
+end
+function HealBot_Options_FramePaddingS_OnValueChanged(this)
+ if not HealBot_Config.bpadding then HealBot_Config.bpadding = {} end
+ HealBot_Config.bpadding[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
+function HealBot_Options_BorderThicknessS_OnValueChanged(this)
+ if not HealBot_Config.bboffset then HealBot_Config.bboffset = {} end
+ HealBot_Config.bboffset[HealBot_Config.Current_Skin] = this:GetValue();
+ getglobal(this:GetName().."Text"):SetText(this.text .. ": " .. this:GetValue());
+ HealBot_Action_ResetSkin()
+end
diff --git a/HealBot_Options_General.xml b/HealBot_Options_General.xml
new file mode 100644
index 0000000..410831c
--- /dev/null
+++ b/HealBot_Options_General.xml
@@ -0,0 +1,224 @@
+
+
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ActionLocked_OnLoad(this)
+ HealBot_Options_ActionLocked_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_GrowUpwards_OnLoad(this,HEALBOT_OPTIONS_GROWUPWARDS)
+ HealBot_Options_GrowUpwards_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+ getglobal(this:GetName().."Text"):SetText("Show Mana Bars");
+ this:SetChecked(HealBot_Config.ShowManaBars);
+
+
+ if (this:GetChecked()) then
+ HealBot_Config.ShowManaBars = 1;
+ else
+ HealBot_Config.ShowManaBars = 0;
+ end
+ HealBot_Action_Refresh();
+
+
+
+
+
+
+
+
+
+
+
+
+
+ getglobal(this:GetName().."Text"):SetText("For Healers Only");
+ this:SetChecked(HealBot_Config.ManaBarsHealersOnly);
+
+
+ if (this:GetChecked()) then
+ HealBot_Config.ManaBarsHealersOnly = 1;
+ else
+ HealBot_Config.ManaBarsHealersOnly = 0;
+ end
+ HealBot_Action_Refresh();
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_AutoShow_OnLoad(this)
+ HealBot_Options_AutoShow_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_PanelSounds_OnLoad(this)
+ HealBot_Options_PanelSounds_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ActionMouseover_OnLoad(this,"Enable Action Bar Mouseover")
+ HealBot_Options_ActionMouseover_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_HideOptions_OnLoad(this,HEALBOT_OPTIONS_HIDEOPTIONS)
+
+ HealBot_Options_HideOptions_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_HideAbort_OnLoad(this,HEALBOT_OPTIONS_HIDEABORT)
+ HealBot_Options_HideAbort_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_QualityRange_OnLoad(this,HEALBOT_OPTIONS_QUALITYRANGE)
+ HealBot_Options_QualityRange_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ProtectPvP_OnLoad(this,HEALBOT_OPTIONS_PROTECTPVP)
+ HealBot_Options_ProtectPvP_OnClick(this)
+
+
+
+
+
+
+
+
+
diff --git a/HealBot_Options_Healing.lua b/HealBot_Options_Healing.lua
new file mode 100644
index 0000000..a1d457f
--- /dev/null
+++ b/HealBot_Options_Healing.lua
@@ -0,0 +1,338 @@
+-- HealBot Options panel file: HealBot_Options_Healing.lua
+-- Split from original HealBot_Options.lua
+
+function HealBot_Options_GroupHeals_OnLoad(this,text)
+ this.text = text
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_GroupHeals_OnClick(this)
+ HealBot_Config.GroupHeals = this:GetChecked() or 0;
+ HealBot_RecalcParty();
+end
+function HealBot_Options_TankHeals_OnLoad(this,text)
+ this.text = text
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_TankHeals_OnClick(this)
+ HealBot_Config.TankHeals = this:GetChecked() or 0;
+ HealBot_RecalcParty();
+end
+function HealBot_Options_TargetHeals_OnLoad(this,text)
+ this.text = text
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_TargetHeals_OnClick(this)
+ HealBot_Config.TargetHeals = this:GetChecked() or 0;
+ HealBot_RecalcParty();
+end
+function HealBot_Options_EmergencyHeals_OnLoad(this,text)
+ this.text = text
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_EmergencyHeals_OnClick(this)
+ HealBot_Config.EmergencyHeals = this:GetChecked() or 0;
+ HealBot_RecalcParty();
+end
+function HealBot_Options_OverHeal_OnValueChanged(this)
+ HealBot_Config.OverHeal = HealBot_Options_Pct_OnValueChanged(this);
+end
+function HealBot_Options_EFClass_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_EFClass_OnClick(this)
+ if HealBot_Config.EmergencyFClass==1 then
+ HealBot_Config.EmergIncMelee[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
+ HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
+ elseif HealBot_Config.EmergencyFClass==2 then
+ HealBot_Config.EmergIncRange[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
+ HealBot_Config.EmergIncRange[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
+ elseif HealBot_Config.EmergencyFClass==3 then
+ HealBot_Config.EmergIncHealers[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
+ HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
+ elseif HealBot_Config.EmergencyFClass==4 then
+ HealBot_Config.EmergIncCustom[HEALBOT_DRUID] = HealBot_Options_EFClassDruid:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_HUNTER] = HealBot_Options_EFClassHunter:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_MAGE] = HealBot_Options_EFClassMage:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_PALADIN] = HealBot_Options_EFClassPaladin:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_PRIEST] = HealBot_Options_EFClassPriest:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_ROGUE] = HealBot_Options_EFClassRogue:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN] = HealBot_Options_EFClassShaman:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK] = HealBot_Options_EFClassWarlock:GetChecked() or 0;
+ HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR] = HealBot_Options_EFClassWarrior:GetChecked() or 0;
+ end
+ if HealBot_Config.EmergIncMonitor>10 then
+ HealBot_Action_PartyChanged();
+ end
+end
+local HealBot_Options_EmergencyFClass_List = {
+ HEALBOT_CLASSES_MELEE,
+ HEALBOT_CLASSES_RANGES,
+ HEALBOT_CLASSES_HEALERS,
+ HEALBOT_CLASSES_CUSTOM,
+}
+
+function HealBot_Options_EmergencyFClass_DropDown()
+ for i=1, getn(HealBot_Options_EmergencyFClass_List), 1 do
+ local info = {};
+ info.text = HealBot_Options_EmergencyFClass_List[i];
+ info.func = HealBot_Options_EmergencyFClass_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+end
+
+function HealBot_Options_EmergencyFClass_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_EmergencyFClass,HealBot_Options_EmergencyFClass_DropDown)
+end
+
+function HealBot_Options_EmergencyFClass_Refresh(onselect)
+ if not HealBot_Config.EmergencyFClass then return end
+ if not onselect then HealBot_Options_EmergencyFClass_Initialize() end -- or wrong menu may be used !
+ UIDropDownMenu_SetSelectedID(HealBot_Options_EmergencyFClass,HealBot_Config.EmergencyFClass)
+end
+
+function HealBot_Options_EmergencyFClass_OnLoad(this)
+ HealBot_Options_EmergencyFClass_Initialize()
+ UIDropDownMenu_SetWidth(100)
+end
+
+function HealBot_Options_EmergencyFClass_OnSelect()
+ HealBot_Config.EmergencyFClass = this:GetID()
+ HealBot_Options_EmergencyFClass_Refresh(true)
+ HealBot_Options_EFClass_Reset()
+end
+
+function HealBot_Options_EFClass_Reset()
+ if HealBot_Config.EmergencyFClass==1 then
+ HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_DRUID]);
+ HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_HUNTER]);
+ HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_MAGE]);
+ HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_PALADIN]);
+ HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_PRIEST]);
+ HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_ROGUE]);
+ HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN]);
+ HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK]);
+ HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR]);
+ elseif HealBot_Config.EmergencyFClass==2 then
+ HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_DRUID]);
+ HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_HUNTER]);
+ HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_MAGE]);
+ HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_PALADIN]);
+ HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_PRIEST]);
+ HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_ROGUE]);
+ HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_SHAMAN]);
+ HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_WARLOCK]);
+ HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncRange[HEALBOT_WARRIOR]);
+ elseif HealBot_Config.EmergencyFClass==3 then
+ HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_DRUID]);
+ HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_HUNTER]);
+ HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_MAGE]);
+ HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_PALADIN]);
+ HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_PRIEST]);
+ HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_ROGUE]);
+ HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN]);
+ HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK]);
+ HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR]);
+ elseif HealBot_Config.EmergencyFClass==4 then
+ HealBot_Options_EFClassDruid:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_DRUID]);
+ HealBot_Options_EFClassHunter:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_HUNTER]);
+ HealBot_Options_EFClassMage:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_MAGE]);
+ HealBot_Options_EFClassPaladin:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_PALADIN]);
+ HealBot_Options_EFClassPriest:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_PRIEST]);
+ HealBot_Options_EFClassRogue:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_ROGUE]);
+ HealBot_Options_EFClassShaman:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN]);
+ HealBot_Options_EFClassWarlock:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK]);
+ HealBot_Options_EFClassWarrior:SetChecked(HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR]);
+ end
+end
+
+--------------------------------------------------------------------------------
+
+local HealBot_Options_ExtraSort_List = {
+ HEALBOT_SORTBY_NAME,
+ HEALBOT_SORTBY_CLASS,
+ HEALBOT_SORTBY_GROUP,
+ HEALBOT_SORTBY_MAXHEALTH,
+}
+
+function HealBot_Options_ExtraSort_DropDown()
+ for i=1, getn(HealBot_Options_ExtraSort_List), 1 do
+ local info = {};
+ info.text = HealBot_Options_ExtraSort_List[i];
+ info.func = HealBot_Options_ExtraSort_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+end
+
+function HealBot_Options_ExtraSort_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_ExtraSort,HealBot_Options_ExtraSort_DropDown)
+end
+
+function HealBot_Options_ExtraSort_Refresh(onselect)
+ if not HealBot_Config.ExtraOrder then return end
+ if not onselect then HealBot_Options_ExtraSort_Initialize() end -- or wrong menu may be used !
+ UIDropDownMenu_SetSelectedID(HealBot_Options_ExtraSort,HealBot_Config.ExtraOrder)
+end
+
+function HealBot_Options_ExtraSort_OnLoad(this)
+ HealBot_Options_ExtraSort_Initialize()
+ UIDropDownMenu_SetWidth(100)
+end
+
+function HealBot_Options_ExtraSort_OnSelect()
+ HealBot_Config.ExtraOrder = this:GetID()
+ HealBot_Options_ExtraSort_Refresh(true)
+ HealBot_Action_PartyChanged()
+end
+
+--------------------------------------------------------------------------------
+
+function HealBot_Options_EmergencyFilter_DropDown()
+ for i=1, getn(HealBot_Options_EmergencyFilter_List), 1 do
+ local info = {};
+ info.text = HealBot_Options_EmergencyFilter_List[i];
+ info.func = HealBot_Options_EmergencyFilter_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+end
+
+
+function HealBot_Options_EmergencyFilter_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_EmergencyFilter,HealBot_Options_EmergencyFilter_DropDown)
+end
+
+
+function HealBot_Options_EmergencyFilter_Refresh(onselect)
+ if not HealBot_Config.EmergIncMonitor then return end
+ if not onselect then HealBot_Options_EmergencyFilter_Initialize() end -- or wrong menu may be used !
+ UIDropDownMenu_SetSelectedID(HealBot_Options_EmergencyFilter,HealBot_Config.EmergIncMonitor)
+end
+
+
+function HealBot_Options_EmergencyFilter_OnLoad(this)
+ HealBot_Options_EmergencyFilter_Initialize()
+ UIDropDownMenu_SetWidth(100)
+end
+
+
+function HealBot_Options_EmergencyFilter_OnSelect()
+ HealBot_Config.EmergIncMonitor = this:GetID()
+ HealBot_Options_EmergencyFilter_Refresh(true)
+ HealBot_Options_EmergencyFilter_Reset()
+end
+
+function HealBot_Options_EmergencyFilter_Reset()
+
+ HealBot_EmergInc[HEALBOT_DRUID] = 0;
+ HealBot_EmergInc[HEALBOT_HUNTER] = 0;
+ HealBot_EmergInc[HEALBOT_MAGE] = 0;
+ HealBot_EmergInc[HEALBOT_PALADIN] = 0;
+ HealBot_EmergInc[HEALBOT_PRIEST] = 0;
+ HealBot_EmergInc[HEALBOT_ROGUE] = 0;
+ HealBot_EmergInc[HEALBOT_SHAMAN] = 0;
+ HealBot_EmergInc[HEALBOT_WARLOCK] = 0;
+ HealBot_EmergInc[HEALBOT_WARRIOR] = 0;
+ if HealBot_Config.EmergIncMonitor==1 then
+ HealBot_EmergInc[HEALBOT_DRUID] = 1;
+ HealBot_EmergInc[HEALBOT_HUNTER] = 1;
+ HealBot_EmergInc[HEALBOT_MAGE] = 1;
+ HealBot_EmergInc[HEALBOT_PALADIN] = 1;
+ HealBot_EmergInc[HEALBOT_PRIEST] = 1;
+ HealBot_EmergInc[HEALBOT_ROGUE] = 1;
+ HealBot_EmergInc[HEALBOT_SHAMAN] = 1;
+ HealBot_EmergInc[HEALBOT_WARLOCK] = 1;
+ HealBot_EmergInc[HEALBOT_WARRIOR] = 1;
+ elseif HealBot_Config.EmergIncMonitor==2 then
+ HealBot_EmergInc[HEALBOT_DRUID] = 1;
+ elseif HealBot_Config.EmergIncMonitor==3 then
+ HealBot_EmergInc[HEALBOT_HUNTER] = 1;
+ elseif HealBot_Config.EmergIncMonitor==4 then
+ HealBot_EmergInc[HEALBOT_MAGE] = 1;
+ elseif HealBot_Config.EmergIncMonitor==5 then
+ HealBot_EmergInc[HEALBOT_PALADIN] = 1;
+ elseif HealBot_Config.EmergIncMonitor==6 then
+ HealBot_EmergInc[HEALBOT_PRIEST] = 1;
+ elseif HealBot_Config.EmergIncMonitor==7 then
+ HealBot_EmergInc[HEALBOT_ROGUE] = 1;
+ elseif HealBot_Config.EmergIncMonitor==8 then
+ HealBot_EmergInc[HEALBOT_SHAMAN] = 1;
+ elseif HealBot_Config.EmergIncMonitor==9 then
+ HealBot_EmergInc[HEALBOT_WARLOCK] = 1;
+ elseif HealBot_Config.EmergIncMonitor==10 then
+ HealBot_EmergInc[HEALBOT_WARRIOR] = 1;
+ elseif HealBot_Config.EmergIncMonitor==11 then
+ HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncMelee[HEALBOT_DRUID];
+ HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncMelee[HEALBOT_HUNTER];
+ HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncMelee[HEALBOT_MAGE];
+ HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncMelee[HEALBOT_PALADIN];
+ HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncMelee[HEALBOT_PRIEST];
+ HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncMelee[HEALBOT_ROGUE];
+ HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncMelee[HEALBOT_SHAMAN];
+ HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncMelee[HEALBOT_WARLOCK];
+ HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncMelee[HEALBOT_WARRIOR];
+ elseif HealBot_Config.EmergIncMonitor==12 then
+ HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncRange[HEALBOT_DRUID];
+ HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncRange[HEALBOT_HUNTER];
+ HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncRange[HEALBOT_MAGE];
+ HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncRange[HEALBOT_PALADIN];
+ HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncRange[HEALBOT_PRIEST];
+ HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncRange[HEALBOT_ROGUE];
+ HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncRange[HEALBOT_SHAMAN];
+ HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncRange[HEALBOT_WARLOCK];
+ HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncRange[HEALBOT_WARRIOR];
+ elseif HealBot_Config.EmergIncMonitor==13 then
+ HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncHealers[HEALBOT_DRUID];
+ HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncHealers[HEALBOT_HUNTER];
+ HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncHealers[HEALBOT_MAGE];
+ HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncHealers[HEALBOT_PALADIN];
+ HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncHealers[HEALBOT_PRIEST];
+ HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncHealers[HEALBOT_ROGUE];
+ HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncHealers[HEALBOT_SHAMAN];
+ HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncHealers[HEALBOT_WARLOCK];
+ HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncHealers[HEALBOT_WARRIOR];
+ elseif HealBot_Config.EmergIncMonitor==14 then
+ HealBot_EmergInc[HEALBOT_DRUID] = HealBot_Config.EmergIncCustom[HEALBOT_DRUID];
+ HealBot_EmergInc[HEALBOT_HUNTER] = HealBot_Config.EmergIncCustom[HEALBOT_HUNTER];
+ HealBot_EmergInc[HEALBOT_MAGE] = HealBot_Config.EmergIncCustom[HEALBOT_MAGE];
+ HealBot_EmergInc[HEALBOT_PALADIN] = HealBot_Config.EmergIncCustom[HEALBOT_PALADIN];
+ HealBot_EmergInc[HEALBOT_PRIEST] = HealBot_Config.EmergIncCustom[HEALBOT_PRIEST];
+ HealBot_EmergInc[HEALBOT_ROGUE] = HealBot_Config.EmergIncCustom[HEALBOT_ROGUE];
+ HealBot_EmergInc[HEALBOT_SHAMAN] = HealBot_Config.EmergIncCustom[HEALBOT_SHAMAN];
+ HealBot_EmergInc[HEALBOT_WARLOCK] = HealBot_Config.EmergIncCustom[HEALBOT_WARLOCK];
+ HealBot_EmergInc[HEALBOT_WARRIOR] = HealBot_Config.EmergIncCustom[HEALBOT_WARRIOR];
+ end
+
+ HealBot_Action_PartyChanged()
+end
+
+
+
+--------------------------------------------------------------------------------
+
+
+
+
+
+
+--------------------------------------------------------------------------------
+
diff --git a/HealBot_Options_Healing.xml b/HealBot_Options_Healing.xml
new file mode 100644
index 0000000..c2a5b4f
--- /dev/null
+++ b/HealBot_Options_Healing.xml
@@ -0,0 +1,359 @@
+
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_GroupHeals_OnLoad(this,HEALBOT_OPTIONS_GROUPHEALS)
+ HealBot_Options_GroupHeals_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_TankHeals_OnLoad(this,HEALBOT_OPTIONS_TANKHEALS)
+ HealBot_Options_TankHeals_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_TargetHeals_OnLoad(this,HEALBOT_OPTIONS_TARGETHEALS)
+ HealBot_Options_TargetHeals_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EmergencyHeals_OnLoad(this,HEALBOT_OPTIONS_EMERGENCYHEALS)
+ HealBot_Options_EmergencyHeals_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Pct_OnLoad(this,HEALBOT_OPTIONS_ALERTLEVEL)
+ HealBot_Options_AlertLevel_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Pct_OnLoad(this,HEALBOT_OPTIONS_OVERHEAL)
+ HealBot_Options_OverHeal_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EmergencyFilter_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ExtraSort_OnLoad(this)
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EmergencyFClass_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_DRUID)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_HUNTER)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_MAGE)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_PALADIN)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_PRIEST)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_ROGUE)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_SHAMAN)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_WARLOCK)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EFClass_OnLoad(this,HEALBOT_WARRIOR)
+ HealBot_Options_EFClass_OnClick(this)
+
+
+
+
+
+
+
+
diff --git a/HealBot_Options_Skins.lua b/HealBot_Options_Skins.lua
new file mode 100644
index 0000000..d8e4832
--- /dev/null
+++ b/HealBot_Options_Skins.lua
@@ -0,0 +1,128 @@
+-- HealBot Options panel file: HealBot_Options_Skins.lua
+-- Split from original HealBot_Options.lua
+
+function HealBot_Options_NewSkin_OnTextChanged(this)
+ local text= this:GetText()
+ if string.len(text)>0 then
+ HealBot_Options_NewSkinb:Enable();
+ else
+ HealBot_Options_NewSkinb:Disable();
+ end
+end
+function HealBot_Options_NewSkinb_OnClick(this)
+ HealBot_Config.numcols[HealBot_Options_NewSkin:GetText()] = HealBot_Config.numcols[HealBot_Config.Current_Skin]
+ HealBot_Config.btexture[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btexture[HealBot_Config.Current_Skin]
+ HealBot_Config.bcspace[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bcspace[HealBot_Config.Current_Skin]
+ HealBot_Config.brspace[HealBot_Options_NewSkin:GetText()] = HealBot_Config.brspace[HealBot_Config.Current_Skin]
+ HealBot_Config.bwidth[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bwidth[HealBot_Config.Current_Skin]
+ HealBot_Config.bheight[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bheight[HealBot_Config.Current_Skin]
+ HealBot_Config.btextenabledcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcolr[HealBot_Config.Current_Skin]
+ HealBot_Config.btextenabledcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcolg[HealBot_Config.Current_Skin]
+ HealBot_Config.btextenabledcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcolb[HealBot_Config.Current_Skin]
+ HealBot_Config.btextenabledcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextenabledcola[HealBot_Config.Current_Skin]
+ HealBot_Config.btextdisbledcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcolr[HealBot_Config.Current_Skin]
+ HealBot_Config.btextdisbledcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcolg[HealBot_Config.Current_Skin]
+ HealBot_Config.btextdisbledcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcolb[HealBot_Config.Current_Skin]
+ HealBot_Config.btextdisbledcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextdisbledcola[HealBot_Config.Current_Skin]
+ HealBot_Config.btextcursecolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecolr[HealBot_Config.Current_Skin]
+ HealBot_Config.btextcursecolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecolg[HealBot_Config.Current_Skin]
+ HealBot_Config.btextcursecolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecolb[HealBot_Config.Current_Skin]
+ HealBot_Config.btextcursecola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextcursecola[HealBot_Config.Current_Skin]
+ HealBot_Config.backcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcola[HealBot_Config.Current_Skin]
+ HealBot_Config.Barcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.Barcola[HealBot_Config.Current_Skin]
+ HealBot_Config.BarcolaInHeal[HealBot_Options_NewSkin:GetText()] = HealBot_Config.BarcolaInHeal[HealBot_Config.Current_Skin]
+ HealBot_Config.backcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcolr[HealBot_Config.Current_Skin]
+ HealBot_Config.backcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcolg[HealBot_Config.Current_Skin]
+ HealBot_Config.backcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.backcolb[HealBot_Config.Current_Skin]
+ HealBot_Config.borcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcolr[HealBot_Config.Current_Skin]
+ HealBot_Config.borcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcolg[HealBot_Config.Current_Skin]
+ HealBot_Config.borcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcolb[HealBot_Config.Current_Skin]
+ HealBot_Config.borcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.borcola[HealBot_Config.Current_Skin]
+ HealBot_Config.btextheight[HealBot_Options_NewSkin:GetText()] = HealBot_Config.btextheight[HealBot_Config.Current_Skin]
+ HealBot_Config.bardisa[HealBot_Options_NewSkin:GetText()] = HealBot_Config.bardisa[HealBot_Config.Current_Skin]
+ HealBot_Config.abortsize[HealBot_Options_NewSkin:GetText()] = HealBot_Config.abortsize[HealBot_Config.Current_Skin]
+ HealBot_Config.babortcolr[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcolr[HealBot_Config.Current_Skin]
+ HealBot_Config.babortcolg[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcolg[HealBot_Config.Current_Skin]
+ HealBot_Config.babortcolb[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcolb[HealBot_Config.Current_Skin]
+ HealBot_Config.babortcola[HealBot_Options_NewSkin:GetText()] = HealBot_Config.babortcola[HealBot_Config.Current_Skin]
+ HealBot_Config.ShowHeader[HealBot_Options_NewSkin:GetText()] = HealBot_Config.ShowHeader[HealBot_Config.Current_Skin]
+
+ table.insert(HealBot_Skins,2,HealBot_Options_NewSkin:GetText())
+ HealBot_Config.Skin_ID = 2;
+ HealBot_Config.Skins = HealBot_Skins; HealBot_Config.Current_Skin = HealBot_Options_NewSkin:GetText();
+ HealBot_Options_SetSkins()
+ HealBot_Options_NewSkin:SetText("")
+end
+function HealBot_Options_DeleteSkin_OnClick(this)
+ if HealBot_Config.Current_Skin~=HEALBOT_SKINS_STD then
+ HealBot_Config.numcols[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btexture[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.bcspace[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.brspace[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.bwidth[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.bheight[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextenabledcolr[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextenabledcolg[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextenabledcolb[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextenabledcola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextdisbledcolr[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextdisbledcolg[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextdisbledcolb[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextdisbledcola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextcursecolr[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextcursecolg[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextcursecolb[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextcursecola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.backcola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.Barcola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.BarcolaInHeal[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.backcolr[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.backcolg[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.backcolb[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.borcolr[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.borcolg[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.borcolb[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.borcola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.btextheight[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.bardisa[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.abortsize[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.babortcolr[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.babortcolg[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.babortcolb[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.babortcola[HealBot_Options_SkinsText:GetText()] = nil
+ HealBot_Config.ShowHeader[HealBot_Options_SkinsText:GetText()] = nil
+ table.remove(HealBot_Skins,HealBot_Config.Skin_ID)
+ HealBot_Config.Skin_ID = 1;
+ HealBot_Config.Skins = HealBot_Skins;
+ HealBot_Config.Current_Skin = HEALBOT_SKINS_STD;
+ HealBot_Options_SetSkins()
+ end
+end
+function HealBot_Options_Skins_DropDown()
+ for i=1, getn(HealBot_Skins), 1 do
+ local info = {};
+ info.text = HealBot_Skins[i];
+ info.func = HealBot_Options_Skins_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+end
+function HealBot_Options_Skins_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_Skins,HealBot_Options_Skins_DropDown)
+end
+function HealBot_Options_Skins_Refresh(onselect)
+ if not HealBot_Config.Skin_ID then return end
+ if not onselect then HealBot_Options_Skins_Initialize() end -- or wrong menu may be used !
+ UIDropDownMenu_SetSelectedID(HealBot_Options_Skins,HealBot_Config.Skin_ID)
+end
+function HealBot_Options_Skins_OnLoad(this)
+ HealBot_Options_Skins_Initialize()
+ UIDropDownMenu_SetWidth(100)
+end
+function HealBot_Options_Skins_OnSelect()
+ HealBot_Config.Skin_ID = this:GetID()
+ HealBot_Options_Skins_Refresh(true)
+ if this:GetID()>=1 then
+ HealBot_Config.Current_Skin = this:GetText()
+ HealBot_Options_SetSkins()
+ end
+end
diff --git a/HealBot_Options_Skins.xml b/HealBot_Options_Skins.xml
new file mode 100644
index 0000000..66190e5
--- /dev/null
+++ b/HealBot_Options_Skins.xml
@@ -0,0 +1,666 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Skins_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_NewSkin_OnTextChanged(this)
+
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ShowHeaders_OnLoad(this,HEALBOT_OPTIONS_SHOWHEADERS)
+ HealBot_Options_ShowHeaders_OnClick(this)
+
+
+
+
+
+ getglobal(this:GetName().."Text"):SetText("Class Colors")
+ HealBot_Config.bcolormode[HealBot_Config.Current_Skin] = (this:GetChecked() and 2 or 1); HealBot_Action_ResetSkin()
+
+
+
+
+
+ getglobal(this:GetName().."Text"):SetText("Font Outline")
+ HealBot_Config.bfontoutline[HealBot_Config.Current_Skin] = (this:GetChecked() and 1 or 0); HealBot_Action_ResetSkin()
+
+
+
+
+
+ getglobal(this:GetName().."Text"):SetText("1px Borders")
+ HealBot_Config.bborder[HealBot_Config.Current_Skin] = (this:GetChecked() and 1 or 2); HealBot_Action_ResetSkin()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINTEXTURE,1,14)
+ HealBot_Options_BarTextureS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINNUMCOLS,1,8)
+ HealBot_Options_BarNumColsS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINHEIGHT,10,100)
+ HealBot_Options_BarHeightS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINWIDTH,50,225)
+ HealBot_Options_BarWidthS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINBRSPACE,0,10)
+ HealBot_Options_BarBRSpaceS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINBCSPACE,0,25)
+ HealBot_Options_BarBCSpaceS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,"Frame Padding",0,50)
+ HealBot_Options_FramePaddingS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,"Solid Border",1,10)
+ HealBot_Options_BorderThicknessS_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Pct_OnLoad_MinMax(this,HEALBOT_OPTIONS_BARALPHA,0.25,1)
+ HealBot_Options_BarAlpha_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Pct_OnLoad_MinMax(this,HEALBOT_OPTIONS_BARALPHAINHEAL,0.05,0.75)
+ HealBot_Options_BarAlphaInHeal_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_Pct_OnLoad(this,HEALBOT_OPTIONS_BARALPHADIS)
+ HealBot_Options_BarAlphaDis_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_SKINFHEIGHT,7,18)
+ HealBot_Options_FontHeight_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_val_OnLoad(this,HEALBOT_OPTIONS_ABORTSIZE,0,15)
+ HealBot_Options_AbortBarSize_OnValueChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(70);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ this:SetMinMaxValues(0,100); this:SetValue(100);
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/HealBot_Options_Spells.lua b/HealBot_Options_Spells.lua
new file mode 100644
index 0000000..0607d7c
--- /dev/null
+++ b/HealBot_Options_Spells.lua
@@ -0,0 +1,195 @@
+-- HealBot Options panel file: HealBot_Options_Spells.lua
+-- Split from original HealBot_Options.lua
+
+function HealBot_ComboButtons_Button_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_ComboButtons_Button_OnClick(this,id)
+ if HealBot_Options_ComboButtons_Button>0 then
+ getglobal("HealBot_ComboButtons_Button"..HealBot_Options_ComboButtons_Button):SetChecked(nil);
+ end
+ HealBot_Options_ComboButtons_Button = id;
+ if HealBot_Options_ComboButtons_Button>0 then
+ getglobal("HealBot_ComboButtons_Button"..HealBot_Options_ComboButtons_Button):SetChecked(1);
+ end
+ HealBot_Options_ComboClass_Text()
+end
+function HealBot_Options_ShowTooltip_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ShowTooltip_OnClick(this)
+ HealBot_Config.ShowTooltip = this:GetChecked() or 0;
+end
+function HealBot_Options_ShowTooltipTarget_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ShowTooltipTarget_OnClick(this)
+ HealBot_Config.Tooltip_ShowTarget = this:GetChecked() or 0;
+end
+function HealBot_Options_ShowTooltipSpellDetail_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ShowTooltipSpellDetail_OnClick(this)
+ HealBot_Config.Tooltip_ShowSpellDetail = this:GetChecked() or 0;
+end
+function HealBot_Options_ShowTooltipInstant_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+function HealBot_Options_ShowTooltipInstant_OnClick(this)
+ HealBot_Config.Tooltip_Recommend = this:GetChecked() or 0;
+end
+local HealBot_Options_TooltipPos_List = {
+ HEALBOT_TOOLTIP_POSDEFAULT,
+ HEALBOT_TOOLTIP_POSLEFT,
+ HEALBOT_TOOLTIP_POSRIGHT,
+ HEALBOT_TOOLTIP_POSABOVE,
+ HEALBOT_TOOLTIP_POSBELOW,
+}
+
+function HealBot_Options_TooltipPos_DropDown()
+ for i=1, getn(HealBot_Options_TooltipPos_List), 1 do
+ local info = {};
+ info.text = HealBot_Options_TooltipPos_List[i];
+ info.func = HealBot_Options_TooltipPos_OnSelect;
+ UIDropDownMenu_AddButton(info);
+ end
+end
+
+function HealBot_Options_TooltipPos_Initialize()
+ UIDropDownMenu_Initialize(HealBot_Options_TooltipPos,HealBot_Options_TooltipPos_DropDown)
+end
+
+function HealBot_Options_TooltipPos_Refresh(onselect)
+ if not HealBot_Config.TooltipPos then return end
+ if not onselect then HealBot_Options_TooltipPos_Initialize() end -- or wrong menu may be used !
+ UIDropDownMenu_SetSelectedID(HealBot_Options_TooltipPos,HealBot_Config.TooltipPos)
+end
+
+function HealBot_Options_TooltipPos_OnLoad(this)
+ HealBot_Options_TooltipPos_Initialize()
+ UIDropDownMenu_SetWidth(128)
+end
+
+function HealBot_Options_TooltipPos_OnSelect()
+ HealBot_Config.TooltipPos = this:GetID()
+ HealBot_Options_TooltipPos_Refresh(true)
+end
+
+--------------------------------------------------------------------------------
+
+local HealBot_Options_ComboClass_List = {
+ HEALBOT_DRUID,
+ HEALBOT_PALADIN,
+ HEALBOT_PRIEST,
+ HEALBOT_SHAMAN,
+}
+
+
+
+
+
+
+
+
+function HealBot_Options_ComboClass_Text()
+ local class=UnitClass("Player");
+ local combo = HealBot_Config.KeyCombo[class]
+ local button = HealBot_Options_ComboClass_Button()
+ if combo then
+ HealBot_Options_Click:SetText(combo[button] or "")
+ HealBot_Options_Shift:SetText(combo["Shift"..button] or "")
+ HealBot_Options_Ctrl:SetText(combo["Ctrl"..button] or "")
+ HealBot_Options_ShiftCtrl:SetText(combo["ShiftCtrl"..button] or "")
+ end
+end
+
+
+
+
+
+
+function HealBot_Options_ComboClass_Button()
+ local button = "Left"
+ if HealBot_Options_ComboButtons_Button==2 then button = "Middle"; end
+ if HealBot_Options_ComboButtons_Button==3 then button = "Right"; end
+ if HealBot_Options_ComboButtons_Button==4 then button = "Button4"; end
+ if HealBot_Options_ComboButtons_Button==5 then button = "Button5"; end
+ return button;
+end
+
+
+
+
+ColorPickerFrame.func = HealBot_Returned_Colours
+
+
+
+
+
+--------------------------------------------------------------------------------
+
+function HealBot_Options_EditBox_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+
+function HealBot_Options_Click_OnTextChanged(this)
+ local class=UnitClass("Player");
+ local combo = HealBot_Config.KeyCombo[class]
+ local button = HealBot_Options_ComboClass_Button()
+ combo[button] = this:GetText()
+ HealBot_Options_KeyCombo_Change()
+end
+
+function HealBot_Options_Shift_OnTextChanged(this)
+ local class=UnitClass("Player");
+ local combo = HealBot_Config.KeyCombo[class]
+ local button = HealBot_Options_ComboClass_Button()
+ combo["Shift"..button] = this:GetText()
+ HealBot_Options_KeyCombo_Change()
+end
+
+function HealBot_Options_Ctrl_OnTextChanged(this)
+ local class=UnitClass("Player");
+ local combo = HealBot_Config.KeyCombo[class]
+ local button = HealBot_Options_ComboClass_Button()
+ combo["Ctrl"..button] = this:GetText()
+ HealBot_Options_KeyCombo_Change()
+end
+
+function HealBot_Options_ShiftCtrl_OnTextChanged(this)
+ local class=UnitClass("Player");
+ local combo = HealBot_Config.KeyCombo[class]
+ local button = HealBot_Options_ComboClass_Button()
+ combo["ShiftCtrl"..button] = this:GetText()
+ HealBot_Options_KeyCombo_Change()
+end
+
+function HealBot_Options_KeyCombo_Change()
+ local class=UnitClass("Player");
+ HealBot_Config.KeyCombo[class]=HealBot_Config.KeyCombo[class];
+
+end
+
+function HealBot_Options_EnableHealthy_OnLoad(this,text)
+ getglobal(this:GetName().."Text"):SetText(text);
+end
+
+function HealBot_Options_EnableHealthy_OnClick(this)
+ HealBot_Config.EnableHealthy = this:GetChecked() or 0;
+ HealBot_Action_EnableButtons();
+end
+
+--------------------------------------------------------------------------------
+
+
+
+
+
+HealBot_Options_CurrentPanel = 0;
+
+
+
+--------------------------------------------------------------------------------
+-- Chat Custom Messages UI Logic
+--------------------------------------------------------------------------------
+
diff --git a/HealBot_Options_Spells.xml b/HealBot_Options_Spells.xml
new file mode 100644
index 0000000..131768c
--- /dev/null
+++ b/HealBot_Options_Spells.xml
@@ -0,0 +1,308 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTONLEFT)
+ HealBot_ComboButtons_Button_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTONMIDDLE)
+ HealBot_ComboButtons_Button_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTONRIGHT)
+ HealBot_ComboButtons_Button_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTON4)
+ HealBot_ComboButtons_Button_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_ComboButtons_Button_OnLoad(this,HEALBOT_OPTIONS_BUTTON5)
+ HealBot_ComboButtons_Button_OnClick(this,this:GetID())
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_CLICK)
+
+
+ HealBot_Options_Click_OnTextChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_SHIFT)
+
+
+ HealBot_Options_Shift_OnTextChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_CTRL)
+
+
+ HealBot_Options_Ctrl_OnTextChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EditBox_OnLoad(this,HEALBOT_OPTIONS_SHIFTCTRL)
+
+
+ HealBot_Options_ShiftCtrl_OnTextChanged(this)
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_EnableHealthy_OnLoad(this,HEALBOT_OPTIONS_ENABLEHEALTHY)
+ HealBot_Options_EnableHealthy_OnClick(this)
+
+
+
+
+
+
+
+
+ this:SetBackdropBorderColor(0.4, 0.4, 0.4);
+ this:SetBackdropColor(0, 0, 0, 0);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ShowTooltip_OnLoad(this,HEALBOT_OPTIONS_SHOWTOOLTIP)
+ HealBot_Options_ShowTooltip_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_TooltipPos_OnLoad(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ShowTooltipTarget_OnLoad(this,HEALBOT_OPTIONS_SHOWUNITTOOLTIP)
+ HealBot_Options_ShowTooltipTarget_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ShowTooltipSpellDetail_OnLoad(this,HEALBOT_OPTIONS_SHOWDETTOOLTIP)
+ HealBot_Options_ShowTooltipSpellDetail_OnClick(this)
+
+
+
+
+
+
+
+
+
+
+
+ HealBot_Options_ShowTooltipInstant_OnLoad(this,HEALBOT_OPTIONS_SHOWRECTOOLTIP)
+ HealBot_Options_ShowTooltipInstant_OnClick(this)
+
+
+
+
+
+
+
+
+