diff --git a/CHANGELOG.md b/CHANGELOG.md index 5922667..446192a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Improved Blizzard UI Changelog +3.6.0 - 9.1 Support. +3.6.0 - Class Coloured Party Frames +3.6.0 - Fix Zandalari Troll Loot String +3.5.1 - Fix TBC Focus Frame Dragging +3.5.0 - Full TBC Support. +3.5.0 - Fix Party Frames 3.4.1 - Disabled Party Frames in TBC. 3.4.0 - The Burning Crusade Classic Support 3.3.1 - More Focus Frame Improvements. diff --git a/ImprovedBlizzardUI.toc b/ImprovedBlizzardUI.toc index b682d47..e49791b 100644 --- a/ImprovedBlizzardUI.toc +++ b/ImprovedBlizzardUI.toc @@ -1,9 +1,9 @@ -## Interface: 90005 +## Interface: 90100 ## Title: Improved Blizzard UI ## Notes: A variety of improvements to the default Blizzard UI ## Version: @project-version@ ## Author: Kaytotes -## SavedVariables: ImpUI_DB +## SavedVariables: ImpBlizzardUI_DB ## OptionalDeps: Ace3, Blizzard_TalkingHeadUI, Blizzard_WeeklyRewards ## X-Embeds: Ace3 ## X-Curse-Project-ID: 103336 diff --git a/config.lua b/config.lua index 7a5b75e..a35e130 100644 --- a/config.lua +++ b/config.lua @@ -75,6 +75,7 @@ ImpUI_Config.defaults = { partyFrameScale = 1.4, partyFramePosition = Helpers.pack_position('CENTER', UIParent, 'CENTER', -550, 100), + partyClassColours = true, focusFrameScale = 0.9, focusFramePosition = Helpers.pack_position('CENTER', UIParent, 'CENTER', -500.0, -250.0), @@ -319,6 +320,20 @@ ImpUI_Config.options = { hidden = false, }, + partyClassColours = { + type = 'toggle', + name = L['Display Class Colours'], + desc = '', + get = function () + return ImpUI.db.profile.partyClassColours; + end, + set = function (info, newValue) + ImpUI.db.profile.partyClassColours = newValue; + ImpUI_Party:UpdateColours(); + end, + order = 13, + }, + -- Focus Frames Section focusHeader = { type = 'header', diff --git a/core.lua b/core.lua index 1e24715..7ae3d23 100644 --- a/core.lua +++ b/core.lua @@ -39,10 +39,13 @@ local function GetDraggables() }; if (Helpers.IsRetail()) then - table.insert(draggables, 'ImpUI_Focus'); table.insert(draggables, 'ImpUI_TalkingHead'); end + if (Helpers.IsRetail() or Helpers.IsTBC()) then + table.insert(draggables, 'ImpUI_Focus'); + end + return draggables; end diff --git a/helpers.lua b/helpers.lua index 1bf26c1..a4156f1 100644 --- a/helpers.lua +++ b/helpers.lua @@ -52,7 +52,7 @@ end ]] function Helpers.GetSupportedBuild() if (Helpers.IsRetail()) then - return '9.0.5'; + return '9.1.0'; end if (Helpers.IsTBC()) then diff --git a/modules/frames/party.lua b/modules/frames/party.lua index c0ae0af..5d124a7 100644 --- a/modules/frames/party.lua +++ b/modules/frames/party.lua @@ -22,12 +22,13 @@ function ImpUI_Party:StyleFrames() -- Fonts local font = Helpers.get_styled_font(ImpUI.db.profile.primaryInterfaceFont); + local size = 10; -- Style Each Party Frame for i = 1, 4 do -- Update Fonts _G["PartyMemberFrame"..i.."Name"]:SetTextColor(font.r, font.g, font.b, font.a); - _G["PartyMemberFrame"..i.."Name"]:SetFont(font.font, 10, font.flags); + _G["PartyMemberFrame"..i.."Name"]:SetFont(font.font, size, font.flags); if (Helpers.IsRetail()) then _G["PartyMemberFrame"..i.."HealthBarText"]:SetFont(font.font, 8, font.flags); @@ -39,6 +40,45 @@ function ImpUI_Party:StyleFrames() _G["PartyMemberFrame"..i.."ManaBarTextRight"]:SetFont(font.font, 8, font.flags); end end + + ImpUI_Party:UpdateColours(); +end + +--[[ + Simply updates the class colouring for all party members. + + @ return void +]] +function ImpUI_Party:UpdateColours() + if (IsInGroup() == false) then return end + + local font = Helpers.get_styled_font(ImpUI.db.profile.primaryInterfaceFont); + local enabled = ImpUI.db.profile.partyClassColours; + + for i = 1, 4 do + local unitName = "party"..i; + if (UnitExists(unitName)) then + if (UnitClass(unitName)) then + local c = Helpers.GetClassColour(unitName); + local nameFrame = _G["PartyMemberFrame"..i.."Name"]; + + if (enabled) then + nameFrame:SetTextColor(c.r, c.g, c.b, 1); + else + nameFrame:SetTextColor(font.r, font.g, font.b, font.a); + end + end + end + end +end + +--[[ + Fires when the party a player is in changes / updates with new members. + + @ return void +]] +function ImpUI_Party:GROUP_ROSTER_UPDATE() + ImpUI_Party:UpdateColours(); end --[[ @@ -140,6 +180,8 @@ function ImpUI_Party:OnEnable() ImpUI_Party:LoadPosition(); ImpUI_Party:StyleFrames(); + + self:RegisterEvent('GROUP_ROSTER_UPDATE'); end --[[ diff --git a/modules/misc/chat.lua b/modules/misc/chat.lua index 6f8fc40..c3d058e 100644 --- a/modules/misc/chat.lua +++ b/modules/misc/chat.lua @@ -17,6 +17,7 @@ local strings = { CURRENCY_GAINED_MULTIPLE = '|cffFFFF00+ %s |cffFFFF00(%d)', CURRENCY_GAINED_MULTIPLE_BONUS = '|cffFFFF00+ %s |cffFFFF00(%d)', YOU_LOOT_MONEY = '|cffFFFF00+ %s', + ERR_AUTOLOOT_MONEY_S = '|cffFFFF00+ %s', LOOT_ITEM_SELF = '|cffFFFF00+ %s', LOOT_ITEM_SELF_MULTIPLE = '|cffFFFF00+ %s |cffFFFF00(%d)', LOOT_ITEM_CREATED_SELF = '|cffFFFF00+ %s',