View Single Post
03-08-19, 09:44 AM   #2
Fizzlemizz
I did that?
 
Fizzlemizz's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Dec 2011
Posts: 1,877
BreakupLargeNumbers has been broken for a while even though it is still used in the stock UI code and not yet been replaced by FormatLargeNumber.

If you are putting it into an addon of your own that loads at startup then something like:

Lua Code:
  1. hooksecurefunc(StatusTrackingBarManager, "AddBarFromTemplate", function(self, frameType, template)
  2.     if template == "AzeriteBarTemplate" then
  3.         hooksecurefunc(StatusTrackingBarManager.bars[5], "UpdateOverlayFrameText", function(self)
  4.             if ( self.OverlayFrame.Text:IsShown() ) then
  5.                 local xp = self.StatusBar:GetAnimatedValue();
  6.                 local _, xpForNextPoint = self.StatusBar:GetMinMaxValues();
  7.                 if ( xpForNextPoint > 0 ) then
  8.                     self.OverlayFrame.Text:SetFormattedText(ARTIFACT_POWER_BAR, FormatLargeNumber(xp), FormatLargeNumber(xpForNextPoint).." "..math.floor((xp/xpForNextPoint)*100).."%");
  9.                 end
  10.             end
  11.         end)
  12.     end
  13. end)
__________________
Fizzlemizz
Maintainer of Discord Unit Frames and Discord Art.
Author of FauxMazzle, FauxMazzleHUD and Move Pad Plus.

Last edited by Fizzlemizz : 03-08-19 at 09:50 AM.
  Reply With Quote