Skip to content

Commit 7caaea0

Browse files
committed
Update chat commands, add gear upgrade and enchant overlay to Inspect UI equipment slots
1 parent f5a4b15 commit 7caaea0

3 files changed

Lines changed: 93 additions & 8 deletions

File tree

InspectFrame.lua

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,22 @@ local function CreateInspectSlot(parent, slotInfo, index, anchorPoint, xOff, yOf
272272
ilvlText:SetTextColor(1, 0.82, 0, 1)
273273
btn.ilvlText = ilvlText
274274

275+
-- Enchant status indicator (top-left corner, shown when enchanted)
276+
local enchantIndicator = btn:CreateTexture(nil, "OVERLAY", nil, 3)
277+
enchantIndicator:SetSize(11, 11)
278+
enchantIndicator:SetPoint("TOPLEFT", 2, -2)
279+
enchantIndicator:SetAtlas("Professions-Icon-Quality-Tier3-Small")
280+
enchantIndicator:Hide()
281+
btn.enchantIndicator = enchantIndicator
282+
283+
-- Upgrade track text (top-right corner)
284+
local upgradeText = btn:CreateFontString(nil, "OVERLAY")
285+
upgradeText:SetFont(STANDARD_TEXT_FONT, 9, "OUTLINE")
286+
upgradeText:SetPoint("TOPRIGHT", -2, -4)
287+
upgradeText:SetTextColor(1, 0.82, 0, 1)
288+
upgradeText:Hide()
289+
btn.upgradeText = upgradeText
290+
275291
btn.sockets = {}
276292
for i = 1, MAX_SOCKETS do
277293
local gem = btn:CreateTexture(nil, "OVERLAY", nil, 2)
@@ -807,6 +823,40 @@ local function UpdateSlot(btn, unit)
807823
end
808824
end
809825
end
826+
827+
-- Enchant status overlay
828+
btn.enchantIndicator:Hide()
829+
if ns.db and ns.db.global and ns.db.global.showEnchantStatus and link then
830+
local enchantID = link:match("item:%d+:(%d+)")
831+
if enchantID and tonumber(enchantID) > 0 then
832+
btn.enchantIndicator:Show()
833+
end
834+
end
835+
836+
-- Upgrade track overlay
837+
btn.upgradeText:Hide()
838+
if ns.db and ns.db.global and ns.db.global.showUpgradeTrack and link then
839+
if C_TooltipInfo and C_TooltipInfo.GetInventoryItem then
840+
local data = C_TooltipInfo.GetInventoryItem(unit, slotID)
841+
if data and data.lines then
842+
for _, line in ipairs(data.lines) do
843+
if line.leftText then
844+
local current, maximum = line.leftText:match("(%d+)/(%d+)")
845+
if current and maximum and line.leftText:lower():find("upgrade") then
846+
btn.upgradeText:SetText(current .. "/" .. maximum)
847+
if tonumber(current) >= tonumber(maximum) then
848+
btn.upgradeText:SetTextColor(0.0, 1.0, 0.0, 1)
849+
else
850+
btn.upgradeText:SetTextColor(1, 0.82, 0, 1)
851+
end
852+
btn.upgradeText:Show()
853+
break
854+
end
855+
end
856+
end
857+
end
858+
end
859+
end
810860
end
811861

812862
local function UpdateAllSlots()

README.md

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ High-resolution UI for the character, dressing room, and inspect windows with Mi
2323
### Dressing Room
2424
- Full Transmog-style 3-panel layout with outfit list, character preview, and built-in appearances browser
2525
- 5x6 model grid with search, source filters, and paging
26-
- All weapon types shown in a single merged list per weapon slot
26+
- Weapon category dropdown and class filter to browse appearances for any class
2727
- Click any appearance to preview it instantly; previewed items are highlighted with page navigation
2828
- Click equipment slots to browse appearances, right-click to undress
2929
- Save and load custom outfit sets
@@ -47,7 +47,10 @@ High-resolution UI for the character, dressing room, and inspect windows with Mi
4747

4848
### Quality of Life
4949
- Combat lockout option to prevent Character window from opening mid-fight
50+
- Optional enchant status and upgrade track overlays on equipment slots
51+
- Configurable window scaling (50-200%) for Character Panel, Inspect, and Dressing Room
5052
- Preview any item in the dressing room and then click the item slot to view it in your collection
53+
- Inspect another class and browse their collection in the dressing room with automatic class filtering
5154
- Search & Filter support for the Reputation and Currency tabs to quickly find what you need
5255
- Preview mounts in the dressing room with a dedicated mount browser, search, and paging across all mounts in the game
5356
- All windows remember their position between sessions
@@ -59,17 +62,24 @@ High-resolution UI for the character, dressing room, and inspect windows with Mi
5962

6063
## Configuration
6164

62-
`/mcu config` or Interface > AddOns > Modern Character UI.
65+
`/mcu` or Interface > AddOns > Modern Character UI.
6366

6467
- **Override Legacy Character Panel**: On
6568
- **Override Legacy Dressing Room**: On
6669
- **Override Legacy Inspect Window**: On
6770
- **Block Opening in Combat**: On
71+
- **Show Enchant Status**: Off — displays an indicator on enchanted equipment slots
72+
- **Show Upgrade Track**: Off — displays upgrade progress (e.g. 2/6) on equipment slots
73+
- **Character Panel Scale**: 50-200% (default 100%)
74+
- **Inspect Window Scale**: 50-200% (default 100%)
75+
- **Dressing Room Scale**: 50-200% (default 100%)
6876

6977
## Commands
7078

71-
- **`/mcu`**: Toggle character panel
72-
- **`/mcu config`**: Open settings
79+
- **`/mcu`**: Open settings
80+
- **`/mcu character`**: Toggle character panel
81+
- **`/mcu dress`**: Toggle dressing room
82+
- **`/mcu mounts`**: Open mount preview
7383

7484
## Feedback and Support
7585

Settings.lua

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,36 @@ function MCU:OnEnable()
4343
end
4444

4545
function MCU:ChatCommand(input)
46-
input = strtrim(input or "")
47-
if input == "settings" or input == "config" then
48-
LibStub("AceConfigDialog-3.0"):Open(addonName)
49-
else
46+
input = strlower(strtrim(input or ""))
47+
if input == "character" or input == "char" then
5048
ns:TogglePanel()
49+
elseif input == "dress" or input == "dressup" then
50+
if MCUDressingRoomFrame then
51+
if MCUDressingRoomFrame:IsShown() then
52+
MCUDressingRoomFrame:Hide()
53+
else
54+
MCUDressingRoomFrame:Show()
55+
end
56+
end
57+
elseif input == "mounts" or input == "mount" then
58+
if ns.PreviewMount then
59+
local defaultMountID
60+
for i = 1, C_MountJournal.GetNumDisplayedMounts() do
61+
local _, _, _, _, _, _, _, _, _, _, isCollected, mountID = C_MountJournal.GetDisplayedMountInfo(i)
62+
if isCollected then
63+
defaultMountID = mountID
64+
break
65+
end
66+
end
67+
if not defaultMountID then
68+
defaultMountID = C_MountJournal.GetDisplayedMountID(1)
69+
end
70+
if defaultMountID then
71+
ns:PreviewMount(defaultMountID)
72+
end
73+
end
74+
else
75+
LibStub("AceConfigDialog-3.0"):Open(addonName)
5176
end
5277
end
5378

0 commit comments

Comments
 (0)