Skip to content

Commit

Permalink
* Support Paragon reputation for Renown
Browse files Browse the repository at this point in the history
* Hide reputation values for Exalted standing
  • Loading branch information
azuraji committed Jun 28, 2023
1 parent 0c7eeb4 commit 77d94ce
Show file tree
Hide file tree
Showing 12 changed files with 32 additions and 14 deletions.
22 changes: 20 additions & 2 deletions FuBar_FuXPFu/FuBar_FuXPFu.lua
Original file line number Diff line number Diff line change
Expand Up @@ -748,6 +748,13 @@ function FuXP:OnTextUpdate()
currentRep = renownReputationData.renownReputationEarned

factionStandingLabel = "|cff00b0bdRenown " .. renownReputationData.renownLevel

if currentRepParagon ~= nil then --Renown + Paragon
maxRep = maxRepParagon
currentRep = currentRepParagon % maxRepParagon

factionStandingLabel = factionStandingLabel .. "|r |cffffffff+|r |cffB2D7F7Paragon"
end
elseif currentRepParagon ~= nil then --Paragon
minRep = 0
maxRep = maxRepParagon
Expand Down Expand Up @@ -794,7 +801,11 @@ function FuXP:OnTextUpdate()
self:SetText(string.format(L["%s (%s) // XP: %3.0f%%/%s to go"], name, factionStandingLabel .. "|r", math.floor(xp / max * 100), numWithCommas(toGo)))
end
else
self:SetText(string.format(L["%s: %3.0f%% (%s/%s) (%s)"], name, ((currentRep - minRep) / (maxRep - minRep)) * 100 , numWithCommas(currentRep - minRep), numWithCommas(maxRep - minRep), factionStandingLabel .. "|r"))
if currentRep == minRep and minRep == maxRep then -- Max reputation
self:SetText(string.format("%s (%s)", name, factionStandingLabel .. "|r"))
else
self:SetText(string.format(L["%s: %3.0f%% (%s/%s) (%s)"], name, ((currentRep - minRep) / (maxRep - minRep)) * 100 , numWithCommas(currentRep - minRep), numWithCommas(maxRep - minRep), factionStandingLabel .. "|r"))
end
end
else
self:SetText(string.format(L["XP: %3.0f%%/%s to go"], math.floor(xp / max * 100), numWithCommas(toGo)))
Expand Down Expand Up @@ -871,7 +882,14 @@ function FuXP:OnTooltipUpdate()
maxRep = renownReputationData.renownLevelThreshold
currentRep = renownReputationData.renownReputationEarned

standing = "|cff00b0bdRenown " .. renownReputationData.renownLevel .. "|r" --Renown
standing = "|cff00b0bdRenown " .. renownReputationData.renownLevel .. "|r" --Renown

if currentRepParagon ~= nil then --Renown + Paragon
maxRep = maxRepParagon
currentRep = currentRepParagon % maxRepParagon

standing = standing .. " |cffffffff+|r |cffB2D7F7Paragon|r"
end
elseif currentRepParagon ~= nil then
maxRep = maxRepParagon
currentRep = currentRepParagon % maxRepParagon
Expand Down
4 changes: 2 additions & 2 deletions FuBar_FuXPFu/FuBar_FuXPFu.toc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
## Interface: 100005
## Interface: 100100
## Title: FuBar - |cffffffffFuXP|r|cff00ff00Fu|r
## Title-koKR: |CFF99FF99F|CFFFFFFFFu|CFF99FF99B|CFFFFFFFFar - |cffffffffFuXP|r|cff00ff00Fu|r
## Notes: Lightweight XP Bar
## Notes-zhCN: 迷你经验条
## Notes-zhTW: 輕量級的經驗值條模組。
## Version: 10.0.5.0
## Version: 10.1.0.0
## Author: Wobin, azuraji
## eMail: [email protected]
## X-Credits: Bant (For the design)
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceAddon-2.0/AceAddon-2.0.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceConsole-2.0/AceConsole-2.0.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceDB-2.0/AceDB-2.0.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceEvent-2.0/AceEvent-2.0.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceHook-2.1/AceHook-2.1.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100

## Title: Lib: AceHook-2.1
## Notes: AddOn development framework
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceLibrary/AceLibrary.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceLocale-2.2/AceLocale-2.2.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/AceOO-2.0/AceOO-2.0.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1101
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/CrayonLib/AceLibrary/AceLibrary.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## X-Curse-Packaged-Version: r1094
## X-Curse-Project-Name: Ace2
## X-Curse-Project-ID: ace2
Expand Down
2 changes: 1 addition & 1 deletion FuBar_FuXPFu/Libs/CrayonLib/CrayonLib.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100002
## Interface: 100100
## LoadOnDemand: 1
## Title: Lib: Crayon-2.0
## Notes: A library to provide coloring tools.
Expand Down

0 comments on commit 77d94ce

Please sign in to comment.