Skip to content

Commit

Permalink
Merge pull request #152 from wowsims/sharp_stone
Browse files Browse the repository at this point in the history
fix dense stone consumable
  • Loading branch information
rosenrusinov authored Feb 8, 2024
2 parents defa515 + 5e49bc0 commit 929b2e7
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions sim/core/consumes.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ func applyConsumeEffects(agent Agent, partyBuffs *proto.PartyBuffs) {
}

if character.HasMHWeapon() {
addImbueStats(character, consumes.MainHandImbue)
addImbueStats(character, consumes.MainHandImbue, true)
}
if character.HasOHWeapon() {
addImbueStats(character, consumes.OffHandImbue)
addImbueStats(character, consumes.OffHandImbue, false)
}

if consumes.Food != proto.Food_FoodUnknown {
Expand Down Expand Up @@ -205,7 +205,7 @@ func applyConsumeEffects(agent Agent, partyBuffs *proto.PartyBuffs) {
registerExplosivesCD(agent, consumes)
}

func addImbueStats(character *Character, imbue proto.WeaponImbue) {
func addImbueStats(character *Character, imbue proto.WeaponImbue, isMh bool) {
if imbue != proto.WeaponImbue_WeaponImbueUnknown {
switch imbue {
case proto.WeaponImbue_BrillianWizardOil:
Expand All @@ -218,11 +218,13 @@ func addImbueStats(character *Character, imbue proto.WeaponImbue) {
stats.MP5: 5,
stats.Healing: 25,
})
// TODO: Classic
// case proto.WeaponImbue_DenseSharpeningStone:
// character.AddStats(stats.Stats{
// stats.WeaponDamage??: 5,
// })
case proto.WeaponImbue_DenseSharpeningStone:
weapon := character.AutoAttacks.MH()
if !isMh {
weapon = character.AutoAttacks.OH()
}
weapon.BaseDamageMin += 8
weapon.BaseDamageMax += 8
case proto.WeaponImbue_ElementalSharpeningStone:
character.AddStats(stats.Stats{
stats.MeleeCrit: 2 * CritRatingPerCritChance,
Expand Down

0 comments on commit 929b2e7

Please sign in to comment.