Skip to content

Commit

Permalink
Merge branch 'release/3.6.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
kaytotes committed Jul 6, 2021
2 parents 91dcb19 + 1f70370 commit ebdd97f
Show file tree
Hide file tree
Showing 7 changed files with 72 additions and 5 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -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.
Expand Down
4 changes: 2 additions & 2 deletions ImprovedBlizzardUI.toc
Original file line number Diff line number Diff line change
@@ -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
Expand Down
15 changes: 15 additions & 0 deletions config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -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),
Expand Down Expand Up @@ -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',
Expand Down
5 changes: 4 additions & 1 deletion core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down
2 changes: 1 addition & 1 deletion helpers.lua
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
44 changes: 43 additions & 1 deletion modules/frames/party.lua
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand All @@ -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

--[[
Expand Down Expand Up @@ -140,6 +180,8 @@ function ImpUI_Party:OnEnable()

ImpUI_Party:LoadPosition();
ImpUI_Party:StyleFrames();

self:RegisterEvent('GROUP_ROSTER_UPDATE');
end

--[[
Expand Down
1 change: 1 addition & 0 deletions modules/misc/chat.lua
Original file line number Diff line number Diff line change
Expand Up @@ -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',
Expand Down

0 comments on commit ebdd97f

Please sign in to comment.