Skip to content

Commit

Permalink
Merge pull request #816 from wowsims/p4/druid
Browse files Browse the repository at this point in the history
P4 Druid Sets + Update DB
  • Loading branch information
kayla-glick authored Jun 23, 2024
2 parents 988698f + 1d93a08 commit 065c680
Show file tree
Hide file tree
Showing 42 changed files with 12,351 additions and 10,271 deletions.
Binary file modified assets/database/db.bin
Binary file not shown.
1,626 changes: 1,125 additions & 501 deletions assets/database/db.json

Large diffs are not rendered by default.

Binary file modified assets/database/leftover_db.bin
Binary file not shown.
4 changes: 3 additions & 1 deletion assets/database/leftover_db.json
Original file line number Diff line number Diff line change
Expand Up @@ -1461,7 +1461,9 @@
{"id":223181,"name":"Geomancer's Spaulders","icon":"inv_shoulder_02","type":3,"armorType":1,"requiresLevel":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,38,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"randomSuffixOptions":[177,178,187,188,517,518,519,772,773,774,857,858,859,1027,1028,1029,1809,1810,1847,1848,1961,1962],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":3,"quality":2},
{"id":223182,"name":"Geomancer's Trousers","icon":"inv_pants_09","type":9,"armorType":1,"requiresLevel":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,45,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"randomSuffixOptions":[409,410,441,442,443,609,610,611,779,780,781,864,865,866,1034,1035,1036,1889,1890,2041,2042],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":3,"quality":2},
{"id":223183,"name":"Geomancer's Wraps","icon":"inv_chest_cloth_40","type":5,"armorType":1,"requiresLevel":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,54,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"randomSuffixOptions":[333,334,384,385,410,411,782,783,784,867,868,869,1037,1038,1039,1814,1815,1852,1853,1966,1967],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":3,"quality":2},
{"id":223186,"name":"Supply Expediter","icon":"ability_hunter_pathfinding","type":12,"requiresLevel":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":3,"quality":3,"sources":[{"rep":{"repFactionId":2586,"repLevel":8}},{"rep":{"repFactionId":2587,"repLevel":8}}]}
{"id":223186,"name":"Supply Expediter","icon":"ability_hunter_pathfinding","type":12,"requiresLevel":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":3,"quality":3,"sources":[{"rep":{"repFactionId":2586,"repLevel":8}},{"rep":{"repFactionId":2587,"repLevel":8}}]},
{"id":225838,"name":"Voltaic Icon","icon":"inv_relics_totemoflife","type":14,"rangedWeaponType":7,"requiresLevel":32,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":1,"quality":2,"unique":true,"classAllowlist":[7]},
{"id":226546,"name":"Desert Sonar","icon":"inv_misc_enggizmos_20","type":12,"requiresLevel":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"weaponSkills":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ilvl":1,"phase":1,"quality":1,"unique":true}
],
"randomSuffixes":[
],
Expand Down
19,530 changes: 10,278 additions & 9,252 deletions assets/db_inputs/wowhead_gearplannerdb.txt

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion proto/common.proto
Original file line number Diff line number Diff line change
Expand Up @@ -658,12 +658,13 @@ message Consumes {
bool bogling_root = 19 [deprecated=true];
}

// NextIndex: 35
// NextIndex: 36
message Debuffs {
bool judgement_of_wisdom = 1;
bool judgement_of_light = 2;
TristateEffect judgement_of_the_crusader = 33;
bool faerie_fire = 3;
TristateEffect faerie_fire_improved = 36;

// Bonus spell damage
bool curse_of_elements = 4 [deprecated=true];
Expand Down
54 changes: 36 additions & 18 deletions sim/common/sod/items_sets/dungeon_set_1.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"github.com/wowsims/sod/sim/core/stats"
)

var WildheartRaiment = core.NewItemSet(core.ItemSet{
var ItemSetWildheartRaiment = core.NewItemSet(core.ItemSet{
Name: "Wildheart Raiment",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand Down Expand Up @@ -37,7 +37,9 @@ var WildheartRaiment = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskSpellDamage | core.ProcMaskSpellHealing,
ProcChance: 0.02,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddMana(sim, 300, manaMetrics)
if c.HasManaBar() {
c.AddMana(sim, 300, manaMetrics)
}
},
})
core.MakeProcTriggerAura(&c.Unit, core.ProcTrigger{
Expand All @@ -47,7 +49,9 @@ var WildheartRaiment = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskMeleeWhiteHit,
ProcChance: 0.06,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddEnergy(sim, 40, energyMetrics)
if c.HasEnergyBar() {
c.AddEnergy(sim, 40, energyMetrics)
}
},
})
core.MakeProcTriggerAura(&c.Unit, core.ProcTrigger{
Expand All @@ -57,7 +61,9 @@ var WildheartRaiment = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskMelee,
ProcChance: 0.03,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddRage(sim, 10, rageMetrics)
if c.HasRageBar() {
c.AddRage(sim, 10, rageMetrics)
}
},
})
},
Expand All @@ -74,7 +80,7 @@ var WildheartRaiment = core.NewItemSet(core.ItemSet{
},
})

var BeaststalkerArmor = core.NewItemSet(core.ItemSet{
var ItemSetBeaststalkerArmor = core.NewItemSet(core.ItemSet{
Name: "Beaststalker Armor",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand All @@ -100,7 +106,9 @@ var BeaststalkerArmor = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskWhiteHit,
ProcChance: 0.06,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddMana(sim, 300, manaMetrics)
if c.HasManaBar() {
c.AddMana(sim, 300, manaMetrics)
}
},
})
},
Expand All @@ -117,7 +125,7 @@ var BeaststalkerArmor = core.NewItemSet(core.ItemSet{
},
})

var MagistersRegalia = core.NewItemSet(core.ItemSet{
var ItemSetMagistersRegalia = core.NewItemSet(core.ItemSet{
Name: "Magister's Regalia",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand All @@ -140,7 +148,9 @@ var MagistersRegalia = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskSpellDamage | core.ProcMaskSpellHealing,
ProcChance: 0.06,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddMana(sim, 300, manaMetrics)
if c.HasManaBar() {
c.AddMana(sim, 300, manaMetrics)
}
},
})
},
Expand All @@ -157,7 +167,7 @@ var MagistersRegalia = core.NewItemSet(core.ItemSet{
},
})

var LightforgeArmor = core.NewItemSet(core.ItemSet{
var ItemSetLightforgeArmor = core.NewItemSet(core.ItemSet{
Name: "Lightforge Armor",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand Down Expand Up @@ -211,7 +221,7 @@ var LightforgeArmor = core.NewItemSet(core.ItemSet{
},
})

var VestmentsOfTheDevout = core.NewItemSet(core.ItemSet{
var ItemSetVestmentsOfTheDevout = core.NewItemSet(core.ItemSet{
Name: "Vestments of the Devout",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand All @@ -234,7 +244,9 @@ var VestmentsOfTheDevout = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskSpellDamage | core.ProcMaskSpellHealing,
ProcChance: 0.06,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddMana(sim, 300, manaMetrics)
if c.HasManaBar() {
c.AddMana(sim, 300, manaMetrics)
}
},
})
},
Expand All @@ -251,7 +263,7 @@ var VestmentsOfTheDevout = core.NewItemSet(core.ItemSet{
},
})

var ShadowcraftArmor = core.NewItemSet(core.ItemSet{
var ItemSetShadowcraftArmor = core.NewItemSet(core.ItemSet{
Name: "Shadowcraft Armor",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand All @@ -277,7 +289,9 @@ var ShadowcraftArmor = core.NewItemSet(core.ItemSet{
ProcMask: core.ProcMaskMelee,
PPM: 1,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddEnergy(sim, 35, energyMetrics)
if c.HasEnergyBar() {
c.AddEnergy(sim, 35, energyMetrics)
}
},
})
},
Expand All @@ -294,7 +308,7 @@ var ShadowcraftArmor = core.NewItemSet(core.ItemSet{
},
})

var TheElements = core.NewItemSet(core.ItemSet{
var ItemSetTheElements = core.NewItemSet(core.ItemSet{
Name: "The Elements",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand Down Expand Up @@ -349,7 +363,7 @@ var TheElements = core.NewItemSet(core.ItemSet{
},
})

var DreadmistRaiment = core.NewItemSet(core.ItemSet{
var ItemSetDreadmistRaiment = core.NewItemSet(core.ItemSet{
Name: "Dreadmist Raiment",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand All @@ -366,7 +380,9 @@ var DreadmistRaiment = core.NewItemSet(core.ItemSet{
manaMetrics := c.NewManaMetrics(core.ActionID{SpellID: 450583})

handler := func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.AddMana(sim, sim.Roll(270, 300), manaMetrics)
if c.HasManaBar() {
c.AddMana(sim, sim.Roll(270, 300), manaMetrics)
}
}

core.MakeProcTriggerAura(&c.Unit, core.ProcTrigger{
Expand Down Expand Up @@ -399,7 +415,7 @@ var DreadmistRaiment = core.NewItemSet(core.ItemSet{
},
})

var BattlegearOfValor = core.NewItemSet(core.ItemSet{
var ItemSetBattlegearOfValor = core.NewItemSet(core.ItemSet{
Name: "Battlegear of Valor",
Bonuses: map[int32]core.ApplyEffect{
2: func(agent core.Agent) {
Expand Down Expand Up @@ -427,7 +443,9 @@ var BattlegearOfValor = core.NewItemSet(core.ItemSet{
PPM: 1,
Handler: func(sim *core.Simulation, spell *core.Spell, _ *core.SpellResult) {
c.GainHealth(sim, sim.Roll(88, 132), healthMetrics)
c.AddRage(sim, 10, rageMetrics)
if c.HasRageBar() {
c.AddRage(sim, 10, rageMetrics)
}
},
})
},
Expand Down
20 changes: 17 additions & 3 deletions sim/core/debuffs.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,12 @@ func applyDebuffEffects(target *Unit, targetIdx int, debuffs *proto.Debuffs, rai
MakePermanent(CurseOfRecklessnessAura(target, level))
}

if debuffs.FaerieFire {
MakePermanent(FaerieFireAura(target, level))
// if debuffs.FaerieFire {
// MakePermanent(FaerieFireAura(target, level))
// }

if debuffs.FaerieFireImproved != proto.TristateEffect_TristateEffectMissing {
MakePermanent(FaerieFireAura(target, level, debuffs.FaerieFireImproved == proto.TristateEffect_TristateEffectImproved))
}

if debuffs.CurseOfWeakness != proto.TristateEffect_TristateEffectMissing {
Expand Down Expand Up @@ -921,7 +925,9 @@ func CurseOfRecklessnessAura(target *Unit, playerLevel int32) *Aura {
return aura
}

func FaerieFireAura(target *Unit, playerLevel int32) *Aura {
// Decreases the armor of the target by X for 40 sec.
// Improved: Your Faerie Fire and Faerie Fire (Feral) also increase the chance for all attacks to hit that target by 1% for 40 sec.
func FaerieFireAura(target *Unit, playerLevel int32, improved bool) *Aura {
spellID := map[int32]int32{
25: 770,
40: 778,
Expand All @@ -942,9 +948,17 @@ func FaerieFireAura(target *Unit, playerLevel int32) *Aura {
Duration: time.Second * 40,
OnGain: func(aura *Aura, sim *Simulation) {
aura.Unit.AddStatDynamic(sim, stats.Armor, -arpen)
if improved {
aura.Unit.PseudoStats.BonusMeleeHitRatingTaken += 1 * SpellHitRatingPerHitChance
aura.Unit.PseudoStats.BonusSpellHitRatingTaken += 1 * SpellHitRatingPerHitChance
}
},
OnExpire: func(aura *Aura, sim *Simulation) {
aura.Unit.AddStatDynamic(sim, stats.Armor, arpen)
if improved {
aura.Unit.PseudoStats.BonusMeleeHitRatingTaken -= 1 * SpellHitRatingPerHitChance
aura.Unit.PseudoStats.BonusSpellHitRatingTaken -= 1 * SpellHitRatingPerHitChance
}
},
})
return aura
Expand Down
3 changes: 3 additions & 0 deletions sim/core/spell.go
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,9 @@ func (unit *Unit) GetOrRegisterSpell(config SpellConfig) *Spell {
}
}

func (spell *Spell) Dots() []*Dot {
return spell.dots
}
func (spell *Spell) Dot(target *Unit) *Dot {
return spell.dots.Get(target)
}
Expand Down
6 changes: 3 additions & 3 deletions sim/core/test_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ var FullDebuffsPhase1 = &proto.Debuffs{
DemoralizingShout: proto.TristateEffect_TristateEffectImproved,
Dreamstate: true,
ExposeArmor: proto.TristateEffect_TristateEffectImproved,
FaerieFire: true,
FaerieFireImproved: proto.TristateEffect_TristateEffectRegular,
InsectSwarm: true,
ImprovedShadowBolt: true,
ScorpidSting: true,
Expand All @@ -225,7 +225,7 @@ var FullDebuffsPhase2 = &proto.Debuffs{
DemoralizingShout: proto.TristateEffect_TristateEffectImproved,
Dreamstate: true,
ExposeArmor: proto.TristateEffect_TristateEffectImproved,
FaerieFire: true,
FaerieFireImproved: proto.TristateEffect_TristateEffectRegular,
InsectSwarm: true,
ImprovedScorch: true,
ImprovedShadowBolt: true,
Expand All @@ -250,7 +250,7 @@ var FullDebuffsPhase3 = &proto.Debuffs{
DemoralizingShout: proto.TristateEffect_TristateEffectImproved,
Dreamstate: true,
ExposeArmor: proto.TristateEffect_TristateEffectImproved,
FaerieFire: true,
FaerieFireImproved: proto.TristateEffect_TristateEffectRegular,
InsectSwarm: true,
ImprovedScorch: true,
ImprovedShadowBolt: true,
Expand Down
42 changes: 42 additions & 0 deletions sim/druid/balance/TestBalance.results
Original file line number Diff line number Diff line change
Expand Up @@ -390,6 +390,13 @@ stat_weights_results: {
weights: 0
}
}
dps_results: {
key: "TestBalance-Lvl25-AllItems-FeralheartRaiment"
value: {
dps: 149.47558
tps: 153.29033
}
}
dps_results: {
key: "TestBalance-Lvl25-Average-Default"
value: {
Expand Down Expand Up @@ -488,6 +495,13 @@ dps_results: {
tps: 180.64991
}
}
dps_results: {
key: "TestBalance-Lvl40-AllItems-FeralheartRaiment"
value: {
dps: 219.92224
tps: 228.29649
}
}
dps_results: {
key: "TestBalance-Lvl40-Average-Default"
value: {
Expand Down Expand Up @@ -586,6 +600,13 @@ dps_results: {
tps: 655.69788
}
}
dps_results: {
key: "TestBalance-Lvl50-AllItems-FeralheartRaiment"
value: {
dps: 469.62547
tps: 484.36381
}
}
dps_results: {
key: "TestBalance-Lvl50-Average-Default"
value: {
Expand Down Expand Up @@ -705,6 +726,13 @@ dps_results: {
tps: 511.61449
}
}
dps_results: {
key: "TestBalance-Lvl60-AllItems-Champion'sSanctuary"
value: {
dps: 529.21204
tps: 544.40014
}
}
dps_results: {
key: "TestBalance-Lvl60-AllItems-CoagulateBloodguard'sLeathers"
value: {
Expand Down Expand Up @@ -740,6 +768,13 @@ dps_results: {
tps: 675.99835
}
}
dps_results: {
key: "TestBalance-Lvl60-AllItems-FeralheartRaiment"
value: {
dps: 477.26204
tps: 493.29805
}
}
dps_results: {
key: "TestBalance-Lvl60-AllItems-Knight-Lieutenant'sCracklingLeather"
value: {
Expand All @@ -761,6 +796,13 @@ dps_results: {
tps: 511.61449
}
}
dps_results: {
key: "TestBalance-Lvl60-AllItems-LieutenantCommander'sSanctuary"
value: {
dps: 529.21204
tps: 544.40014
}
}
dps_results: {
key: "TestBalance-Lvl60-AllItems-LostWorshipper'sArmor"
value: {
Expand Down
4 changes: 4 additions & 0 deletions sim/druid/druid.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ var TalentTreeSizes = [3]int{16, 16, 15}

const (
SpellCode_DruidNone int32 = iota

SpellCode_FerociousBite
SpellCode_DruidMoonfire
SpellCode_DruidRip
SpellCode_DruidShred
SpellCode_DruidStarfire
SpellCode_DruidStarsurge
Expand Down Expand Up @@ -48,6 +51,7 @@ type Druid struct {
FrenziedRegeneration *DruidSpell
GiftOfTheWild *DruidSpell
Hurricane []*DruidSpell
Innervate *DruidSpell
InsectSwarm []*DruidSpell
Lacerate *DruidSpell
Languish *DruidSpell
Expand Down
Loading

0 comments on commit 065c680

Please sign in to comment.