Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bloodfury str=>ap conversion #872

Merged
merged 1 commit into from
Jul 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
12 changes: 12 additions & 0 deletions sim/core/base_stats.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,18 @@ var ClassBaseCrit = map[proto.Class]stats.Stats{
},
}

var APPerStrength = map[proto.Class]float64{
proto.Class_ClassWarrior: 2,
proto.Class_ClassPaladin: 2,
proto.Class_ClassHunter: 1,
proto.Class_ClassRogue: 1,
proto.Class_ClassPriest: 1,
proto.Class_ClassShaman: 2,
proto.Class_ClassMage: 1,
proto.Class_ClassWarlock: 1,
proto.Class_ClassDruid: 2,
}

// Melee/Ranged crit agi scaling
var CritPerAgiAtLevel = map[proto.Class]map[int]float64{
proto.Class_ClassUnknown: {25: 0.0, 40: 0.0, 50: 0.0, 60: 0.0},
Expand Down
2 changes: 1 addition & 1 deletion sim/core/racials.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ func applyRaceEffects(agent Agent) {
Duration: time.Second * 15,
// Tooltip is misleading; ap bonus is base AP plus AP from current strength, does not include +attackpower on items/buffs
OnGain: func(aura *Aura, sim *Simulation) {
bloodFuryAP = (character.GetBaseStats()[stats.AttackPower] + (character.GetStat(stats.Strength) * 2)) * 0.25
bloodFuryAP = (character.GetBaseStats()[stats.AttackPower] + (character.GetStat(stats.Strength) * APPerStrength[character.Class])) * 0.25
character.AddStatDynamic(sim, stats.AttackPower, bloodFuryAP)
},

Expand Down
2 changes: 1 addition & 1 deletion sim/druid/druid.go
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ func New(character *core.Character, form DruidForm, selfBuffs SelfBuffs, talents
druid.EnableManaBar()

// TODO: Class druid physical stats
druid.AddStatDependency(stats.Strength, stats.AttackPower, 2)
druid.AddStatDependency(stats.Strength, stats.AttackPower, core.APPerStrength[character.Class])
druid.AddStatDependency(stats.BonusArmor, stats.Armor, 1)
druid.AddStatDependency(stats.Agility, stats.MeleeCrit, core.CritPerAgiAtLevel[character.Class][int(druid.Level)]*core.CritRatingPerCritChance)
druid.AddStatDependency(stats.Intellect, stats.SpellCrit, core.CritPerIntAtLevel[character.Class][int(druid.Level)]*core.SpellCritRatingPerCritChance)
Expand Down
46 changes: 23 additions & 23 deletions sim/hunter/TestBM.results
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ stat_weights_results: {
key: "TestBM-Lvl40-StatWeights-Default"
value: {
weights: 0
weights: 0.8085
weights: 0.8079
weights: 0
weights: 0
weights: 0
Expand All @@ -166,8 +166,8 @@ stat_weights_results: {
weights: 0
weights: 0
weights: 0.31124
weights: 8.46821
weights: 7.64026
weights: 8.44271
weights: 7.62158
weights: 0
weights: 0
weights: 0
Expand Down Expand Up @@ -302,22 +302,22 @@ dps_results: {
dps_results: {
key: "TestBM-Lvl40-AllItems-BeastmasterArmor"
value: {
dps: 527.83604
tps: 239.75095
dps: 527.06296
tps: 238.97786
}
}
dps_results: {
key: "TestBM-Lvl40-AllItems-SignetofBeasts-209823"
value: {
dps: 838.59889
tps: 321.29786
dps: 836.59954
tps: 320.1109
}
}
dps_results: {
key: "TestBM-Lvl40-Average-Default"
value: {
dps: 849.12016
tps: 328.13556
dps: 847.09336
tps: 326.90583
}
}
dps_results: {
Expand Down Expand Up @@ -491,43 +491,43 @@ dps_results: {
dps_results: {
key: "TestBM-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-FullBuffs-Phase 2 Consumes-LongMultiTarget"
value: {
dps: 1635.24911
tps: 992.4943
dps: 1630.77885
tps: 990.55107
}
}
dps_results: {
key: "TestBM-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-FullBuffs-Phase 2 Consumes-LongSingleTarget"
value: {
dps: 745.63236
tps: 236.04306
dps: 744.69965
tps: 235.90031
}
}
dps_results: {
key: "TestBM-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-FullBuffs-Phase 2 Consumes-ShortSingleTarget"
value: {
dps: 788.82445
tps: 249.1845
dps: 787.53742
tps: 249.04312
}
}
dps_results: {
key: "TestBM-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-NoBuffs-Phase 2 Consumes-LongMultiTarget"
value: {
dps: 865.15225
tps: 634.09869
dps: 863.26146
tps: 633.2562
}
}
dps_results: {
key: "TestBM-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-NoBuffs-Phase 2 Consumes-LongSingleTarget"
value: {
dps: 373.97251
tps: 129.19582
dps: 373.62562
tps: 129.14291
}
}
dps_results: {
key: "TestBM-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-NoBuffs-Phase 2 Consumes-ShortSingleTarget"
value: {
dps: 407.26555
tps: 135.24739
dps: 406.77043
tps: 135.17851
}
}
dps_results: {
Expand Down Expand Up @@ -659,7 +659,7 @@ dps_results: {
dps_results: {
key: "TestBM-Lvl40-SwitchInFrontOfTarget-Default"
value: {
dps: 805.77815
tps: 300.9746
dps: 803.96822
tps: 299.90694
}
}
44 changes: 22 additions & 22 deletions sim/hunter/TestSV.results
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,8 @@ stat_weights_results: {
weights: 0
weights: 0
weights: 0.35631
weights: 0.43666
weights: 6.71901
weights: 0.36455
weights: 6.70309
weights: 0
weights: 0
weights: 0
Expand Down Expand Up @@ -302,22 +302,22 @@ dps_results: {
dps_results: {
key: "TestSV-Lvl40-AllItems-BeastmasterArmor"
value: {
dps: 435.22146
tps: 272.1554
dps: 434.39369
tps: 271.32762
}
}
dps_results: {
key: "TestSV-Lvl40-AllItems-SignetofBeasts-209823"
value: {
dps: 792.67024
tps: 356.36949
dps: 790.46674
tps: 355.09957
}
}
dps_results: {
key: "TestSV-Lvl40-Average-Default"
value: {
dps: 801.81039
tps: 362.65002
dps: 799.53008
tps: 361.30319
}
}
dps_results: {
Expand Down Expand Up @@ -365,49 +365,49 @@ dps_results: {
dps_results: {
key: "TestSV-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-FullBuffs-Phase 2 Consumes-LongMultiTarget"
value: {
dps: 1622.39123
tps: 1026.15453
dps: 1617.31294
tps: 1023.9301
}
}
dps_results: {
key: "TestSV-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-FullBuffs-Phase 2 Consumes-LongSingleTarget"
value: {
dps: 663.99075
tps: 245.00558
dps: 662.87964
tps: 244.83736
}
}
dps_results: {
key: "TestSV-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-FullBuffs-Phase 2 Consumes-ShortSingleTarget"
value: {
dps: 682.32512
tps: 258.2862
dps: 680.75712
tps: 258.06929
}
}
dps_results: {
key: "TestSV-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-NoBuffs-Phase 2 Consumes-LongMultiTarget"
value: {
dps: 859.13143
tps: 636.55664
dps: 856.99433
tps: 635.62351
}
}
dps_results: {
key: "TestSV-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-NoBuffs-Phase 2 Consumes-LongSingleTarget"
value: {
dps: 338.27763
tps: 134.99062
dps: 337.85046
tps: 134.93215
}
}
dps_results: {
key: "TestSV-Lvl40-Settings-Orc-p2_melee-Basic-p2_melee-NoBuffs-Phase 2 Consumes-ShortSingleTarget"
value: {
dps: 360.65389
tps: 138.63798
dps: 359.98879
tps: 138.54583
}
}
dps_results: {
key: "TestSV-Lvl40-SwitchInFrontOfTarget-Default"
value: {
dps: 758.75605
tps: 337.89003
dps: 756.63543
tps: 336.64431
}
}
2 changes: 1 addition & 1 deletion sim/hunter/hunter.go
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ func NewHunter(character *core.Character, options *proto.Player) *Hunter {

hunter.pet = hunter.NewHunterPet()

hunter.AddStatDependency(stats.Strength, stats.AttackPower, 1)
hunter.AddStatDependency(stats.Strength, stats.AttackPower, core.APPerStrength[character.Class])
hunter.AddStatDependency(stats.Agility, stats.AttackPower, 1)
hunter.AddStatDependency(stats.Agility, stats.RangedAttackPower, 2)
hunter.AddStatDependency(stats.Agility, stats.MeleeCrit, core.CritPerAgiAtLevel[character.Class][int(character.Level)]*core.CritRatingPerCritChance)
Expand Down
4 changes: 2 additions & 2 deletions sim/mage/TestArcane.results
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ character_stats_results: {
final_stats: 30.39344
final_stats: 0
final_stats: 0
final_stats: 328
final_stats: 406.4
final_stats: 2
final_stats: 8.2
final_stats: 0
Expand Down Expand Up @@ -67,7 +67,7 @@ character_stats_results: {
final_stats: 50.2224
final_stats: 0
final_stats: 0
final_stats: 1042
final_stats: 1201.5
final_stats: 2
final_stats: 18.2
final_stats: 0
Expand Down
6 changes: 3 additions & 3 deletions sim/mage/TestFire.results
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ character_stats_results: {
final_stats: 30.39344
final_stats: 0
final_stats: 0
final_stats: 328
final_stats: 406.4
final_stats: 2
final_stats: 8.2
final_stats: 0
Expand Down Expand Up @@ -67,7 +67,7 @@ character_stats_results: {
final_stats: 42.9179
final_stats: 0
final_stats: 0
final_stats: 460
final_stats: 572.28
final_stats: 0
final_stats: 19.2
final_stats: 0
Expand Down Expand Up @@ -116,7 +116,7 @@ character_stats_results: {
final_stats: 50.25936
final_stats: 0
final_stats: 0
final_stats: 1042
final_stats: 1201.5
final_stats: 2
final_stats: 18.2
final_stats: 0
Expand Down
4 changes: 2 additions & 2 deletions sim/mage/TestFrost.results
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ character_stats_results: {
final_stats: 23.04324
final_stats: 0
final_stats: 0
final_stats: 460
final_stats: 572.28
final_stats: 0
final_stats: 19.2
final_stats: 0
Expand Down Expand Up @@ -67,7 +67,7 @@ character_stats_results: {
final_stats: 13.1808
final_stats: 0
final_stats: 0
final_stats: -10
final_stats: 24
final_stats: 2
final_stats: 5.2
final_stats: 0
Expand Down
1 change: 1 addition & 0 deletions sim/mage/mage.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ func NewMage(character *core.Character, options *proto.Player) *Mage {

mage.EnableManaBar()

mage.AddStatDependency(stats.Strength, stats.AttackPower, core.APPerStrength[character.Class])
mage.AddStatDependency(stats.Intellect, stats.SpellCrit, core.CritPerIntAtLevel[mage.Class][int(mage.Level)]*core.SpellCritRatingPerCritChance)

switch mage.Options.Armor {
Expand Down
2 changes: 1 addition & 1 deletion sim/paladin/paladin.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ func NewPaladin(character *core.Character, talentsStr string) *Paladin {

paladin.PseudoStats.CanParry = true
paladin.EnableManaBar()
paladin.AddStatDependency(stats.Strength, stats.AttackPower, 2.0)
paladin.AddStatDependency(stats.Strength, stats.AttackPower, core.APPerStrength[character.Class])
paladin.AddStatDependency(stats.Agility, stats.MeleeCrit, core.CritPerAgiAtLevel[character.Class][int(paladin.Level)]*core.CritRatingPerCritChance)
paladin.AddStatDependency(stats.Intellect, stats.SpellCrit, core.CritPerIntAtLevel[character.Class][int(paladin.Level)]*core.SpellCritRatingPerCritChance)

Expand Down
1 change: 1 addition & 0 deletions sim/priest/priest.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ func New(character *core.Character, talents string) *Priest {

priest.EnableManaBar()

priest.AddStatDependency(stats.Strength, stats.AttackPower, core.APPerStrength[character.Class])
priest.AddStatDependency(stats.Intellect, stats.SpellCrit, core.CritPerIntAtLevel[priest.Class][int(priest.Level)]*core.SpellCritRatingPerCritChance)

// Set mana regen to 12.5 + Spirit/4 each 2s tick
Expand Down
8 changes: 4 additions & 4 deletions sim/priest/shadow/TestShadow.results
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ character_stats_results: {
final_stats: 6.93294
final_stats: 0
final_stats: 10
final_stats: 207
final_stats: 265.2
final_stats: 1
final_stats: 5
final_stats: 0
Expand Down Expand Up @@ -67,7 +67,7 @@ character_stats_results: {
final_stats: 13.48128
final_stats: 0
final_stats: 0
final_stats: 328
final_stats: 415.2
final_stats: 2
final_stats: 6
final_stats: 0
Expand Down Expand Up @@ -116,7 +116,7 @@ character_stats_results: {
final_stats: 20.9776
final_stats: 0
final_stats: 0
final_stats: 460
final_stats: 577.032
final_stats: 3
final_stats: 17
final_stats: 0
Expand Down Expand Up @@ -165,7 +165,7 @@ character_stats_results: {
final_stats: 28.04832
final_stats: 0
final_stats: 0
final_stats: 1042
final_stats: 1207
final_stats: 3
final_stats: 17
final_stats: 0
Expand Down
Loading
Loading