26c8dda - Remove heal absorb from player and target frames
[wowui.git] / OmaUF / Settings.lua
1 -- Settings.lua
2 local PowerTypeMana = Enum.PowerType.Mana;
3 local PowerTypeRage = Enum.PowerType.Rage;
4 local PowerTypeFocus = Enum.PowerType.Focus;
5 local PowerTypeEnergy = Enum.PowerType.Energy;
6 local PowerTypeRunic = Enum.PowerType.RunicPower;
7 local rawget = rawget;
8
9 -- configurable settings
10 -- character specific settings
11 local charDefaults = {
12     AnchorX = 0,
13     AnchorY = -330,
14     Clickheal = {
15     },
16 };
17 local chars = {
18     ["Stormreaver"] = {
19         ["Vildan"] = {
20             Clickheal = {
21                 ["type1"] = "spell",
22                 ["type2"] = "spell",
23                 ["shift-type1"] = "spell",
24                 ["shift-type2"] = "spell",
25                 ["ctrl-type1"] = "macro",
26                 ["alt-type2"] = "spell",
27                 ["alt-shift-type1"] = "spell",
28                 ["alt-shift-type2"] = "spell",
29                 ["spell1"] = "Holy Light",
30                 ["spell2"] = "Bestow Faith",
31                 ["shift-spell1"] = "Flash of Light",
32                 ["shift-spell2"] = "Light of the Martyr",
33                 ["ctrl-macro1"] = "Cleansing",
34                 ["alt-spell2"] = "Lay on Hands",
35                 ["alt-shift-spell1"] = "Beacon of Light",
36                 ["alt-shift-spell2"] = "Beacon of Faith",
37             },
38         },
39         ["Gedren"] = {
40             Clickheal = {
41                 ["type1"] = "spell",
42                 ["type2"] = "spell",
43                 ["shift-type1"] = "spell",
44                 ["shift-type2"] = "spell",
45                 ["ctrl-type1"] = "spell",
46                 ["alt-type2"] = "spell",
47                 ["spell1"] = "Healing Touch",
48                 ["spell2"] = "Lifebloom",
49                 ["shift-spell1"] = "Regrowth",
50                 ["shift-spell2"] = "Swiftmend",
51                 ["ctrl-spell1"] = "Nature's Cure",
52                 ["alt-spell2"] = "Rebirth",
53             },
54         },
55     },
56 };
57
58 -- account-wide settings
59 local settings = {
60     Player = {
61         Width = 160,
62         Height = 50,
63         AnchorX = -300,
64         AnchorY = -175,
65     },
66     Pet = {
67         Width = 80,
68         Height = 25,
69         AnchorX = -10,
70         AnchorY = 0,
71     },
72     Target = {
73         Width = 160,
74         Height = 50,
75         AnchorX = 300,
76         AnchorY = -175,
77     },
78     Boss = {
79         Width = 140,
80         Height = 30,
81         AnchorX = 550,
82         AnchorY = 300,
83     },
84     BaseColor = {0, 0, 0, 0.5},
85     BgColor = {0.1, 0.1, 0.1, 0.4},
86     HealthColor = {0.5, 0.5, 0.5},
87     ShieldColor = {0.1, 0.8, 1},
88     ShieldhlColor = {0.5, 0.8, 1},
89     HealpredColor = {0.5, 0.6, 0.5},
90     HealabsorbColor = {0.1, 0.1, 0.1},
91     PowerColors = {
92         [PowerTypeMana] = {0, 0.5, 1},
93         [PowerTypeRage] = {1, 0, 0},
94         [PowerTypeFocus] = {1, 0.5, 0},
95         [PowerTypeEnergy] = {1, 0.8, 0},
96         [PowerTypeRunic] = {0.8, 0, 0.2},
97     },
98 };
99 OmaUFSettings = settings;
100 -- watch to not remove mana entry
101 setmetatable(settings.PowerColors, {__index = function(t) return rawget(t, PowerTypeMana) end});
102
103 function OmaUFLoadChar()
104     local name, realm = UnitFullName("player");
105     if chars[realm] and chars[realm][name] then
106         settings.Character = chars[realm][name];
107     else
108         settings.Character = charDefaults;
109     end
110 end