diff --git a/Icons/Alliance.tga b/Icons/Alliance.tga new file mode 100644 index 0000000..1f6925f Binary files /dev/null and b/Icons/Alliance.tga differ diff --git a/Icons/Horde.tga b/Icons/Horde.tga new file mode 100644 index 0000000..7e8e7c9 Binary files /dev/null and b/Icons/Horde.tga differ diff --git a/RepHub.lua b/RepHub.lua index 4f30c0e..c85e464 100755 --- a/RepHub.lua +++ b/RepHub.lua @@ -321,17 +321,32 @@ function RepHub:GetRepHubTableData() highestStandingCharacterNameTextColor = classesColor[self.db.global.characterClasses[highestStandingCharacterNameText]] end + local factionAdditionalInfo = RepHub:GetFactionAdditionalInfo(factionData.name) + local factionNameText = factionData.name + if factionAdditionalInfo then + local sideIcon = "" + if factionAdditionalInfo.side == "Alliance" then + sideIcon = "Interface\\Addons\\RepHub\\Icons\\Alliance" + elseif factionAdditionalInfo.side == "Horde" then + sideIcon = "Interface\\Addons\\RepHub\\Icons\\Horde" + end + if sideIcon ~= "" then + sideIcon = string.format("\124T%s:%d\124t", sideIcon, 15) + factionNameText = sideIcon .. " " .. factionNameText + end + end + local currentGroupText = factionData.currentGroup local currentGroupIcon = groupsIcons[currentGroupText] or nil if currentGroupIcon then - local currentGroupIcon = string.format("\124T%s:%d\124t", currentGroupIcon, 25) + currentGroupIcon = string.format("\124T%s:%d\124t", currentGroupIcon, 25) currentGroupText = currentGroupIcon .. " " .. currentGroupText end table.insert(dataArr, { ["cols"] = { - { ["value"] = factionData.name }, + { ["value"] = factionNameText }, { ["value"] = currentGroupText }, { ["value"] = highestStandingText, ["color"] = highestStandingTextColor }, { ["value"] = highestStandingCharacterNameText, ["color"] = highestStandingCharacterNameTextColor },