Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
1b46707
rework buffs scanning
Alessandro-Barbieri Feb 16, 2025
9903670
wrong function name
Alessandro-Barbieri Apr 13, 2025
947fede
[feature] Add setting to change item quality colors' intensity (Thank…
BrenoLudgero Feb 27, 2025
5ce4049
[fix] Fix avoidance calculation (Thanks @Alessandro-Barbieri)
Alessandro-Barbieri Feb 28, 2025
10fb956
Bump version to v4.1.0
BreakBB Feb 28, 2025
ee8fdf8
[fix] Fix parry for Shamans (Thanks @Alessandro-Barbieri)
Alessandro-Barbieri Mar 7, 2025
65edd4f
Bump version to v4.1.1
BreakBB Mar 7, 2025
94b3ecc
Create dependabot.yml
BreakBB Mar 7, 2025
981cfa7
Fix dependabot.yml
BreakBB Mar 7, 2025
545faae
Bump actions/checkout from 3 to 4 (#351)
dependabot[bot] Mar 7, 2025
e8c64bb
Bump leafo/gh-actions-lua from 10 to 11 (#352)
dependabot[bot] Mar 7, 2025
eb4ad76
Bump leafo/gh-actions-luarocks from 4 to 5 (#353)
dependabot[bot] Mar 7, 2025
ee2506f
fix typo (#355)
Alessandro-Barbieri Mar 11, 2025
2532570
[fix] Handle more MP5 bonuses from gear sets
Alessandro-Barbieri Apr 8, 2025
a7c5b4f
rework rune detection (#364)
Alessandro-Barbieri Apr 8, 2025
85d4af9
improve SoD detection (#361)
Alessandro-Barbieri Apr 8, 2025
496f637
[fix] Bump interface version for patch 1.15.7
BreakBB Apr 8, 2025
29a36c7
[fix] Bump interface version for patch 3.4.4
BreakBB Apr 8, 2025
9598ded
Bump version to v4.1.2
BreakBB Apr 8, 2025
0616603
use tables to reduce the numbers of "if" needed
Alessandro-Barbieri Nov 24, 2025
f1d8b98
use C_UnitAuras.GetAuraDataByIndex
Alessandro-Barbieri Nov 24, 2025
a10fca7
Merge branch 'master' into buffs_scanning
Alessandro-Barbieri Nov 24, 2025
8339cc6
fixes
Alessandro-Barbieri Nov 24, 2025
4f820b5
Merge branch 'master' into buffs_scanning
Alessandro-Barbieri Dec 3, 2025
6e67593
use the right function
Alessandro-Barbieri Dec 3, 2025
e421503
simplify MP5 enchants and gems scanning
Alessandro-Barbieri Dec 3, 2025
c193201
rework BoW/mana spring totem buff scanning
Alessandro-Barbieri Dec 4, 2025
f7b261a
fixes
Alessandro-Barbieri Dec 4, 2025
a61a405
remove unneeded stuff
Alessandro-Barbieri Dec 4, 2025
9ecce85
add fallback mechanism
Alessandro-Barbieri Dec 4, 2025
6d14300
fix luacheck errors
Alessandro-Barbieri Dec 5, 2025
be17dcd
move almost all buffs Id to the constant table
Alessandro-Barbieri Dec 5, 2025
533140f
fix luacheck errors
Alessandro-Barbieri Dec 5, 2025
5405a37
more fixes
Alessandro-Barbieri Dec 5, 2025
8e7feb5
more stuff
Alessandro-Barbieri Dec 5, 2025
c199c4b
fix
Alessandro-Barbieri Dec 6, 2025
70343a4
add combat mana regenerations buffs
Alessandro-Barbieri Dec 9, 2025
847a01d
fix
Alessandro-Barbieri Dec 9, 2025
1c7a103
Merge branch 'BreakBB:master' into buffs_scanning
Alessandro-Barbieri Dec 9, 2025
335e2d5
add % mana regen
Alessandro-Barbieri Dec 9, 2025
0f56741
add talent and sets modifiers
Alessandro-Barbieri Dec 10, 2025
0e6e0ba
fixes
Alessandro-Barbieri Dec 10, 2025
5c5d7f2
fix
Alessandro-Barbieri Dec 10, 2025
4dec2fa
fix
Alessandro-Barbieri Dec 10, 2025
c366b39
add Blackfathom Mana Oil
Alessandro-Barbieri Dec 10, 2025
47c85f4
WIP
Alessandro-Barbieri Dec 14, 2025
e145f56
use non deprecated function
Alessandro-Barbieri Dec 14, 2025
cc84a14
Update .luacheckrc
Alessandro-Barbieri Dec 14, 2025
fd80194
Update .luacheckrc
Alessandro-Barbieri Dec 14, 2025
7f3ebb1
refactor Data
Alessandro-Barbieri Dec 18, 2025
7e7fe1e
switch to numeric keys
Alessandro-Barbieri Dec 19, 2025
b1a24e7
add conversion between tooltip value and MP5
Alessandro-Barbieri Dec 19, 2025
85d28e6
fix
Alessandro-Barbieri Dec 19, 2025
6191c6f
more details
Alessandro-Barbieri Dec 20, 2025
d000d6c
fix errors in constants
Alessandro-Barbieri Dec 22, 2025
84e366e
missing comma
Alessandro-Barbieri Dec 22, 2025
2ee5395
Convert enchant to number before returning
Alessandro-Barbieri Dec 23, 2025
2192ef3
Fix ranged enchant comparison to use correct type
Alessandro-Barbieri Dec 23, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .luacheckrc
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,8 @@ stds.ecs = {
"C_Spell.DoesSpellExist",
"C_Spell.IsSpellDataCached",
"C_Spell.RequestLoadSpellData",
"C_SpellBook",
"C_SpellBook.IsSpellKnown",
"C_StorePublic.DoesGroupHavePurchaseableProducts",
"C_StorePublic.IsDisabledByParentalControls",
"C_StorePublic.IsEnabled",
Expand All @@ -559,7 +561,8 @@ stds.ecs = {
"C_UIWidgetManager.GetTextureWithStateVisualizationInfo",
"C_UIWidgetManager.GetTopCenterWidgetSetID",
"C_UnitAuras",
"C_UnitAuras.GetPlayerAuraBySpellID",
"C_UnitAuras.GetAuraDataByIndex",
"C_UnitAuras.GetBuffDataByIndex",
"C_VideoOptions.GetGxAdapterInfo",
"C_VoiceChat.ActivateChannel",
"C_VoiceChat.BeginLocalCapture",
Expand Down
404 changes: 378 additions & 26 deletions Modules/Data/Constants.lua

Large diffs are not rendered by default.

23 changes: 13 additions & 10 deletions Modules/Data/DataUtils.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---@class DataUtils
local DataUtils = ECSLoader:CreateModule("DataUtils")
---@type Data
local Data = ECSLoader:ImportModule("Data")

--- Rounds every number down to the given decimal places
---@param num number
Expand All @@ -15,15 +17,16 @@ end

---@return boolean
function DataUtils:IsShapeshifted()
for i = 1, 40 do
local _, _, _, _, _, _, _, _, _, spellId, _ = UnitAura("player", i, "HELPFUL", "PLAYER")
if spellId == nil then
break
local i = 1
repeat
local aura = C_UnitAuras.GetBuffDataByIndex("player", i)
i = i + 1
if aura and aura.spellId then
if Data.Aura.IsFeralForm[aura.spellId] then
return true
end
end
if spellId == 5487 or spellId == 9634 or spellId == 768 then
return true
end
end
until (not aura)
return false
end

Expand Down Expand Up @@ -105,7 +108,7 @@ function DataUtils:GetEnchantFromItemLink(itemLink)
local _, itemStringLink = GetItemInfo(itemLink)
if itemStringLink then
local _, _, enchant = string.find(itemStringLink, "item:%d+:(%d*)")
return enchant
return tonumber(enchant)
end
end

Expand Down Expand Up @@ -139,4 +142,4 @@ function DataUtils:GetSocketedGemsFromItemLink(itemLink)
return nil
end

return DataUtils
return DataUtils
32 changes: 7 additions & 25 deletions Modules/Data/Defense.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,38 +33,20 @@ function _Defense:GetCritReduction()
local aura = C_UnitAuras.GetAuraDataByIndex("player", i, "HELPFUL")
i = i + 1
if aura and aura.spellId then
buffBonus = buffBonus + (Data.BuffCritReductionAll[aura.spellId] or 0)
if ECS.IsSoD and aura.spellId == 408680 then
meleeCritReduction = meleeCritReduction + 6 -- way of earth
end
buffBonus = buffBonus + (Data.Aura.CritReductionAll[aura.spellId] or 0)
meleeCritReduction = meleeCritReduction + (Data.Aura.CritReductionMelee[aura.spellId] or 0)
end
until (not aura)
i = 1
repeat
local aura = C_UnitAuras.GetAuraDataByIndex("player", i, "HARMFUL")
i = i + 1
if aura and aura.spellId then
buffBonus = buffBonus + (Data.BuffCritReductionAll[aura.spellId] or 0)
if ECS.IsWotlk then
if aura.spellId == 30708 then
buffBonus = buffBonus - 3 -- totem of wrath
elseif aura.spellId == 12579 then
spellCritReduction = spellCritReduction - 1 * aura.applications -- Winter's Chill
elseif aura.spellId == 22959 then
spellCritReduction = spellCritReduction - 5 -- Improved Scorch
elseif aura.spellId == 17800 then
spellCritReduction = spellCritReduction - 5 -- Shadow Mastery
elseif aura.spellId == 17799 then
spellCritReduction = spellCritReduction - 4 -- Shadow Mastery
elseif aura.spellId == 17798 then
spellCritReduction = spellCritReduction - 2 -- Shadow Mastery
elseif aura.spellId == 17797 then
spellCritReduction = spellCritReduction - 3 -- Shadow Mastery
elseif aura.spellId == 17794 then
spellCritReduction = spellCritReduction - 1 -- Shadow Mastery
elseif aura.spellId == 47241 then
meleeCritReduction = meleeCritReduction + 6 -- metamorphosis
end
buffBonus = buffBonus + (Data.Aura.CritReductionAll[aura.spellId] or 0)
meleeCritReduction = meleeCritReduction + (Data.Aura.CritReductionMelee[aura.spellId] or 0)
spellCritReduction = spellCritReduction + (Data.Aura.CritReductionSpell[aura.spellId] or 0)
if ECS.IsWotlk and aura.spellId == 12579 then
spellCritReduction = spellCritReduction - 1 * aura.applications -- Winter's Chill
end
end
until (not aura)
Expand Down
104 changes: 57 additions & 47 deletions Modules/Data/ItemSets.lua
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,16 @@ local itemSets = {
[19691] = true,
[19692] = true,
},
[setNames.DAWN_OF_TRANSCENDENCE] = {
[231155] = true,
[231156] = true,
[231157] = true,
[231158] = true,
[231159] = true,
[231160] = true,
[231161] = true,
[231162] = true,
},
[setNames.FEL_IRON_CHAIN] = {
[23490] = true,
[23491] = true,
Expand All @@ -50,22 +60,27 @@ local itemSets = {
[19838] = true,
[19839] = true,
[19840] = true,
[19955] = true
[19955] = true,
},
[setNames.LIVING_GREEN_DRAGON_MAIL] = {
[227879] = true,
[227878] = true,
[227877] = true,
[227878] = true,
[227879] = true,
},
[setNames.PRIMAL_MOONCLOTH] = {
[21873] = true,
[21874] = true,
[21875] = true,
},
[setNames.STORMRAGE_RAIMENT] = {
[16897] = true,
[16898] = true,
[16899] = true,
[16900] = true,
[16901] = true,
[16902] = true,
[16903] = true,
[16904] = true,
[16897] = true,
[16898] = true
},
[setNames.TEN_STORMS] = {
[16943] = true,
Expand Down Expand Up @@ -109,74 +124,69 @@ local itemSets = {
[20296] = true,
},
[setNames.LIVING_GREEN_DRAGON_MAIL] = {
[227879] = true,
[227878] = true,
[227877] = true,
[227878] = true,
[227879] = true,
},
}

function Data:HasSetBonusModifierMP5()
return (ECS.IsClassic and (
Data:IsSetBonusActive(setNames.GREEN_DRAGON_MAIL, 3) or
---@return number
function Data:GetSetBonusModifierMP5()
local mod = 0
if (ECS.IsClassic and Data:IsSetBonusActive(setNames.GREEN_DRAGON_MAIL, 3)) then
mod = mod + 0.15
end
if (ECS.IsClassic and (
(classId == Data.DRUID and Data:IsSetBonusActive(setNames.STORMRAGE_RAIMENT, 3)) or
(classId == Data.PRIEST and Data:IsSetBonusActive(setNames.VESTMENTS_OF_TRANSCENDENCE, 3)) or
(ECS.IsSod and Data:IsSetBonusActive(setNames.LIVING_GREEN_DRAGON_MAIL, 3))
))
(classId == Data.PRIEST and Data:IsSetBonusActive(setNames.VESTMENTS_OF_TRANSCENDENCE, 3))
)) then
mod = mod + 0.15
end
if (ECS.IsSod and Data:IsSetBonusActive(setNames.LIVING_GREEN_DRAGON_MAIL, 3)) then
mod = mod + 0.15
end
if (ECS.IsSod and Data:IsSetBonusActive(setNames.DAWN_OF_TRANSCENDENCE, 2)) then
mod = mod + 0.15
end
if Data:IsSetBonusActive(setNames.PRIMAL_MOONCLOTH, 3) then
mod = mod + 0.05
end
return mod
end

---@return number
function Data:GetSetBonusValueMP5()
local bonus = 0
if (classId == Data.DRUID and Data:IsSetBonusActive(setNames.HARUSPEXS_GARB, 2)) or
(classId == Data.SHAMAN and Data:IsSetBonusActive(setNames.AUGURS_REGALIA, 2)) or
(classId == Data.PALADIN and Data:IsSetBonusActive(setNames.FREETHINKERS_ARMOR, 2)
) then
if ECS.IsWotlk then
bonus = bonus + 5
else
bonus = bonus + 4
end
bonus = bonus + (ECS.IsWotlk and 5 or 4)
end
if ((ECS.IsSod and Data:IsSetBonusActive(setNames.LIVING_GREEN_DRAGON_MAIL, 2)) or
Data:IsSetBonusActive(setNames.GREEN_DRAGON_MAIL, 2)
) then
if ECS.IsWotlk then
bonus = bonus + 4
else
bonus = bonus + 3
end
if (ECS.IsSod and Data:IsSetBonusActive(setNames.LIVING_GREEN_DRAGON_MAIL, 2)) then
bonus = bonus + 3
end
if Data:IsSetBonusActive(setNames.GREEN_DRAGON_MAIL, 2) then
bonus = bonus + (ECS.IsWotlk and 4 or 3)
end
if (not ECS.IsClassic and Data:IsSetBonusActive(setNames.GREEN_DRAGON_MAIL, 3)) then
bonus = bonus + (ECS.IsWotlk and 25 or 20)
end
if (not ECS.IsClassic and (
Data:IsSetBonusActive(setNames.GREEN_DRAGON_MAIL, 3) or
(classId == Data.DRUID and Data:IsSetBonusActive(setNames.STORMRAGE_RAIMENT, 3)) or
(classId == Data.PRIEST and Data:IsSetBonusActive(setNames.VESTMENTS_OF_TRANSCENDENCE, 3))
)
) then
if ECS.IsWotlk then
bonus = bonus + 25
elseif ECS.IsTbc then
bonus = bonus + 20
end
bonus = bonus + (ECS.IsWotlk and 25 or 20)
end
if Data:IsSetBonusActive(setNames.BLOODSOUL_EMBRACE, 3) then
if ECS.IsWotlk then
bonus = bonus + 15
else
bonus = bonus + 12
end
bonus = bonus + (ECS.IsWotlk and 15 or 12)
end
if Data:IsSetBonusActive(setNames.FEL_IRON_CHAIN, 4) then
if ECS.IsWotlk then
bonus = bonus + 10
else
bonus = bonus + 8
end
bonus = bonus + (ECS.IsWotlk and 10 or 8)
end
if Data:IsSetBonusActive(setNames.WINDHAWK_ARMOR, 3) then
if ECS.IsWotlk then
bonus = bonus + 10
else
bonus = bonus + 8
end
bonus = bonus + (ECS.IsWotlk and 10 or 8)
end
return bonus
end
Expand Down
Loading
Loading