aux support

now tooltips show source inside aux addon
also fixed bug that prevented some enchanting items to show source
fixed bug with empty () drop chance showing
This commit is contained in:
Spit
2025-01-23 14:22:15 +03:00
parent 2c4f7d8580
commit b9dac1f7e7
3 changed files with 38 additions and 9 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
## Notes: Shows possible loot from dungeon bosses and other sources. ## Notes: Shows possible loot from dungeon bosses and other sources.
## Author: Shagu (pfUI update code), Lexie (Turtle WoW fixes/updates), Otari (overhaul/revamp, menu changes, bugfixes/updates) ## Author: Shagu (pfUI update code), Lexie (Turtle WoW fixes/updates), Otari (overhaul/revamp, menu changes, bugfixes/updates)
## LegacyAuthor: Daviesh, Pompa (Turtle WoW World Bosses), Xerron (Turtle WoW World Bosses), Gurky (Turtle WoW 1.16/1.16.1 Dungeons) ## LegacyAuthor: Daviesh, Pompa (Turtle WoW World Bosses), Xerron (Turtle WoW World Bosses), Gurky (Turtle WoW 1.16/1.16.1 Dungeons)
## Version: 3.0.6 ## Version: 3.0.7
## SavedVariables: AtlasLoot_updateavailable ## SavedVariables: AtlasLoot_updateavailable
## SavedVariablesPerCharacter: AtlasLootCharDB ## SavedVariablesPerCharacter: AtlasLootCharDB
## OptionalDeps: Alphamap, AtlasLoader, LootLink, ItemSync, HewdropLib, Ace2, EquipCompare, EQCompare ## OptionalDeps: Alphamap, AtlasLoader, LootLink, ItemSync, HewdropLib, Ace2, EquipCompare, EQCompare
+35 -6
View File
@@ -185,6 +185,13 @@ function AtlasLootTip.extendTooltip(tooltip)
for k,v in pairs(GetSpellInfoAtlasLootDB["craftspells"]) do for k,v in pairs(GetSpellInfoAtlasLootDB["craftspells"]) do
if v["craftItem"] == itemID then if v["craftItem"] == itemID then
craftSpell = "s"..tostring(k) craftSpell = "s"..tostring(k)
break
end
end
for k, v in pairs(GetSpellInfoAtlasLootDB["enchants"]) do
if v["item"] and v["item"] == itemID then
craftSpell = "e"..tostring(k)
break
end end
end end
for k1, v1 in pairs(AtlasLoot_Data["AtlasLootCrafting"]) do for k1, v1 in pairs(AtlasLoot_Data["AtlasLootCrafting"]) do
@@ -192,7 +199,7 @@ function AtlasLootTip.extendTooltip(tooltip)
break break
end end
for k2, v2 in pairs(AtlasLoot_Data["AtlasLootCrafting"][k1]) do for k2, v2 in pairs(AtlasLoot_Data["AtlasLootCrafting"][k1]) do
if v2[1] ~= 0 and v2[1] ~= "" and string.sub(v2[1], 1, 1) ~= "e" then if v2[1] ~= 0 and v2[1] ~= "" --[[and string.sub(v2[1], 1, 1) ~= "e"]] then
if (v2[1] == craftSpell or v2[1] == itemID) and if (v2[1] == craftSpell or v2[1] == itemID) and
(strfind(k1, "Apprentice", 1, true) or (strfind(k1, "Apprentice", 1, true) or
strfind(k1, "Journeyman", 1, true) or strfind(k1, "Journeyman", 1, true) or
@@ -220,6 +227,19 @@ function AtlasLootTip.extendTooltip(tooltip)
source = k1 source = k1
isCraft = true isCraft = true
lastDropRate = nil lastDropRate = nil
-- if strfind(k1, "Apprentice", 1, true) then
-- dropRate = "1-75"
-- lastDropRate = dropRate
-- elseif strfind(k1, "Journeyman", 1, true) then
-- dropRate = "75-150"
-- lastDropRate = dropRate
-- elseif strfind(k1, "Expert", 1, true) then
-- dropRate = "150-225"
-- lastDropRate = dropRate
-- elseif strfind(k1, "Artisan", 1, true) then
-- dropRate = "225-300"
-- lastDropRate = dropRate
-- end
break break
end end
end end
@@ -235,7 +255,7 @@ function AtlasLootTip.extendTooltip(tooltip)
if v2[1] == itemID then if v2[1] == itemID then
source = k1 source = k1
isWBLoot = true isWBLoot = true
if v2[5] then if v2[5] and v2[5] ~= "" then
dropRate = v2[5] dropRate = v2[5]
lastDropRate = dropRate lastDropRate = dropRate
else else
@@ -273,7 +293,7 @@ function AtlasLootTip.extendTooltip(tooltip)
if v2[1] == itemID then if v2[1] == itemID then
source = k1 source = k1
isRepReward = true isRepReward = true
if v2[5] then if v2[5] and v2[5] ~= "" then
dropRate = v2[5] dropRate = v2[5]
lastDropRate = dropRate lastDropRate = dropRate
else else
@@ -292,7 +312,7 @@ function AtlasLootTip.extendTooltip(tooltip)
if v2[1] == itemID then if v2[1] == itemID then
source = k1 source = k1
isRepReward = true isRepReward = true
if v2[5] and source ~= "Darkmoon" and not strfind(source, "Cenarion",1,true) then if v2[5] and v2[5] ~= "" --[[and source ~= "Darkmoon" and not strfind(source, "Cenarion",1,true)]] then
dropRate = v2[5] dropRate = v2[5]
lastDropRate = dropRate lastDropRate = dropRate
else else
@@ -333,7 +353,7 @@ function AtlasLootTip.extendTooltip(tooltip)
if v2[1] == itemID then if v2[1] == itemID then
source = k1 source = k1
isWorldEvent = true isWorldEvent = true
if v2[5] then if v2[5] and v2[5] ~= "" then
dropRate = v2[5] dropRate = v2[5]
lastDropRate = dropRate lastDropRate = dropRate
else else
@@ -355,7 +375,7 @@ function AtlasLootTip.extendTooltip(tooltip)
if k1 ~= "VanillaKeys" then if k1 ~= "VanillaKeys" then
source = k1 source = k1
end end
if v2[5] then if v2[5] and v2[5] ~= "" then
dropRate = v2[5] dropRate = v2[5]
lastDropRate = dropRate lastDropRate = dropRate
else else
@@ -447,6 +467,15 @@ AtlasLootTip:SetScript("OnHide", function()
end) end)
AtlasLootTip:SetScript("OnShow", function() AtlasLootTip:SetScript("OnShow", function()
if aux_frame and aux_frame:IsVisible() then
if GetMouseFocus():GetParent() then
if GetMouseFocus():GetParent().row then
if GetMouseFocus():GetParent().row.record.item_id then
GameTooltip.itemID = GetMouseFocus():GetParent().row.record.item_id
end
end
end
end
AtlasLootTip.extendTooltip(GameTooltip) AtlasLootTip.extendTooltip(GameTooltip)
end) end)
+2 -2
View File
@@ -2626,8 +2626,8 @@ AtlasLoot_Data["AtlasLootSetItems"] = {
{ 18563, "Spell_Ice_Lament", "=q5=Bindings of the Windseeker", "=ds=#m10# =q1=#m3#", " 3.78%" }, { 18563, "Spell_Ice_Lament", "=q5=Bindings of the Windseeker", "=ds=#m10# =q1=#m3#", " 3.78%" },
{ 17782, "INV_Jewelry_Amulet_04", "=q5=Talisman of Binding Shard", "=ds=#s2#" }, { 17782, "INV_Jewelry_Amulet_04", "=q5=Talisman of Binding Shard", "=ds=#s2#" },
{ 0, "", "", "" }, { 0, "", "", "" },
{ 0, "", "", "" },
{ 61184, "Inv_weapon_shortblade_23", "=q5=The Scythe of Elune", "=ds=#m2#", "0.85%" }, { 61184, "Inv_weapon_shortblade_23", "=q5=The Scythe of Elune", "=ds=#m2#", "0.85%" },
{ 55505, "Inv_weapon_shortblade_23", "=q5=The Scythe of Elune", "=ds=#s14#" },
{ 0, "", "", "" }, { 0, "", "", "" },
{ "e57518", "inv_misc_gem_pearl_04", "=q5=Eternal Dreamstone Shard", "=q1=Enchanting"}, { "e57518", "inv_misc_gem_pearl_04", "=q5=Eternal Dreamstone Shard", "=q1=Enchanting"},
{ 0, "", "", "" }, { 0, "", "", "" },
@@ -2654,7 +2654,7 @@ AtlasLoot_Data["AtlasLootSetItems"] = {
{ 19872, "Ability_Mount_Raptor", "=q4=Armored Razzashi Raptor", "=ds=#e7#" }, { 19872, "Ability_Mount_Raptor", "=q4=Armored Razzashi Raptor", "=ds=#e7#" },
{ 19902, "Ability_Mount_JungleTiger", "=q4=Swift Zulian Tiger", "=ds=#e7#" }, { 19902, "Ability_Mount_JungleTiger", "=q4=Swift Zulian Tiger", "=ds=#e7#" },
{ 13086, "Ability_Mount_PinkTiger", "=q4=Reins of the Winterspring Frostsaber", "=ds=#e7#" }, { 13086, "Ability_Mount_PinkTiger", "=q4=Reins of the Winterspring Frostsaber", "=ds=#e7#" },
{ 23720, "Ability_Hunter_Pet_Turtle", "=q4=Riding Turtle", "=ds=#e7#" }, { 23720, "Ability_Hunter_Pet_Turtle", "=q1=Swift Riding Turtle", "=ds=#e7#" },
{ 0, "", "", "" }, { 0, "", "", "" },
{ 21218, "INV_Misc_QirajiCrystal_04", "=q3=Blue Qiraji Resonating Crystal", "=ds=#e7#" }, { 21218, "INV_Misc_QirajiCrystal_04", "=q3=Blue Qiraji Resonating Crystal", "=ds=#e7#" },
{ 21323, "INV_Misc_QirajiCrystal_03", "=q3=Green Qiraji Resonating Crystal", "=ds=#e7#" }, { 21323, "INV_Misc_QirajiCrystal_03", "=q3=Green Qiraji Resonating Crystal", "=ds=#e7#" },