druid

package
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Humanoid = 1 << iota
	Bear
	Cat
	Moonkin
)
View Source
const AnimalSpiritRegenSuppression = 0.911337

Converts from 0.009327 to 0.0085

View Source
const IdolAvenger int32 = 31025
View Source
const IdolSteadfastRenewal int32 = 40712
View Source
const IvoryMoongoddess int32 = 27518

Idol IDs

View Source
const ShootingStar int32 = 40321

Variables

View Source
var ItemSetDreamwalkerBattlegear = core.NewItemSet(core.ItemSet{
	Name: "Dreamwalker Battlegear",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})
View Source
var ItemSetDreamwalkerGarb = core.NewItemSet(core.ItemSet{
	Name: "Dreamwalker Garb",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})

T7 Balance

View Source
var ItemSetGladiatorsSanctuary = core.NewItemSet(core.ItemSet{
	Name: "Gladiator's Sanctuary",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {
			agent.GetCharacter().AddStat(stats.Resilience, 100)
			agent.GetCharacter().AddStat(stats.AttackPower, 50)
		},
		4: func(agent core.Agent) {
			agent.GetCharacter().AddStat(stats.AttackPower, 150)
		},
	},
})
View Source
var ItemSetGladiatorsWildhide = core.NewItemSet(core.ItemSet{
	Name: "Gladiator's Wildhide",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {
			druid := agent.(DruidAgent).GetDruid()
			druid.AddStat(stats.SpellPower, 29)
			druid.AddStat(stats.Resilience, 100)
		},
		4: func(agent core.Agent) {
			druid := agent.(DruidAgent).GetDruid()
			druid.AddStat(stats.SpellPower, 88)
			druid.SwiftStarfireAura = druid.RegisterAura(core.Aura{
				Label:    "Moonkin Starfire Bonus",
				ActionID: core.ActionID{SpellID: 46832},
				Duration: time.Second * 15,
			})

		},
	},
})
View Source
var ItemSetLasherweaveBattlegear = core.NewItemSet(core.ItemSet{
	Name: "Lasherweave Battlegear",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})
View Source
var ItemSetLasherweaveRegalia = core.NewItemSet(core.ItemSet{
	Name: "Lasherweave Regalia",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})

T10 Balance

View Source
var ItemSetMalfurionsBattlegear = core.NewItemSet(core.ItemSet{
	Name: "Malfurion's Battlegear",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})
View Source
var ItemSetMalfurionsRegalia = core.NewItemSet(core.ItemSet{
	Name: "Malfurion's Regalia",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})

T9 Balance Alliance

View Source
var ItemSetNightsongBattlegear = core.NewItemSet(core.ItemSet{
	Name: "Nightsong Battlegear",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {
			druid := agent.(DruidAgent).GetDruid()

			procChance := 0.02

			cca := druid.GetOrRegisterAura(core.Aura{
				Label:    "Clearcasting",
				ActionID: core.ActionID{SpellID: 16870},
				Duration: time.Second * 15,
			})

			icd := core.Cooldown{
				Timer:    druid.NewTimer(),
				Duration: time.Second * 15,
			}

			druid.RegisterAura(core.Aura{
				Label:    "Nightsong 4pc",
				Duration: core.NeverExpires,
				OnReset: func(aura *core.Aura, sim *core.Simulation) {
					aura.Activate(sim)
				},
				OnPeriodicDamageDealt: func(aura *core.Aura, sim *core.Simulation, spell *core.Spell, result *core.SpellResult) {
					isLacerate := druid.LacerateDot != nil && druid.LacerateDot.Spell == spell
					if spell != druid.Rake && spell != druid.Rip && !isLacerate {
						return
					}
					if !icd.IsReady(sim) {
						return
					}
					if sim.RandomFloat("Nightsong 4pc") < procChance {
						icd.Use(sim)
						cca.Activate(sim)
					}
				},
			})
		},
		4: func(agent core.Agent) {

		},
	},
})
View Source
var ItemSetNightsongGarb = core.NewItemSet(core.ItemSet{
	Name: "Nightsong Garb",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})

T8 Balance

View Source
var ItemSetRunetotemsBattlegear = core.NewItemSet(core.ItemSet{
	Name: "Runetotem's Battlegear",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})
View Source
var ItemSetRunetotemsRegalia = core.NewItemSet(core.ItemSet{
	Name: "Runetotem's Regalia",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})

T9 Balance Horde

View Source
var ItemSetThunderheartHarness = core.NewItemSet(core.ItemSet{
	Name: "Thunderheart Harness",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})
View Source
var ItemSetThunderheartRegalia = core.NewItemSet(core.ItemSet{
	Name: "Thunderheart Regalia",
	Bonuses: map[int32]core.ApplyEffect{
		2: func(agent core.Agent) {

		},
		4: func(agent core.Agent) {

		},
	},
})

Functions

This section is empty.

Types

type Druid

type Druid struct {
	core.Character
	SelfBuffs
	Talents *proto.DruidTalents

	StartingForm DruidForm

	RebirthUsed       bool
	MaulRageThreshold float64
	RebirthTiming     float64
	BleedsActive      int
	AssumeBleedActive bool

	Berserk          *core.Spell
	DemoralizingRoar *core.Spell
	Enrage           *core.Spell
	FaerieFire       *core.Spell
	FerociousBite    *core.Spell
	ForceOfNature    *core.Spell
	Hurricane        *core.Spell
	InsectSwarm      *core.Spell
	Lacerate         *core.Spell
	MangleBear       *core.Spell
	MangleCat        *core.Spell
	Maul             *core.Spell
	Moonfire         *core.Spell
	Rebirth          *core.Spell
	Rake             *core.Spell
	Rip              *core.Spell
	SavageRoar       *core.Spell
	Shred            *core.Spell
	Starfire         *core.Spell
	Starfall         *core.Spell
	StarfallSplash   *core.Spell
	SwipeBear        *core.Spell
	SwipeCat         *core.Spell
	TigersFury       *core.Spell
	Typhoon          *core.Spell
	Wrath            *core.Spell

	CatForm  *core.Spell
	BearForm *core.Spell

	InsectSwarmDot    *core.Dot
	LacerateDot       *core.Dot
	LasherweaveDot    *core.Dot
	MoonfireDot       *core.Dot
	RakeDot           *core.Dot
	RipDot            *core.Dot
	StarfallDot       *core.Dot
	StarfallDotSplash *core.Dot

	BearFormAura         *core.Aura
	BerserkAura          *core.Aura
	CatFormAura          *core.Aura
	ClearcastingAura     *core.Aura
	SwiftStarfireAura    *core.Aura
	DemoralizingRoarAura *core.Aura
	EnrageAura           *core.Aura
	FaerieFireAura       *core.Aura
	MangleAura           *core.Aura
	MaulQueueAura        *core.Aura
	NaturesGraceProcAura *core.Aura
	NaturesSwiftnessAura *core.Aura
	TigersFuryAura       *core.Aura
	SavageRoarAura       *core.Aura
	SolarEclipseProcAura *core.Aura
	LunarEclipseProcAura *core.Aura

	PrimalPrecisionRecoveryMetrics *core.ResourceMetrics

	LunarICD core.Cooldown
	SolarICD core.Cooldown
	Treant1  *TreantPet
	Treant2  *TreantPet
	Treant3  *TreantPet
	// contains filtered or unexported fields
}

func New

func New(char core.Character, form DruidForm, selfBuffs SelfBuffs, talents *proto.DruidTalents) *Druid

func (*Druid) AddRaidBuffs

func (druid *Druid) AddRaidBuffs(raidBuffs *proto.RaidBuffs)

func (*Druid) ApplyClearcasting

func (druid *Druid) ApplyClearcasting(sim *core.Simulation, _ *core.Spell, cast *core.Cast)

func (*Druid) ApplyTalents

func (druid *Druid) ApplyTalents()

func (*Druid) CanDemoralizingRoar

func (druid *Druid) CanDemoralizingRoar(_ *core.Simulation) bool

func (*Druid) CanFerociousBite

func (druid *Druid) CanFerociousBite() bool

func (*Druid) CanLacerate

func (druid *Druid) CanLacerate(sim *core.Simulation) bool

func (*Druid) CanMangleBear

func (druid *Druid) CanMangleBear(sim *core.Simulation) bool

func (*Druid) CanMangleCat

func (druid *Druid) CanMangleCat() bool

func (*Druid) CanRake

func (druid *Druid) CanRake() bool

func (*Druid) CanRip

func (druid *Druid) CanRip() bool

func (*Druid) CanSavageRoar

func (druid *Druid) CanSavageRoar() bool

func (*Druid) CanShred

func (druid *Druid) CanShred() bool

func (*Druid) CanSwipeBear

func (druid *Druid) CanSwipeBear() bool

func (*Druid) CanSwipeCat

func (druid *Druid) CanSwipeCat() bool

func (*Druid) ClearForm

func (druid *Druid) ClearForm(sim *core.Simulation)

func (*Druid) CurrentFerociousBiteCost

func (druid *Druid) CurrentFerociousBiteCost() float64

func (*Druid) CurrentMangleCatCost

func (druid *Druid) CurrentMangleCatCost() float64

func (*Druid) CurrentRakeCost

func (druid *Druid) CurrentRakeCost() float64

func (*Druid) CurrentRipCost

func (druid *Druid) CurrentRipCost() float64

func (*Druid) CurrentSavageRoarCost

func (druid *Druid) CurrentSavageRoarCost() float64

func (*Druid) CurrentShredCost

func (druid *Druid) CurrentShredCost() float64

func (*Druid) CurrentSwipeCatCost

func (druid *Druid) CurrentSwipeCatCost() float64

func (*Druid) DequeueMaul

func (druid *Druid) DequeueMaul(sim *core.Simulation)

func (*Druid) GetCharacter

func (druid *Druid) GetCharacter() *core.Character

func (*Druid) GetForm

func (druid *Druid) GetForm() DruidForm

func (*Druid) HasMajorGlyph

func (druid *Druid) HasMajorGlyph(glyph proto.DruidMajorGlyph) bool

func (*Druid) HasMinorGlyph

func (druid *Druid) HasMinorGlyph(glyph proto.DruidMinorGlyph) bool

func (*Druid) HasT9FeralSetBonus

func (druid *Druid) HasT9FeralSetBonus(num int32) bool

func (*Druid) InForm

func (druid *Druid) InForm(form DruidForm) bool

func (*Druid) Initialize

func (druid *Druid) Initialize()

func (*Druid) IsMangle

func (druid *Druid) IsMangle(spell *core.Spell) bool

func (*Druid) IsSwipeSpell

func (druid *Druid) IsSwipeSpell(spell *core.Spell) bool

func (*Druid) MaxRipTicks

func (druid *Druid) MaxRipTicks() int

func (*Druid) MeleeCritMultiplier

func (druid *Druid) MeleeCritMultiplier() float64

func (*Druid) NewTreant

func (druid *Druid) NewTreant() *TreantPet

func (*Druid) PowerShiftBear

func (druid *Druid) PowerShiftBear(sim *core.Simulation)

func (*Druid) PowerShiftCat

func (druid *Druid) PowerShiftCat(sim *core.Simulation) bool

func (*Druid) QueueMaul

func (druid *Druid) QueueMaul(sim *core.Simulation)

func (*Druid) RegisterBalanceSpells

func (druid *Druid) RegisterBalanceSpells()

func (*Druid) RegisterFeralSpells

func (druid *Druid) RegisterFeralSpells(maulRageThreshold float64)

func (*Druid) RegisterTalentsBonuses

func (druid *Druid) RegisterTalentsBonuses()

Registering non-unique Talent effects

func (*Druid) Reset

func (druid *Druid) Reset(_ *core.Simulation)

func (*Druid) ResetTalentsBonuses

func (druid *Druid) ResetTalentsBonuses()

func (*Druid) SavageRoarDurationTable added in v0.1.1

func (druid *Druid) SavageRoarDurationTable() [6]time.Duration

func (*Druid) ShouldDemoralizingRoar

func (druid *Druid) ShouldDemoralizingRoar(sim *core.Simulation, filler bool, maintainOnly bool) bool

func (*Druid) ShouldFaerieFire

func (druid *Druid) ShouldFaerieFire(sim *core.Simulation) bool

func (*Druid) ShouldQueueMaul

func (druid *Druid) ShouldQueueMaul(sim *core.Simulation) bool

func (*Druid) TryMaul

func (druid *Druid) TryMaul(sim *core.Simulation, mhSwingSpell *core.Spell) *core.Spell

Returns true if the regular melee swing should be used, false otherwise.

type DruidAgent

type DruidAgent interface {
	GetDruid() *Druid
}

Agent is a generic way to access underlying druid on any of the agents (for example balance druid.)

type DruidForm

type DruidForm uint8

func (DruidForm) Matches

func (form DruidForm) Matches(other DruidForm) bool

type SelfBuffs

type SelfBuffs struct {
	InnervateTarget *proto.RaidTarget
}

type TreantPet

type TreantPet struct {
	core.Pet
	// contains filtered or unexported fields
}

func (*TreantPet) GetPet

func (treant *TreantPet) GetPet() *core.Pet

func (*TreantPet) Initialize

func (treant *TreantPet) Initialize()

func (*TreantPet) OnGCDReady

func (treant *TreantPet) OnGCDReady(_ *core.Simulation)

func (*TreantPet) Reset

func (treant *TreantPet) Reset(_ *core.Simulation)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL