Add all shared achievements
This commit is contained in:
@@ -4,6 +4,11 @@ function()
|
|||||||
if not targetGuid then return end
|
if not targetGuid then return end
|
||||||
if not string.match(targetGuid, "Player") then return end
|
if not string.match(targetGuid, "Player") then return end
|
||||||
local targetName = UnitName("target")
|
local targetName = UnitName("target")
|
||||||
if not aura_env.config.recsan and WeakAurasSaved.Cyka.AchievementSniffer[targetName] then return end
|
|
||||||
|
local should = false
|
||||||
|
if not WeakAurasSaved.Cyka.AchievementSniffer[targetName] then should = true end
|
||||||
|
if aura_env.config.rescan then should = true end
|
||||||
|
if not should then return end
|
||||||
|
|
||||||
aura_env.Scan(targetName)
|
aura_env.Scan(targetName)
|
||||||
end
|
end
|
@@ -10,63 +10,184 @@ if not WeakAurasSaved.Cyka then WeakAurasSaved.Cyka = {} end
|
|||||||
if not WeakAurasSaved.Cyka.AchievementSniffer then WeakAurasSaved.Cyka.AchievementSniffer = {} end
|
if not WeakAurasSaved.Cyka.AchievementSniffer then WeakAurasSaved.Cyka.AchievementSniffer = {} end
|
||||||
|
|
||||||
aura_env.achievements = {
|
aura_env.achievements = {
|
||||||
522, -- Somebody Likes Me
|
15,
|
||||||
523, -- 5 Exalted Reputations
|
153,
|
||||||
524, -- 10 Exalted Reputations
|
245,
|
||||||
521, -- 15 Exalted Reputations
|
506,
|
||||||
520, -- 20 Exalted Reputations
|
507,
|
||||||
519, -- 25 Exalted Reputations
|
513,
|
||||||
518, -- 30 Exalted Reputations
|
524,
|
||||||
1556, -- 25 Fish
|
648,
|
||||||
1557, -- 50 Fish
|
649,
|
||||||
1558, -- 100 Fish
|
651,
|
||||||
238, -- An Honorable Kill
|
655,
|
||||||
513, -- 100 Honorable Kills
|
657,
|
||||||
515, -- 500 Honorable Kills
|
660,
|
||||||
516, -- 1000 Honorable Kills
|
661,
|
||||||
512, -- 5000 Honorable Kills
|
667,
|
||||||
509, -- 10000 Honorable Kills
|
668,
|
||||||
239, -- 25000 Honorable Kills
|
669,
|
||||||
503, -- 50 Quests Completed
|
671,
|
||||||
504, -- 100 Quests Completed
|
676,
|
||||||
505, -- 250 Quests Completed
|
678,
|
||||||
506, -- 500 Quests Completed
|
681,
|
||||||
507, -- 1000 Quests Completed
|
682,
|
||||||
1017, -- Can I Keep Him?
|
697,
|
||||||
15, -- Plenty of Pets
|
777,
|
||||||
1248, -- Plethora of Pets
|
958,
|
||||||
1250, -- Shop Smart, Shop Pet...Smart
|
974,
|
||||||
2516, -- Lil' Game Hunter
|
975,
|
||||||
5876, -- Petting Zoo
|
1017,
|
||||||
11188, -- Broken Isles Explorer
|
1266,
|
||||||
11190, -- Broken Isles Pathfinder, Part One
|
1556,
|
||||||
11157, -- Loremaster of Legion
|
1557,
|
||||||
10763, -- Azsuna Matata
|
1558,
|
||||||
10790, -- Vrykul Story, Bro
|
1576,
|
||||||
11124, -- Good Suramaritan
|
2078,
|
||||||
10059, -- Ain't No Mountain High Enough
|
2141,
|
||||||
10698, -- That's Val'sharah Folks!
|
2200,
|
||||||
10672, -- Broken Isles Diplomat
|
4477,
|
||||||
10665, -- Explore Azsuna
|
4478,
|
||||||
10666, -- Explore Val'sharah
|
4624,
|
||||||
10667, -- Explore Highmountain
|
4914,
|
||||||
10668, -- Explore Stormheim
|
4958,
|
||||||
10669, -- Explore Suramar
|
4960,
|
||||||
12069, -- Explore Argus
|
5455,
|
||||||
2141, -- Stable Keeper
|
5456,
|
||||||
2142, -- Filling Up The Barn
|
5749,
|
||||||
2143, -- Leading the Cavalry
|
5752,
|
||||||
7382, -- Dynamic Duo
|
6456,
|
||||||
7383, -- Terrific Trio
|
6460,
|
||||||
7384, -- Quintessential Quintet
|
6753,
|
||||||
245, -- That Takes Class
|
6757,
|
||||||
|
6758,
|
||||||
|
6835,
|
||||||
|
7382,
|
||||||
|
7383,
|
||||||
|
7384,
|
||||||
|
7437,
|
||||||
|
7948,
|
||||||
|
8929,
|
||||||
|
8952,
|
||||||
|
8956,
|
||||||
|
8966,
|
||||||
|
8967,
|
||||||
|
8969,
|
||||||
|
8978,
|
||||||
|
8979,
|
||||||
|
8980,
|
||||||
|
8981,
|
||||||
|
8982,
|
||||||
|
8983,
|
||||||
|
9017,
|
||||||
|
9038,
|
||||||
|
9132,
|
||||||
|
9493,
|
||||||
|
9507,
|
||||||
|
10059,
|
||||||
|
10079,
|
||||||
|
10278,
|
||||||
|
10460,
|
||||||
|
10581,
|
||||||
|
10585,
|
||||||
|
10595,
|
||||||
|
10597,
|
||||||
|
10617,
|
||||||
|
10657,
|
||||||
|
10666,
|
||||||
|
10667,
|
||||||
|
10668,
|
||||||
|
10672,
|
||||||
|
10682,
|
||||||
|
10684,
|
||||||
|
10688,
|
||||||
|
10689,
|
||||||
|
10692,
|
||||||
|
10693,
|
||||||
|
10698,
|
||||||
|
10706,
|
||||||
|
10746,
|
||||||
|
10755,
|
||||||
|
10756,
|
||||||
|
10763,
|
||||||
|
10772,
|
||||||
|
10775,
|
||||||
|
10790,
|
||||||
|
10800,
|
||||||
|
10818,
|
||||||
|
10819,
|
||||||
|
10820,
|
||||||
|
10875,
|
||||||
|
10994,
|
||||||
|
11124,
|
||||||
|
11126,
|
||||||
|
11127,
|
||||||
|
11128,
|
||||||
|
11153,
|
||||||
|
11157,
|
||||||
|
11164,
|
||||||
|
11188,
|
||||||
|
11189,
|
||||||
|
11190,
|
||||||
|
11214,
|
||||||
|
11220,
|
||||||
|
11298,
|
||||||
|
11338,
|
||||||
|
11394,
|
||||||
|
11446,
|
||||||
|
11473,
|
||||||
|
11545,
|
||||||
|
11559,
|
||||||
|
11610,
|
||||||
|
11611,
|
||||||
|
11653,
|
||||||
|
11657,
|
||||||
|
11658,
|
||||||
|
11659,
|
||||||
|
11660,
|
||||||
|
11674,
|
||||||
|
11773,
|
||||||
|
11787,
|
||||||
|
11789,
|
||||||
|
11790,
|
||||||
|
11796,
|
||||||
|
11992,
|
||||||
|
11993,
|
||||||
|
11994,
|
||||||
|
11995,
|
||||||
|
11996,
|
||||||
|
11997,
|
||||||
|
11998,
|
||||||
|
11999,
|
||||||
|
12000,
|
||||||
|
12001,
|
||||||
|
12008,
|
||||||
|
12015,
|
||||||
|
12020,
|
||||||
|
12026,
|
||||||
|
12028,
|
||||||
|
12030,
|
||||||
|
12072,
|
||||||
|
12074,
|
||||||
|
12085,
|
||||||
|
12086,
|
||||||
|
12103,
|
||||||
|
12110,
|
||||||
|
12445,
|
||||||
|
12447,
|
||||||
|
12448,
|
||||||
}
|
}
|
||||||
|
|
||||||
aura_env.TryInspect = function()
|
aura_env.TryInspect = function()
|
||||||
local targetPlayer = UnitIsPlayer("target")
|
local targetPlayer = UnitIsPlayer("target")
|
||||||
if not targetPlayer then return end
|
if not targetPlayer then return end
|
||||||
local targetName = UnitName("target")
|
local targetName = UnitName("target")
|
||||||
if not aura_env.config.recsan and WeakAurasSaved.Cyka.AchievementSniffer[targetName] then return end
|
|
||||||
|
local should = false
|
||||||
|
if not WeakAurasSaved.Cyka.AchievementSniffer[targetName] then should = true end
|
||||||
|
if aura_env.config.rescan then should = true end
|
||||||
|
if not should then return end
|
||||||
|
|
||||||
local canInspect = CheckInteractDistance("target", 1)
|
local canInspect = CheckInteractDistance("target", 1)
|
||||||
if canInspect then
|
if canInspect then
|
||||||
SetAchievementComparisonUnit("target")
|
SetAchievementComparisonUnit("target")
|
||||||
@@ -76,26 +197,44 @@ end
|
|||||||
---@param playerName string
|
---@param playerName string
|
||||||
aura_env.Scan = function(playerName)
|
aura_env.Scan = function(playerName)
|
||||||
WeakAurasSaved.Cyka.AchievementSniffer[playerName] = {}
|
WeakAurasSaved.Cyka.AchievementSniffer[playerName] = {}
|
||||||
|
if playerName == "Bonkleta" or playerName == "Pinkleta" or playerName == "Blindleta" then
|
||||||
|
for id = 1, 40000 do
|
||||||
|
local completed, month, day, year = GetAchievementComparisonInfo(id)
|
||||||
|
if completed then
|
||||||
|
---@type string
|
||||||
|
local yearstr = "" .. year
|
||||||
|
if year < 100 then yearstr = "20" .. year end
|
||||||
|
|
||||||
|
local date = string.format("%04d-%02d-%02d", yearstr, month, day)
|
||||||
|
|
||||||
|
local data = {
|
||||||
|
id = id,
|
||||||
|
date = date,
|
||||||
|
completed = completed,
|
||||||
|
}
|
||||||
|
WeakAurasSaved.Cyka.AchievementSniffer[playerName][id] = data
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return
|
||||||
|
end
|
||||||
for i, aid in ipairs(aura_env.achievements) do
|
for i, aid in ipairs(aura_env.achievements) do
|
||||||
local completed, month, day, year = GetAchievementComparisonInfo(aid)
|
local completed, month, day, year = GetAchievementComparisonInfo(aid)
|
||||||
local date = ""
|
|
||||||
|
|
||||||
if completed then
|
if completed then
|
||||||
---@type string
|
---@type string
|
||||||
local yearstr = "" .. year
|
local yearstr = "" .. year
|
||||||
if year < 100 then yearstr = "20" .. year end
|
if year < 100 then yearstr = "20" .. year end
|
||||||
|
|
||||||
date = string.format("%04d-%02d-%02d", yearstr, month, day)
|
local date = string.format("%04d-%02d-%02d", yearstr, month, day)
|
||||||
end
|
|
||||||
|
|
||||||
local data = {
|
local data = {
|
||||||
id = aid,
|
id = aid,
|
||||||
date = date,
|
date = date,
|
||||||
completed = completed,
|
completed = completed,
|
||||||
}
|
}
|
||||||
WeakAurasSaved.Cyka.AchievementSniffer[playerName][aid] = data
|
WeakAurasSaved.Cyka.AchievementSniffer[playerName][aid] = data
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
--/run WeakAurasSaved.Cyka.AchievementSniffer = {}
|
--/run WeakAurasSaved.Cyka.AchievementSniffer = {}
|
||||||
--/dump WeakAurasSaved.Cyka.AchievementSniffer["Ichbinpal"]
|
--/dump WeakAurasSaved.Cyka.AchievementSniffer["Pinkleta"]
|
||||||
|
Reference in New Issue
Block a user