Documentation
¶
Index ¶
- Constants
- Variables
- type Warrior
- func (warrior *Warrior) AddPartyBuffs(_ *proto.PartyBuffs)
- func (warrior *Warrior) AddRaidBuffs(raidBuffs *proto.RaidBuffs)
- func (warrior *Warrior) ApplyTalents()
- func (warrior *Warrior) CastNormalizedSweepingStrikesAttack(results core.SpellResultSlice, sim *core.Simulation)
- func (warrior *Warrior) GetCharacter() *core.Character
- func (warrior *Warrior) GetMainHandType() proto.HandType
- func (warrior *Warrior) Initialize()
- func (warrior *Warrior) OnEncounterStart(sim *core.Simulation)
- func (warrior *Warrior) Reset(_ *core.Simulation)
- func (warrior *Warrior) TryHSOrCleave(sim *core.Simulation, mhSwingSpell *core.Spell) *core.Spell
- type WarriorAgent
- type WarriorInputs
Constants ¶
const ShoutExpirationThreshold = time.Second * 3
How close to running out the warrior's own shout has to be before recasting it is worth a global.
Variables ¶
var ItemSetBattlegearOfGlory = core.NewItemSet(core.ItemSet{ Name: "Battlegear of Glory", ID: 2102, Slots: tierOneSlots, Bonuses: map[int32]core.ApplySetBonus{ 2: parsedSetBonus(battlegearGloryHaste), 3: parsedSetBonus(battlegearGloryShoutCooldown), 4: parsedSetBonus(battlegearGloryHumanoidPower), 5: parsedSetBonus(battlegearGloryRecklessnessCD), }, })
Tier 1 - Arms/Fury
var ItemSetBattlegearOfMight = core.NewItemSet(core.ItemSet{ Name: "Battlegear of Might", ID: 209, Bonuses: map[int32]core.ApplySetBonus{ 3: func(agent core.Agent, setBonusAura *core.Aura) { setBonusAura.AttachStatBuff(stats.BlockValue, mightBlockValue.EffectN(1).BaseValue()) }, 5: func(agent core.Agent, setBonusAura *core.Aura) { warrior := agent.(WarriorAgent).GetWarrior() gain := shared.FiredSpellHandler(&warrior.Character, core.ActionID{SpellID: mightRageEnergize.ID}, mightRageProc) trigger := spelldata.ProcTrigger(&warrior.Character, mightRageProc, gain) trigger.Name = "Battlegear of Might - 5PC" setBonusAura.AttachProcTrigger(trigger) }, 8: func(agent core.Agent, setBonusAura *core.Aura) { setBonusAura.AttachSpellMod(core.SpellModConfig{ ClassFlags: mightSunderThreat.EffectN(1).ClassFlags, Kind: core.SpellMod_FlatThreatBonus_Pct, FloatValue: mightSunderThreat.EffectN(1).Percent(), }) }, }, })
TODO: items 16861-16868 have no ItemSparse rows in the game files, so the set cannot be worn yet.
var ItemSetBattlegearOfWrath = core.NewItemSet(core.ItemSet{ Name: "Battlegear of Wrath", ID: 218, Bonuses: map[int32]core.ApplySetBonus{ 3: func(agent core.Agent, setBonusAura *core.Aura) { if setBonusAura.BuildPhase == core.CharacterBuildPhaseGear { agent.(WarriorAgent).GetWarrior().HasBsT2 = true } }, 5: func(agent core.Agent, setBonusAura *core.Aura) { warrior := agent.(WarriorAgent).GetWarrior() discounted := wrathDiscountBuff.EffectN(1).ClassFlags buff := warrior.RegisterAura(spelldata.AuraConfig(wrathDiscountBuff)) spelldata.ParseEffects(&warrior.Character, buff, wrathDiscountBuff) buff.AttachProcTrigger(core.ProcTrigger{ Name: "Warrior's Wrath - Consume", ClassFlags: discounted, Callback: core.CallbackOnCastComplete, TriggerImmediately: true, Handler: func(sim *core.Simulation, _ *core.Spell, _ *core.SpellResult) { buff.Deactivate(sim) }, }) trigger := spelldata.ProcTrigger(&warrior.Character, wrathDiscountProc, func(sim *core.Simulation, _ *core.Spell, _ *core.SpellResult) { buff.Activate(sim) }) trigger.Name = "Battlegear of Wrath - 5PC" trigger.ClassFlags = discounted setBonusAura.AttachProcTrigger(trigger) }, 8: func(agent core.Agent, setBonusAura *core.Aura) { warrior := agent.(WarriorAgent).GetWarrior() parry := warrior.RegisterAura(spelldata.AuraConfig(wrathParryBuff, spelldata.Label("Battlegear of Wrath Parry"))) spelldata.ParseEffects(&warrior.Character, parry, wrathParryBuff) consume := spelldata.ProcTrigger(&warrior.Character, wrathParryBuff, func(sim *core.Simulation, _ *core.Spell, _ *core.SpellResult) { parry.Deactivate(sim) }) consume.Name = "Battlegear of Wrath - 8PC Consume" consume.Outcome = core.OutcomeEmpty consume.RequireDamageDealt = false consume.TriggerImmediately = true parry.AttachProcTrigger(consume) trigger := spelldata.ProcTrigger(&warrior.Character, wrathParryProc, func(sim *core.Simulation, _ *core.Spell, _ *core.SpellResult) { parry.Activate(sim) }) trigger.Name = "Battlegear of Wrath - 8PC" setBonusAura.AttachProcTrigger(trigger) }, }, })
TODO: items 16959-16966 have no ItemSparse rows in the game files, so the set cannot be worn yet.
var ItemSetBattleplateOfGlory = core.NewItemSet(core.ItemSet{ Name: "Battleplate of Glory", ID: 2103, Slots: tierOneSlots, Bonuses: map[int32]core.ApplySetBonus{ 2: parsedSetBonus(battleplateGloryDefense), 3: parsedSetBonus(battleplateGloryIntervene), 4: parsedSetBonus(battleplateGloryExpertise), 5: parsedSetBonus(battleplateGloryShieldWallCD), }, })
Tier 1 - Protection
var ItemSetConquerorsBattlegear = core.NewItemSet(core.ItemSet{ Name: "Conqueror's Battlegear", ID: 496, Bonuses: map[int32]core.ApplySetBonus{ 3: func(agent core.Agent, setBonusAura *core.Aura) { warrior := agent.(WarriorAgent).GetWarrior() spelldata.ParseEffects(&warrior.Character, setBonusAura, conquerorShoutCost) }, 5: func(agent core.Agent, setBonusAura *core.Aura) { warrior := agent.(WarriorAgent).GetWarrior() spelldata.ParseEffects(&warrior.Character, setBonusAura, conquerorThunderClap) setBonusAura.AttachAdditivePseudoStatBuff(&warrior.thunderClapEffectBonus, conquerorThunderClap.EffectN(1).Percent()) }, }, })
var ItemSetDreadnaughtsBattlegear = core.NewItemSet(core.ItemSet{ Name: "Dreadnaught's Battlegear", ID: 523, Slots: shared.TierThreeSlots, Bonuses: map[int32]core.ApplySetBonus{ 2: func(_ core.Agent, setBonusAura *core.Aura) { setBonusAura.AttachSpellMod(core.SpellModConfig{ ClassFlags: dreadnaughtRevenge.EffectN(1).ClassFlags, Kind: core.SpellMod_BaseDamage_Flat, FloatValue: dreadnaughtRevenge.EffectN(1).BaseValue(), }) }, 4: shared.ParsedSetBonus(dreadnaughtTauntHit), 6: shared.ParsedSetBonus(dreadnaughtAbilityHit), 8: func(agent core.Agent, setBonusAura *core.Aura) { character := agent.GetCharacter() cheatDeath := character.RegisterAura(spelldata.AuraConfig(dreadnaughtCheatDeathBuff)) spelldata.ParseEffects(character, cheatDeath, dreadnaughtCheatDeathBuff) trigger := spelldata.ProcTrigger(character, dreadnaughtCheatDeath, func(sim *core.Simulation, _ *core.Spell, _ *core.SpellResult) { cheatDeath.Activate(sim) }) trigger.Name = "Cheat Death - Trigger" trigger.ExtraCondition = func(sim *core.Simulation, _ *core.Spell, _ *core.SpellResult) bool { return character.CurrentHealthPercent() < 0.2 } setBonusAura.AttachProcTrigger(trigger) }, }, })
Tier 3
var SpellFlagsSweepingStrikes = spellData.SweepingStrikes.Highest().ClassFlags
The game files' SpellClassOptions for the Sweeping Strikes copy, a sim-only sub-spell that takes its parent's flags, the game files having no row for it.
var TalentTreeSizes = [3]int{17, 18, 18}
Functions ¶
This section is empty.
Types ¶
type Warrior ¶
type Warrior struct {
core.Character
ClassSpellScaling float64
Talents *proto.WarriorTalents
WarriorInputs
DemoralizingShout *core.Spell
BattleStance *core.Spell
DefensiveStance *core.Spell
BerserkerStance *core.Spell
Rend *core.Spell
DeepWounds *core.Spell
MortalStrike *core.Spell
SweepingStrikesNormalizedAttack *core.Spell
Cleave *core.Spell
MockingBlow *core.Spell
ChallengingShout *core.Spell
IntimidatingShout *core.Spell
Disarm *core.Spell
Taunt *core.Spell
VictoryRush *core.Spell
EnrageAura *core.Aura
GoreDrinkerAura *core.Aura
SweepingStrikesAura *core.Aura
OverpowerAura *core.Aura
DemoralizingShoutAuras core.AuraArray
SunderArmorAuras core.AuraArray
// contains filtered or unexported fields
}
func NewWarrior ¶
func NewWarrior(character *core.Character, options *proto.WarriorOptions, talents string, inputs WarriorInputs) *Warrior
func (*Warrior) AddPartyBuffs ¶
func (warrior *Warrior) AddPartyBuffs(_ *proto.PartyBuffs)
func (*Warrior) AddRaidBuffs ¶
func (*Warrior) ApplyTalents ¶
func (warrior *Warrior) ApplyTalents()
func (*Warrior) CastNormalizedSweepingStrikesAttack ¶
func (warrior *Warrior) CastNormalizedSweepingStrikesAttack(results core.SpellResultSlice, sim *core.Simulation)
Whirlwind's one strike a cast, against two targets or more.
func (*Warrior) GetCharacter ¶
func (*Warrior) GetMainHandType ¶
func (*Warrior) Initialize ¶
func (warrior *Warrior) Initialize()
func (*Warrior) OnEncounterStart ¶
func (warrior *Warrior) OnEncounterStart(sim *core.Simulation)
func (*Warrior) Reset ¶
func (warrior *Warrior) Reset(_ *core.Simulation)
func (*Warrior) TryHSOrCleave ¶
type WarriorAgent ¶
type WarriorAgent interface {
GetWarrior() *Warrior
}
Agent is a generic way to access underlying warrior on any of the agents.
type WarriorInputs ¶
Source Files
¶
- battle_shout.go
- berserker_rage.go
- bloodrage.go
- challenging_shout.go
- charge.go
- demoralizing_shout.go
- disarm.go
- execute.go
- hamstring.go
- heroic_strike_cleave.go
- intercept.go
- intimidating_shout.go
- item_armor.go
- item_weapons.go
- items.go
- mocking_blow.go
- overpower.go
- pummel.go
- recklessness.go
- rend.go
- retaliation.go
- revenge.go
- shield_bash.go
- shield_block.go
- shield_wall.go
- slam.go
- spell_data_auto_gen.go
- stances.go
- sunder_armor.go
- talents.go
- talents_arms.go
- talents_fury.go
- talents_protection.go
- taunt.go
- thunder_clap.go
- victory_rush.go
- warrior.go
- whirlwind.go