Skip to content

Commit

Permalink
Add SoD Tier 2 set bonuses
Browse files Browse the repository at this point in the history
  • Loading branch information
raethkcj committed Sep 8, 2024
1 parent dfb4695 commit 8a39fb7
Show file tree
Hide file tree
Showing 3 changed files with 92 additions and 18 deletions.
61 changes: 48 additions & 13 deletions RatingBuster.lua
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,14 @@ local options = {
args = {},
hidden = true,
},
spell_dmg = {
type = 'group',
name = L[StatLogic.Stats.SpellDamage],
desc = L["Changes the display of %s"]:format(L[StatLogic.Stats.SpellDamage]),
order = 10,
args = {},
hidden = true,
},
mastery = {
type = 'group',
name = L[StatLogic.Stats.MasteryRating],
Expand Down Expand Up @@ -2359,8 +2367,10 @@ do
local effect = value * statModContext("ADD_BLOCK_VALUE_MOD_STR")
infoTable[StatLogic.Stats.BlockValue] = infoTable[StatLogic.Stats.BlockValue] + effect
end
local spellDamage = value * statModContext("ADD_SPELL_DMG_MOD_STR")
self:ProcessStat(StatLogic.Stats.SpellDamage, spellDamage, infoTable, link, color, statModContext)
if db.profile.showSpellDmgFromStr then
local effect = value * statModContext("MOD_SPELL_DMG") * statModContext("ADD_SPELL_DMG_MOD_STR")
local effect = spellDamage * statModContext("MOD_SPELL_DMG")
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + effect
end
if db.profile.showHealingFromStr then
Expand Down Expand Up @@ -2430,12 +2440,15 @@ do
local effect = health * statModContext("MOD_HEALTH")
infoTable[StatLogic.Stats.Health] = infoTable[StatLogic.Stats.Health] + effect
end

local spellDamage = value * statModContext("ADD_SPELL_DMG_MOD_STA")
+ statModContext("ADD_SPELL_DMG_MOD_PET_STA") * statModContext("MOD_PET_STA") * statModContext("ADD_PET_STA_MOD_STA")
self:ProcessStat(StatLogic.Stats.SpellDamage, spellDamage, infoTable, link, color, statModContext)
if db.profile.showSpellDmgFromSta then
local effect = value * statModContext("MOD_SPELL_DMG") * (statModContext("ADD_SPELL_DMG_MOD_STA")
+ statModContext("ADD_SPELL_DMG_MOD_PET_STA") * statModContext("MOD_PET_STA") * statModContext("ADD_PET_STA_MOD_STA"))
local effect = spellDamage * statModContext("MOD_SPELL_DMG")
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + effect
end
-- "ADD_AP_MOD_STA" -- Hunter: Hunter vs. Wild

if db.profile.showAPFromSta then
local effect = value * statModContext("ADD_AP_MOD_STA") * statModContext("MOD_AP")
infoTable[StatLogic.Stats.AttackPower] = infoTable[StatLogic.Stats.AttackPower] + effect
Expand All @@ -2454,14 +2467,18 @@ do
if db.profile.showSpellCritFromInt then
infoTable[StatLogic.Stats.SpellCrit] = infoTable[StatLogic.Stats.SpellCrit] + spellCrit
end

local spellDamage = value * (
statModContext("ADD_SPELL_DMG_MOD_INT")
+ statModContext("ADD_SPELL_DMG_MOD_PET_INT") * statModContext("MOD_PET_INT") * statModContext("ADD_PET_INT_MOD_INT")
+ statModContext("ADD_SPELL_DMG_MOD_MANA") * statModContext("MOD_MANA") * statModContext("ADD_MANA_MOD_INT")
)
self:ProcessStat(StatLogic.Stats.SpellDamage, spellDamage, infoTable, link, color, statModContext)
if db.profile.showSpellDmgFromInt then
local effect = value * statModContext("MOD_SPELL_DMG") * (
statModContext("ADD_SPELL_DMG_MOD_INT")
+ statModContext("ADD_SPELL_DMG_MOD_PET_INT") * statModContext("MOD_PET_INT") * statModContext("ADD_PET_INT_MOD_INT")
+ statModContext("ADD_SPELL_DMG_MOD_MANA") * statModContext("MOD_MANA") * statModContext("ADD_MANA_MOD_INT")
)
local effect = spellDamage * statModContext("MOD_SPELL_DMG")
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + effect
end

if db.profile.showHealingFromInt then
local effect = value * statModContext("MOD_HEALING") * (
statModContext("ADD_HEALING_MOD_INT")
Expand Down Expand Up @@ -2516,10 +2533,14 @@ do
local effect = value * statModContext("ADD_NORMAL_HEALTH_REG_MOD_SPI") * statModContext("MOD_NORMAL_HEALTH_REG")
infoTable[StatLogic.Stats.HealthRegenOutOfCombat] = infoTable[StatLogic.Stats.HealthRegenOutOfCombat] + effect
end

local spellDamage = value * statModContext("ADD_SPELL_DMG_MOD_SPI")
self:ProcessStat(StatLogic.Stats.SpellDamage, spellDamage, infoTable, link, color, statModContext)
if db.profile.showSpellDmgFromSpi then
local effect = value * statModContext("ADD_SPELL_DMG_MOD_SPI") * statModContext("MOD_SPELL_DMG")
local effect = spellDamage * statModContext("MOD_SPELL_DMG")
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + effect
end

if db.profile.showHealingFromSpi then
local effect = value * statModContext("ADD_HEALING_MOD_SPI") * statModContext("MOD_HEALING")
infoTable[StatLogic.Stats.HealingPower] = infoTable[StatLogic.Stats.HealingPower] + effect
Expand Down Expand Up @@ -2596,12 +2617,15 @@ do
local attackPower = value * statModContext("ADD_AP_MOD_DEFENSE")
self:ProcessStat(StatLogic.Stats.AttackPower, attackPower, infoTable, link, color, statModContext)
if db.profile.showAPFromDefense then
infoTable[StatLogic.Stats.AttackPower] = infoTable[StatLogic.Stats.AttackPower] + attackPower
local effect = attackPower * statModContext("MOD_AP")
infoTable[StatLogic.Stats.AttackPower] = infoTable[StatLogic.Stats.AttackPower] + effect
end

local spellDamage = value * statModContext("ADD_SPELL_DMG_MOD_DEFENSE")
self:ProcessStat(StatLogic.Stats.SpellDamage, spellDamage, infoTable, link, color, statModContext)
if db.profile.showSpellDmgFromDefense then
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + spellDamage
local effect = spellDamage * statModContext("MOD_SPELL_DMG")
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + effect
end
elseif statID == StatLogic.Stats.Armor then
local base, bonus = StatLogic:GetArmorDistribution(link, value, color)
Expand All @@ -2615,14 +2639,24 @@ do
-- Attack Power --
------------------
value = value * statModContext("MOD_AP")

local spellDamage = value * statModContext("ADD_SPELL_DMG_MOD_AP")
self:ProcessStat(StatLogic.Stats.SpellDamage, spellDamage, infoTable, link, color, statModContext)
if db.profile.showSpellDmgFromAP then
local effect = value * statModContext("ADD_SPELL_DMG_MOD_AP") * statModContext("MOD_SPELL_DMG")
local effect = spellDamage * statModContext("MOD_SPELL_DMG")
infoTable[StatLogic.Stats.SpellDamage] = infoTable[StatLogic.Stats.SpellDamage] + effect
end

if db.profile.showHealingFromAP then
local effect = value * statModContext("ADD_HEALING_MOD_AP") * statModContext("MOD_HEALING")
infoTable[StatLogic.Stats.HealingPower] = infoTable[StatLogic.Stats.HealingPower] + effect
end
elseif statID == StatLogic.Stats.SpellDamage then
value = value * statModContext("MOD_SPELL_DMG")
if db.profile.showBlockValueFromSpellDmg then
local effect = value * statModContext("ADD_BLOCK_VALUE_MOD_SPELL_DMG") * statModContext("MOD_BLOCK_VALUE")
infoTable[StatLogic.Stats.BlockValue] = infoTable[StatLogic.Stats.BlockValue] + effect
end
end
end
end
Expand Down Expand Up @@ -3468,6 +3502,7 @@ local summaryCalcData = {
statModContext("MOD_BLOCK_VALUE") * (
sum[StatLogic.Stats.BlockValue]
+ sum[StatLogic.Stats.Strength] * statModContext("ADD_BLOCK_VALUE_MOD_STR")
+ summaryFunc[StatLogic.Stats.SpellDamage](sum, statModContext) * statModContext("ADD_BLOCK_VALUE_MOD_SPELL_DMG")
)
) or 0
end,
Expand Down
4 changes: 4 additions & 0 deletions libs/StatLogic/StatLogic.lua
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,10 @@ local addedInfoMods = {
add = "AP",
mod = "STA",
},
{
add = "BLOCK_VALUE",
mod = "SPELL_DMG",
},
{
add = "BLOCK_VALUE",
mod = "STR",
Expand Down
45 changes: 40 additions & 5 deletions libs/StatLogic/Vanilla_Logic.lua
Original file line number Diff line number Diff line change
Expand Up @@ -739,6 +739,12 @@ elseif addon.class == "PRIEST" then
["pieces"] = 3,
["value"] = 0.15,
},
-- Set: Dawn of Transcendence (SoD)
{
["set"] = 1812,
["pieces"] = 2,
["value"] = 0.15,
},
},
-- Priest: Spiritual Guidance (Rank 5) - 2,14
-- Increases spell damage and healing by up to 5%/10%/15%/20%/25% of your total Spirit.
Expand Down Expand Up @@ -816,7 +822,18 @@ elseif addon.class == "ROGUE" then
{
["known"] = 400016,
["rune"] = true,
["value"] = 0.30,
["stack"] = 0.06,
["max_stacks"] = 5,
["aura"] = 400015,
},
},
["MOD_ARMOR"] = {
-- Set: Bloodfang Battlearmor (Rolling with the Punches)
{
["known"] = 400016,
["rune"] = true,
["stack"] = 0.20,
["max_stacks"] = 5,
["aura"] = 400015,
},
},
Expand All @@ -843,6 +860,15 @@ elseif addon.class == "ROGUE" then
[Enum.ItemWeaponSubclass.Unarmed] = true,
},
},
-- Set: Madcap's Outfit (SoD)
{
["set"] = 1829,
["pieces"] = 3,
["value"] = 5,
["weapon"] = {
[Enum.ItemWeaponSubclass.Dagger] = true,
},
},
},
[StatLogic.Stats.WeaponSkill] = {
-- Talent: Mace Specializaiton
Expand Down Expand Up @@ -913,6 +939,17 @@ elseif addon.class == "SHAMAN" then
["value"] = 0.05,
},
},
["ADD_BLOCK_VALUE_MOD_SPELL_DMG"] = {
-- Set: Resolve of the Ten Storms (Elemental Shield) (SoD)
{
["set"] = 1819,
["pieces"] = 4,
["stack"] = 0.10,
["max_stacks"] = 3,
["aura"] = 467910,
["rune"] = true,
},
},
["MOD_AP"] = {
-- Rune: Two-Handed Mastery
{
Expand Down Expand Up @@ -945,17 +982,15 @@ elseif addon.class == "SHAMAN" then
},
},
["MOD_BLOCK_VALUE"] = {
-- Shaman: Shield Specialization 5/5 - 2,2
-- Increases your chance to block attacks with a shield by 5% and increases the amount blocked by 5%/10%/15%/20%/25%.
-- Talent: Shield Specialization
{
["tab"] = 2,
["num"] = 2,
["rank"] = {
0.05, 0.1, 0.15, 0.2, 0.25,
},
},
-- Shaman: Shield Mastery - Rune
-- You also always gain 10% increased chance to Block and 15% increased Block value.
-- Rune: Shield Mastery
{
["known"] = 408524,
["rune"] = true,
Expand Down

0 comments on commit 8a39fb7

Please sign in to comment.