mage

package
v0.0.103 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MageSpellFlagNone      int64 = 0
	MageSpellArcaneBarrage int64 = 1 << iota
	MageSpellArcaneBlast
	MageSpellArcaneExplosion
	MageSpellArcanePower
	MageSpellArcaneMissilesCast
	MageSpellArcaneMissilesTick
	MageSpellBlastWave
	MageSpellBlizzard
	MageSpellConeOfCold
	MageSpellDeepFreeze
	MageSpellDragonsBreath
	MageSpellEvocation
	MageSpellFireBlast
	MageSpellFireball
	MageSpellFlamestrike
	MageSpellFlameOrb
	MageSpellFocusMagic
	MageSpellFreeze
	MageSpellFrostbolt
	MageSpellFrostfireBolt
	MageSpellFrostfireOrb
	MageSpellIceLance
	MageSpellIcyVeins
	MageSpellIgnite
	MageSpellLivingBombExplosion
	MageSpellLivingBombDot
	MageSpellManaGems
	MageSpellMirrorImage
	MageSpellPresenceOfMind
	MageSpellPyroblast
	MageSpellPyroblastDot
	MageSpellScorch
	MageSpellMoltenArmor
	MageSpellMageArmor
	MageSpellCombustion
	MageSpellCombustionApplication
	MageSpellLast
	MageSpellsAll        = MageSpellLast<<1 - 1
	MageSpellLivingBomb  = MageSpellLivingBombDot | MageSpellLivingBombExplosion
	MageSpellFireMastery = MageSpellLivingBombDot | MageSpellPyroblastDot | MageSpellCombustion // Ignite done manually in spell due to unique mechanic
	MageSpellFire        = MageSpellBlastWave | MageSpellCombustionApplication | MageSpellDragonsBreath | MageSpellFireball |
		MageSpellFireBlast | MageSpellFlameOrb | MageSpellFlamestrike | MageSpellFrostfireBolt | MageSpellIgnite |
		MageSpellLivingBomb | MageSpellPyroblast | MageSpellScorch
	MageSpellChill        = MageSpellFrostbolt | MageSpellFrostfireBolt
	MageSpellBrainFreeze  = MageSpellFireball | MageSpellFrostfireBolt
	MageSpellsAllDamaging = MageSpellArcaneBarrage | MageSpellArcaneBlast | MageSpellArcaneExplosion | MageSpellArcaneMissilesTick | MageSpellBlastWave | MageSpellBlizzard | MageSpellDeepFreeze |
		MageSpellDragonsBreath | MageSpellFireBlast | MageSpellFireball | MageSpellFlamestrike | MageSpellFlameOrb | MageSpellFrostbolt | MageSpellFrostfireBolt |
		MageSpellFrostfireOrb | MageSpellIceLance | MageSpellLivingBombExplosion | MageSpellLivingBombDot | MageSpellPyroblast | MageSpellPyroblastDot | MageSpellScorch
	MageSpellInstantCast = MageSpellArcaneBarrage | MageSpellArcaneMissilesCast | MageSpellArcaneMissilesTick | MageSpellFireBlast | MageSpellArcaneExplosion |
		MageSpellBlastWave | MageSpellCombustionApplication | MageSpellConeOfCold | MageSpellDeepFreeze | MageSpellDragonsBreath | MageSpellIceLance |
		MageSpellManaGems | MageSpellMirrorImage | MageSpellPresenceOfMind | MageSpellMoltenArmor | MageSpellMageArmor | MageSpellFlameOrb
	MageSpellExtraResult = MageSpellLivingBombExplosion | MageSpellArcaneMissilesTick | MageSpellBlizzard
)

Variables

View Source
var ItemSetFirehawkRobesOfConflagration = core.NewItemSet(core.ItemSet{
	Name: "Firehawk Robes of Conflagration",
	Bonuses: map[int32]core.ApplyEffect{

		2: func(agent core.Agent) {
			mage := agent.(MageAgent).GetMage()

			core.MakeProcTriggerAura(&mage.Unit, core.ProcTrigger{
				Name:           "Item - Mage T12 2P Bonus",
				Callback:       core.CallbackOnCastComplete,
				ClassSpellMask: MageSpellArcaneBlast | MageSpellFireball | MageSpellFrostfireBolt | MageSpellFrostbolt,
				ProcChance:     0.20,
				ICD:            time.Second * 45,
				Handler: func(sim *core.Simulation, spell *core.Spell, result *core.SpellResult) {
					mage.t12MirrorImage.EnableWithTimeout(sim, mage.t12MirrorImage, time.Second*15)
				},
			})
		},

		4: func(agent core.Agent) {
			mage := agent.(MageAgent).GetMage()

			core.MakePermanent(mage.RegisterAura(core.Aura{
				Label:    "Item - Mage T12 4P Bonus",
				ActionID: core.ActionID{SpellID: 99064},
				OnGain: func(aura *core.Aura, sim *core.Simulation) {
					mage.brainFreezeProcChance += .15
					mage.hotStreakProcChance += 0.30
				},
				OnExpire: func(aura *core.Aura, sim *core.Simulation) {
					mage.brainFreezeProcChance -= .15
					mage.hotStreakProcChance -= .30
				},
			}))

			mage.OnSpellRegistered(func(spell *core.Spell) {
				if spell.ClassSpellMask == MageSpellArcanePower {
					mage.arcanePowerCostMod.UpdateFloatValue(-0.1)
				}
			})
		},
	},
})

T12

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

			agent.GetCharacter().AddStaticMod(core.SpellModConfig{
				Kind:       core.SpellMod_BonusCrit_Percent,
				ClassMask:  MageSpellArcaneMissilesTick | MageSpellIceLance | MageSpellPyroblast | MageSpellPyroblastDot,
				FloatValue: 5,
			})
		},
		4: func(agent core.Agent) {

			agent.GetCharacter().AddStaticMod(core.SpellModConfig{
				Kind:       core.SpellMod_CastTime_Pct,
				ClassMask:  MageSpellArcaneBlast | MageSpellFireball | MageSpellFrostfireBolt | MageSpellFrostbolt,
				FloatValue: -0.1,
			})
		},
	},
})

T11

View Source
var ItemSetTimeLordsRegalia = core.NewItemSet(core.ItemSet{
	Name: "Time Lord's Regalia",
	Bonuses: map[int32]core.ApplyEffect{

		2: func(agent core.Agent) {
			character := agent.GetCharacter()
			mage := agent.(MageAgent).GetMage()

			mage.t13ProcAura = core.MakeStackingAura(character, core.StackingStatAura{
				Aura: core.Aura{
					Label:     "Stolen Time",
					ActionID:  core.ActionID{SpellID: 105785},
					Duration:  time.Second * 30,
					MaxStacks: 10,
				},
				BonusPerStack: stats.Stats{stats.HasteRating: 50},
			})

			newStolenTimeTrigger := func(procChance float64, spellMask int64) {
				core.MakeProcTriggerAura(&character.Unit, core.ProcTrigger{
					Name:           "Stolen Time Trigger",
					ActionID:       core.ActionID{ItemID: 105788},
					Callback:       core.CallbackOnSpellHitDealt,
					ClassSpellMask: spellMask,
					ProcChance:     procChance,
					Outcome:        core.OutcomeLanded,
					Handler: func(sim *core.Simulation, spell *core.Spell, result *core.SpellResult) {
						mage.t13ProcAura.Activate(sim)
						mage.t13ProcAura.AddStack(sim)
					},
				})
			}

			newStolenTimeTrigger(1, MageSpellArcaneBlast)
			newStolenTimeTrigger(0.5, MageSpellFireball|MageSpellPyroblast|MageSpellFrostfireBolt|MageSpellFrostbolt)
		},

		4: func(agent core.Agent) {

		},
	},
})

T13

View Source
var TalentTreeSizes = [3]int{21, 21, 19}

Functions

This section is empty.

Types

type FlameOrb

type FlameOrb struct {
	core.Pet

	FlameOrbTick *core.Spell

	TickCount int64
	// contains filtered or unexported fields
}

func (*FlameOrb) ExecuteCustomRotation

func (fo *FlameOrb) ExecuteCustomRotation(sim *core.Simulation)

func (*FlameOrb) GetPet

func (fo *FlameOrb) GetPet() *core.Pet

func (*FlameOrb) Initialize

func (fo *FlameOrb) Initialize()

func (*FlameOrb) Reset

func (fo *FlameOrb) Reset(_ *core.Simulation)

type FrostfireOrb

type FrostfireOrb struct {
	core.Pet

	FrostfireOrbTick *core.Spell

	FrostfireOrbFingerOfFrost *core.Aura

	TickCount int64
	// contains filtered or unexported fields
}

func (*FrostfireOrb) ExecuteCustomRotation

func (ffo *FrostfireOrb) ExecuteCustomRotation(sim *core.Simulation)

func (*FrostfireOrb) GetPet

func (ffo *FrostfireOrb) GetPet() *core.Pet

func (*FrostfireOrb) Initialize

func (ffo *FrostfireOrb) Initialize()

func (*FrostfireOrb) Reset

func (ffo *FrostfireOrb) Reset(_ *core.Simulation)

type Mage

type Mage struct {
	core.Character

	Talents       *proto.MageTalents
	Options       *proto.MageOptions
	ArcaneOptions *proto.ArcaneMage_Options
	FireOptions   *proto.FireMage_Options
	FrostOptions  *proto.FrostMage_Options

	Combustion           *core.Spell
	Ignite               *core.Spell
	LivingBomb           *core.Spell
	FireBlast            *core.Spell
	FlameOrbExplode      *core.Spell
	Flamestrike          *core.Spell
	FlamestrikeBW        *core.Spell
	FrostfireOrb         *core.Spell
	Pyroblast            *core.Spell
	SummonWaterElemental *core.Spell
	IcyVeins             *core.Spell

	FingersOfFrostAura *core.Aura

	ClassSpellScaling float64
	// contains filtered or unexported fields
}

func NewMage

func NewMage(character *core.Character, options *proto.Player, mageOptions *proto.MageOptions) *Mage

func (*Mage) AddPartyBuffs

func (mage *Mage) AddPartyBuffs(partyBuffs *proto.PartyBuffs)

func (*Mage) AddRaidBuffs

func (mage *Mage) AddRaidBuffs(raidBuffs *proto.RaidBuffs)

func (*Mage) ApplyArcaneTalents

func (mage *Mage) ApplyArcaneTalents()

func (*Mage) ApplyFireTalents

func (mage *Mage) ApplyFireTalents()

func (*Mage) ApplyFrostTalents

func (mage *Mage) ApplyFrostTalents()

func (*Mage) ApplyTalents

func (mage *Mage) ApplyTalents()

func (*Mage) GetCharacter

func (mage *Mage) GetCharacter() *core.Character

func (*Mage) GetMage

func (mage *Mage) GetMage() *Mage

func (*Mage) HasMajorGlyph

func (mage *Mage) HasMajorGlyph(glyph proto.MageMajorGlyph) bool

func (*Mage) HasMinorGlyph

func (mage *Mage) HasMinorGlyph(glyph proto.MageMinorGlyph) bool

func (*Mage) HasPrimeGlyph

func (mage *Mage) HasPrimeGlyph(glyph proto.MagePrimeGlyph) bool

func (*Mage) Initialize

func (mage *Mage) Initialize()

func (*Mage) NewFlameOrb

func (mage *Mage) NewFlameOrb() *FlameOrb

func (*Mage) NewFrostfireOrb

func (mage *Mage) NewFrostfireOrb() *FrostfireOrb

func (*Mage) NewMirrorImage

func (mage *Mage) NewMirrorImage() *MirrorImage

func (*Mage) NewT12MirrorImage added in v0.0.66

func (mage *Mage) NewT12MirrorImage() *T12MirrorImage

func (*Mage) OutcomeArcaneMissiles

func (mage *Mage) OutcomeArcaneMissiles(sim *core.Simulation, result *core.SpellResult, attackTable *core.AttackTable)

func (*Mage) Reset

func (mage *Mage) Reset(sim *core.Simulation)

type MageAgent

type MageAgent interface {
	GetMage() *Mage
}

Agent is a generic way to access underlying mage on any of the agents.

type MirrorImage

type MirrorImage struct {
	core.Pet

	Frostbolt   *core.Spell
	Fireblast   *core.Spell
	Fireball    *core.Spell
	ArcaneBlast *core.Spell

	Spec proto.Spec
	// contains filtered or unexported fields
}

func (*MirrorImage) ExecuteCustomRotation

func (mi *MirrorImage) ExecuteCustomRotation(sim *core.Simulation)

func (*MirrorImage) GetPet

func (mi *MirrorImage) GetPet() *core.Pet

func (*MirrorImage) Initialize

func (mi *MirrorImage) Initialize()

func (*MirrorImage) Reset

func (mi *MirrorImage) Reset(_ *core.Simulation)

type T12MirrorImage added in v0.0.66

type T12MirrorImage struct {
	core.Pet

	Fireball *core.Spell
	// contains filtered or unexported fields
}

func (*T12MirrorImage) ExecuteCustomRotation added in v0.0.66

func (mi *T12MirrorImage) ExecuteCustomRotation(sim *core.Simulation)

func (*T12MirrorImage) GetPet added in v0.0.66

func (mi *T12MirrorImage) GetPet() *core.Pet

func (*T12MirrorImage) Initialize added in v0.0.66

func (mi *T12MirrorImage) Initialize()

func (*T12MirrorImage) Reset added in v0.0.66

func (mi *T12MirrorImage) Reset(_ *core.Simulation)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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