Skip to content

Commit

Permalink
Merge pull request #1204 from wowsims/spriest_BL_updates
Browse files Browse the repository at this point in the history
MF Bug added to the sim. Will remove when bug is fixed
  • Loading branch information
dbyena authored Oct 4, 2022
2 parents 5202bab + 380fbac commit b960d10
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 3 deletions.
34 changes: 33 additions & 1 deletion sim/priest/mind_flay.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ func (priest *Priest) newMindFlaySpell(numTicks int) *core.Spell {
baseCost := priest.BaseMana * 0.09

channelTime := time.Second * time.Duration(numTicks)
for _, gem := range priest.Equip[proto.ItemSlot_ItemSlotHead].Gems {
if gem.ID == 25895 || gem.ID == 41335 {
channelTime = channelTime - time.Duration(numTicks)*(time.Millisecond*100)
}
}
// ADDED TROLL MF BUG 15% REDUCED CHANNEL TIME DUE TO DA VOODOO SHUFFLE
if priest.GetCharacter().Race == proto.Race_RaceTroll {
channelTime = channelTime - time.Duration(numTicks)*(time.Millisecond*150)
}
if priest.HasSetBonus(ItemSetCrimsonAcolyte, 4) {
channelTime = channelTime - time.Duration(numTicks)*(time.Millisecond*170)
}
Expand Down Expand Up @@ -86,6 +95,20 @@ func (priest *Priest) newMindFlayDot(numTicks int) *core.Dot {
normMod := 1 + float64(priest.Talents.Darkness)*0.02 + float64(priest.Talents.TwinDisciplines)*0.01 // initialize modifier

var mfReducTime time.Duration
// ADDED Bug where root resist gem reduces MF by 10%
// ADDED TROLL MF BUG 15% REDUCED CHANNEL TIME DUE TO DA VOODOO SHUFFLE
if priest.GetCharacter().Race == proto.Race_RaceTroll {
mfReducTime = time.Millisecond * 150
}

for _, gem := range priest.Equip[proto.ItemSlot_ItemSlotHead].Gems {
if gem.ID == 25895 || gem.ID == 41335 {
mfReducTime = time.Millisecond * 100
if priest.GetCharacter().Race == proto.Race_RaceTroll {
mfReducTime = time.Millisecond*150 + time.Millisecond*100
}
}
}
if priest.HasSetBonus(ItemSetCrimsonAcolyte, 4) {
mfReducTime = time.Millisecond * 170
}
Expand Down Expand Up @@ -144,5 +167,14 @@ func (priest *Priest) newMindFlayDot(numTicks int) *core.Dot {
}

func (priest *Priest) MindFlayTickDuration() time.Duration {
return priest.ApplyCastSpeed(time.Second - core.TernaryDuration(priest.T10FourSetBonus, time.Millisecond*170, 0))
mfReducTime := time.Millisecond * 0
for _, gem := range priest.Equip[proto.ItemSlot_ItemSlotHead].Gems {
if gem.ID == 25895 || gem.ID == 41335 {
mfReducTime = time.Millisecond * 100
if priest.GetCharacter().Race == proto.Race_RaceTroll {
mfReducTime = time.Millisecond*150 + time.Millisecond*100
}
}
}
return priest.ApplyCastSpeed(time.Second - core.TernaryDuration(priest.T10FourSetBonus, time.Millisecond*170, 0) - core.TernaryDuration(priest.GetCharacter().Race == proto.Race_RaceTroll, time.Millisecond*150, 0) - mfReducTime)
}
4 changes: 2 additions & 2 deletions sim/priest/shadow/TestShadow.results
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,8 @@ dps_results: {
dps_results: {
key: "TestShadow-AllItems-EnigmaticSkyflareDiamond"
value: {
dps: 4567.06306
tps: 3471.94338
dps: 4691.41308
tps: 3564.6456
}
}
dps_results: {
Expand Down
16 changes: 16 additions & 0 deletions sim/priest/shadow/rotation.go
Original file line number Diff line number Diff line change
Expand Up @@ -699,6 +699,22 @@ func (spriest *ShadowPriest) tryUseGCD(sim *core.Simulation) {
return
}

if numTicks == 3 {
// IF TROLL IS ALSO USING STUN RESIST META GEM, THEN THEY LOSE THE LAST TICK OF MF
reduc1 := 0
reduc2 := 0
for _, gem := range spriest.Equip[proto.ItemSlot_ItemSlotHead].Gems {
if gem.ID == 25895 || gem.ID == 41335 {
reduc1 = 1
if spriest.GetCharacter().Race == proto.Race_RaceTroll {
reduc2 = 1
}
}
}
if reduc1+reduc2 == 2 {
numTicks = numTicks - 1
}
}
spell = spriest.MindFlay[numTicks]
} else {

Expand Down

0 comments on commit b960d10

Please sign in to comment.