Skip to content

Commit c46852e

Browse files
committed
11.1 Update 2
1 parent 5dc8d9a commit c46852e

File tree

5 files changed

+93
-41
lines changed

5 files changed

+93
-41
lines changed

PermoksAccountManager.lua

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -765,8 +765,13 @@ function PermoksAccountManager:Modernize(oldInternalVersion)
765765
end
766766

767767
if oldInternalVersion < 7 then
768+
self:AddLabelToDefaultCategory('general', 'veteran_crest')
769+
self:AddLabelToDefaultCategory('general', 'normal_crest')
770+
self:AddLabelToDefaultCategory('general', 'hero_crest')
771+
self:AddLabelToDefaultCategory('general', 'myth_crest')
768772
self:AddLabelToDefaultCategory('general', 'spark_drops')
769773

774+
self:AddLabelToDefaultCategory('currentweekly', 'undermine_weeklies', 19)
770775
self:AddLabelToDefaultCategory('currentweekly', 'undermine_rares')
771776

772777
self:AddLabelToDefaultCategory('raid', 'liberation_of_undermine')

db/db.lua

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ local default_categories = {
1616
'valorstones',
1717
'champion_crest',
1818
'veteran_crest',
19+
'normal_crest',
1920
'hero_crest',
2021
'myth_crest',
2122
'spark_current',
@@ -42,10 +43,11 @@ local default_categories = {
4243
valorstones = 8,
4344
champion_crest = 9,
4445
veteran_crest = 10,
45-
hero_crest = 11,
46-
myth_crest = 12,
47-
spark_current = 13,
48-
spark_drops = 14,
46+
normal_crest = 11,
47+
hero_crest = 12,
48+
myth_crest = 13,
49+
spark_current = 14,
50+
spark_drops = 15,
4951

5052
-- Probably interesting during the first weeks, might wanna (re-)move later
5153
separator2 = 20,
@@ -89,6 +91,7 @@ local default_categories = {
8991
'lesser_keyflame_weeklies',
9092
'greater_keyflame_weeklies',
9193
'severed_threads_pact_weekly',
94+
'undermine_weeklies',
9295

9396
'separator2',
9497
'isle_of_dorne_rares',
@@ -115,6 +118,7 @@ local default_categories = {
115118
lesser_keyflame_weeklies = 16,
116119
greater_keyflame_weeklies = 17,
117120
severed_threads_pact_weekly = 18,
121+
undermine_weeklies = 19,
118122

119123
separator2 = 20,
120124
isle_of_dorne_rares = 21,
@@ -1907,6 +1911,26 @@ PermoksAccountManager.quests = {
19071911
[83097] = { questType = 'weekly', log = true }, -- Skinning
19081912
[83098] = { questType = 'weekly', log = true }, -- Skinning
19091913
},
1914+
1915+
-- 11.1
1916+
undermine_weeklies = {
1917+
[85869] = { questType = 'weekly', log = true },
1918+
[86775] = { questType = 'weekly', log = true },
1919+
[85879] = { questType = 'weekly', log = true },
1920+
1921+
[85553] = { questType = 'weekly', log = true },
1922+
[85554] = { questType = 'weekly', log = true },
1923+
[85913] = { questType = 'weekly', log = true },
1924+
[85914] = { questType = 'weekly', log = true },
1925+
[85944] = { questType = 'weekly', log = true },
1926+
[85945] = { questType = 'weekly', log = true },
1927+
[85960] = { questType = 'weekly', log = true },
1928+
[85962] = { questType = 'weekly', log = true },
1929+
[86177] = { questType = 'weekly', log = true },
1930+
[86178] = { questType = 'weekly', log = true },
1931+
[86179] = { questType = 'weekly', log = true },
1932+
[86180] = { questType = 'weekly', log = true },
1933+
}
19101934
}
19111935

19121936
PermoksAccountManager.locale = {

modules/currencies.lua

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -256,31 +256,31 @@ local labelRows = {
256256

257257
-- 11.0
258258
veteran_crest = {
259-
label = 'Veteran Crests',
259+
label = 'Weathered Crests',
260260
type = 'crestcurrency',
261261
key = 3107,
262262
passRow = true,
263263
group = 'currency',
264264
version = WOW_PROJECT_MAINLINE
265265
},
266266
normal_crest = {
267-
label = 'Normal Crests',
267+
label = 'Carved Crests',
268268
type = 'crestcurrency',
269269
key = 3108,
270270
passRow = true,
271271
group = 'currency',
272272
version = WOW_PROJECT_MAINLINE
273273
},
274274
hero_crest = {
275-
label = 'Hero Crests',
275+
label = 'Runed Crests',
276276
type = 'crestcurrency',
277277
key = 3109,
278278
passRow = true,
279279
group = 'currency',
280280
version = WOW_PROJECT_MAINLINE
281281
},
282282
myth_crest = {
283-
label = 'Myth Crests',
283+
label = 'Gilded Crests',
284284
type = 'crestcurrency',
285285
key = 3110,
286286
passRow = true,
@@ -346,6 +346,7 @@ local labelRows = {
346346
type = 'currency',
347347
key = 3132,
348348
group = 'currency',
349+
hideIcon = true,
349350
version = WOW_PROJECT_MAINLINE,
350351
},
351352
empty_kajacola_can = {
@@ -737,7 +738,7 @@ function PermoksAccountManager:CreateCurrencyString(currencyInfo, abbreviateCurr
737738
local iconString = ''
738739
local options = self.db.global.options
739740
local globalCurrencyInfo = self.db.global.currencyInfo[currencyInfo.currencyType]
740-
local currencyIcon = globalCurrencyInfo.icon
741+
local currencyIcon = globalCurrencyInfo and globalCurrencyInfo.icon
741742
if not hideIcon and currencyIcon and options.currencyIcons then
742743
if customIcon then
743744
iconString = string.format('\124T%s:%d:%d:%d:%d\124t', customIcon.path or currencyIcon,

modules/factions.lua

Lines changed: 38 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,21 @@ local L = LibStub('AceLocale-3.0'):GetLocale(addonName)
33

44
local FACTION_STANDING_LABEL_CUSTOM = {}
55
local FACTION_BAR_COLORS_CUSTOM = {
6-
[1] = {r = 152, g = 32, b = 32},
7-
[2] = {r = 222, g = 0, b = 10},
8-
[3] = {r = 209, g = 102, b = 33},
9-
[4] = {r = 222, g = 255, b = 10},
10-
[5] = {r = 7, g = 255, b = 13},
11-
[6] = {r = 10, g = 222, b = 136},
12-
[7] = {r = 18, g = 224, b = 204},
13-
[8] = {r = 5, g = 255, b = 189},
6+
[1] = { r = 152, g = 32, b = 32 },
7+
[2] = { r = 222, g = 0, b = 10 },
8+
[3] = { r = 209, g = 102, b = 33 },
9+
[4] = { r = 222, g = 255, b = 10 },
10+
[5] = { r = 7, g = 255, b = 13 },
11+
[6] = { r = 10, g = 222, b = 136 },
12+
[7] = { r = 18, g = 224, b = 204 },
13+
[8] = { r = 5, g = 255, b = 189 },
1414
}
1515
do
1616
for standingID, color in pairs(FACTION_BAR_COLORS) do
17-
FACTION_BAR_COLORS_CUSTOM[standingID] = FACTION_BAR_COLORS_CUSTOM[standingID] or {r = color.r * 256, g = color.g * 256, b = color.b * 256}
17+
FACTION_BAR_COLORS_CUSTOM[standingID] = FACTION_BAR_COLORS_CUSTOM[standingID] or
18+
{ r = color.r * 256, g = color.g * 256, b = color.b * 256 }
1819
end
19-
FACTION_BAR_COLORS_CUSTOM[9] = {r = 16, g = 165, b = 202}
20+
FACTION_BAR_COLORS_CUSTOM[9] = { r = 16, g = 165, b = 202 }
2021

2122
for i = 1, 8 do
2223
FACTION_STANDING_LABEL_CUSTOM[i] = GetText('FACTION_STANDING_LABEL' .. i)
@@ -234,7 +235,7 @@ local labelRows = {
234235
key = 2590,
235236
group = 'reputation',
236237
version = WOW_PROJECT_MAINLINE
237-
},
238+
},
238239
hallowfall_arathi = {
239240
label = function()
240241
return PermoksAccountManager.factions[2570].localName or 'Hallowfall Arathi'
@@ -244,7 +245,7 @@ local labelRows = {
244245
key = 2570,
245246
group = 'reputation',
246247
version = WOW_PROJECT_MAINLINE
247-
},
248+
},
248249
the_assembly_of_the_deeps = {
249250
label = function()
250251
return PermoksAccountManager.factions[2594].localName or 'The Assembly of the Deeps'
@@ -254,7 +255,7 @@ local labelRows = {
254255
key = 2594,
255256
group = 'reputation',
256257
version = WOW_PROJECT_MAINLINE
257-
},
258+
},
258259
the_severed_threads = {
259260
label = function()
260261
return PermoksAccountManager.factions[2600].localName or 'The Severed Threads'
@@ -264,7 +265,7 @@ local labelRows = {
264265
key = 2600,
265266
group = 'reputation',
266267
version = WOW_PROJECT_MAINLINE
267-
},
268+
},
268269
the_general = {
269270
label = function()
270271
return PermoksAccountManager.factions[2605].localName or 'The General'
@@ -274,7 +275,7 @@ local labelRows = {
274275
key = 2605,
275276
group = 'reputation',
276277
version = WOW_PROJECT_MAINLINE
277-
},
278+
},
278279
the_vizier = {
279280
label = function()
280281
return PermoksAccountManager.factions[2607].localName or 'The Vizier'
@@ -284,7 +285,7 @@ local labelRows = {
284285
key = 2607,
285286
group = 'reputation',
286287
version = WOW_PROJECT_MAINLINE
287-
},
288+
},
288289
the_weaver = {
289290
label = function()
290291
return PermoksAccountManager.factions[2601].localName or 'The Weaver'
@@ -294,7 +295,7 @@ local labelRows = {
294295
key = 2601,
295296
group = 'reputation',
296297
version = WOW_PROJECT_MAINLINE
297-
},
298+
},
298299
brann_bronzebeard = {
299300
label = function()
300301
return PermoksAccountManager.factions[2640].localName or 'Brann Bronzebeard'
@@ -559,7 +560,7 @@ local labelRows = {
559560
version = WOW_PROJECT_CATACLYSM_CLASSIC,
560561
group = 'reputation'
561562
},
562-
the_ashen_verdict = {
563+
the_ashen_verdict = {
563564
label = function()
564565
local factionInfo = PermoksAccountManager.factions[1156]
565566
return factionInfo.localName or factionInfo.name
@@ -705,20 +706,22 @@ local friendshipStandings = {
705706
local GetFriendshipReputation = C_GossipInfo and C_GossipInfo.GetFriendshipReputation or GetFriendshipReputation
706707
--TODO: Rework after DF launch
707708
local function GetFactionOrFriendshipInfo(factionId, factionType)
708-
local hasReward, renown
709-
local name, _, standing, barMin, barMax, barValue
709+
local barMin, barMax, barValue = 0, 0, 0
710+
local hasReward, renown, name, _, standing
710711
if C_Reputation and C_Reputation.GetFactionDataByID then
711712
local factionData = C_Reputation.GetFactionDataByID(factionId)
712-
name = factionData.name
713-
standing = factionData.reaction
714-
barMin = factionData.currentReactionThreshold
715-
barMax = factionData.nextReactionThreshold
716-
barValue = factionData.currentStanding
717-
else
713+
if factionData then
714+
name = factionData.name
715+
standing = factionData.reaction
716+
barMin = factionData.currentReactionThreshold
717+
barMax = factionData.nextReactionThreshold
718+
barValue = factionData.currentStanding
719+
end
720+
else
718721
name, _, standing, barMin, barMax, barValue = GetFactionInfoByID(factionId)
719722
end
720723
local isParagon = C_Reputation.IsFactionParagon and C_Reputation.IsFactionParagon(factionId)
721-
724+
722725
if isParagon then
723726
barValue, barMax, _, hasReward = C_Reputation.GetFactionParagonInfo(factionId)
724727
barMin, standing, barValue = 0, 9, barValue % barMax
@@ -748,7 +751,6 @@ local function GetFactionOrFriendshipInfo(factionId, factionType)
748751
end
749752

750753
local function UpdateFaction(factionTable, factionId, standing, current, maximum, info, hasReward, renown)
751-
752754
factionTable[factionId] = factionTable[factionId] or {}
753755
local faction = factionTable[factionId]
754756
faction.standing = standing
@@ -808,7 +810,7 @@ local function convertStanding(standing)
808810
if friendshipStandings[standing] then
809811
return friendshipStandings[standing]
810812
else
811-
return standing:sub(1,1)
813+
return standing:sub(1, 1)
812814
end
813815
end
814816

@@ -832,10 +834,14 @@ function PermoksAccountManager:CreateFactionString(factionInfo)
832834
standing = factionInfo.standing
833835
end
834836

835-
local color = factionInfo.hasReward and 'ff00ff00' or CreateColor(standingColor.r / 255, standingColor.g / 255, standingColor.b / 255):GenerateHexColor()
837+
local color = factionInfo.hasReward and 'ff00ff00' or
838+
CreateColor(standingColor.r / 255, standingColor.g / 255, standingColor.b / 255):GenerateHexColor()
836839
if factionInfo.renown then
837-
return string.format('%s - %s /%s', BLUE_FONT_COLOR:WrapTextInColorCode(factionInfo.renown), AbbreviateNumbers(factionInfo.current or 0), AbbreviateNumbers(factionInfo.max or 0))
840+
return string.format('%s - %s /%s', BLUE_FONT_COLOR:WrapTextInColorCode(factionInfo.renown),
841+
AbbreviateNumbers(factionInfo.current or 0), AbbreviateNumbers(factionInfo.max or 0))
838842
elseif factionInfo.max then
839-
return string.format('|c%s%s|r/%s |cff%02X%02X%02X%s|r', color, AbbreviateLargeNumbers(factionInfo.current or 0), AbbreviateNumbers(factionInfo.max or 0), standingColor.r, standingColor.g, standingColor.b, convertStanding(standing))
843+
return string.format('|c%s%s|r/%s |cff%02X%02X%02X%s|r', color, AbbreviateLargeNumbers(factionInfo.current or 0),
844+
AbbreviateNumbers(factionInfo.max or 0), standingColor.r, standingColor.g, standingColor.b,
845+
convertStanding(standing))
840846
end
841847
end

modules/quests.lua

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1223,6 +1223,22 @@ local labelRows = {
12231223
showAll = true,
12241224
version = WOW_PROJECT_MAINLINE
12251225
},
1226+
undermine_weeklies = {
1227+
IDS = {85869, 86775, 85879, 85553, 85554, 85913, 85914, 85944, 85945, 85960, 85962, 86177, 86178, 86179, 86180},
1228+
label = 'Undermine Weeklies',
1229+
type = 'quest',
1230+
questType = 'weekly',
1231+
warband = true,
1232+
visibility = 'visible',
1233+
group = 'resetWeekly',
1234+
tooltip = true,
1235+
customTooltip = function(...)
1236+
PermoksAccountManager:CompletedQuestsTooltip_OnEnter(...)
1237+
end,
1238+
required = 7,
1239+
showAll = true,
1240+
version = WOW_PROJECT_MAINLINE
1241+
},
12261242
-- professions
12271243
knowledge_tww_treasures = {
12281244
label = 'Loot Knowledge',

0 commit comments

Comments
 (0)