Skip to content

Commit 75529ae

Browse files
committed
[Statuses\Resource] Add Current Amount as Text
1 parent d883822 commit 75529ae

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

Statuses/Resource.lua

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -453,12 +453,25 @@ function PlexusStatusResource:UpdateUnitResource(unitid)
453453
end
454454
end
455455

456+
local text = current
457+
if type(current) == "number" then
458+
if Plexus:IsRetailWow() then
459+
text = Plexus:AbbreviateNumbers(current)
460+
else
461+
if current > 9999 then
462+
text = format("%.0fk", current / 1000)
463+
elseif current > 999 then
464+
text = format("%.1fk", current / 1000)
465+
end
466+
end
467+
end
468+
456469
self.core:SendStatusGained(
457470
unitGUID, "unit_resource",
458471
priority,
459472
nil,
460473
color,
461-
nil,
474+
text,
462475
current,max,
463476
nil
464477
)

0 commit comments

Comments
 (0)