Documentation
¶
Index ¶
- Variables
- func AbsorbBreakDamage(absorb *spelldata.Spell) (int32, bool)
- func AbsorbLinkedDamage(absorb *spelldata.Spell) []int32
- func AttachSpellDamageVersus(aura *core.Aura, row *spelldata.Spell) *core.Aura
- func AuraDurationUnsupported(e *spelldata.Effect) []string
- func CarriedProcUnsupported(row *spelldata.Spell) []string
- func ConsumableDamages(row *spelldata.Spell) bool
- func ConsumableRestores(row *spelldata.Spell) (power, survival bool)
- func ConsumableSpells(row *spelldata.Spell) []*spelldata.Spell
- func ConsumableUnsupported(row *spelldata.Spell) []string
- func DamageCloudOf(row *spelldata.Spell) (cloud, damage *spelldata.Spell)
- func DamageConsumableUnsupported(s *spelldata.Spell) []string
- func EnemyDebuffAuras(character *core.Character, row *spelldata.Spell, duration time.Duration, ...) core.AuraArray
- func EnergizesABar(power dbcenums.PowerType) bool
- func FiredSpellHandler(character *core.Character, actionID core.ActionID, row *spelldata.Spell) core.ProcHandler
- func FiredSpellUnsupported(row *spelldata.Spell) []string
- func GainLeechHealth(sim *core.Simulation, character *core.Character, dealt float64, ...)
- func Generated() func()
- func GetOutcome(spell *core.Spell, outcome OutcomeType) core.OutcomeApplier
- func GrantsCrit(row *spelldata.Spell) bool
- func IsSetBonusProc(row *spelldata.Spell) bool
- func LandsOnTheUser(e *spelldata.Effect) bool
- func NewGuardianOnUse(itemID int32, summonID int32, creatures map[int32]GuardianCreature)
- func NewParsedItemSet(id int32, name string, slots []proto.ItemSlot, bonuses map[int32][]int32)
- func NewParsedProfessionItemSet(id int32, name string, profession proto.Profession, slots []proto.ItemSlot, ...)
- func NewProcDamageEffect(config ProcDamageEffect)
- func NewProcStatBonusEffect(config ProcStatBonusEffect)
- func NewProcStatBonusEffectWithDamageProc(config ProcStatBonusEffect, damage DamageEffect)
- func NewProcStatBonusEffectWithVariants(config ProcStatBonusEffect, variants []ItemVariant)
- func NewSimpleStatActive(itemID int32)
- func NewSpellDataAbsorbOnUse(itemID int32)
- func NewSpellDataAbsorbProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataAuraOnUse(itemID int32)
- func NewSpellDataAuraProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataDamageOnUse(itemID int32)
- func NewSpellDataDamageProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataDebuffProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataEnergizeOnUse(itemID int32)
- func NewSpellDataEnergizeProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataEquipAura(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataExplosive(itemID int32)
- func NewSpellDataExtraAttackProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataHealOnUse(itemID int32)
- func NewSpellDataHealProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataOnUseConsumable(itemID int32)
- func NewSpellDataPeriodicDamageOnUse(itemID int32)
- func NewSpellDataProc(cfg SpellDataProc, variants []ItemVariant)
- func NewSpellDataSpeedOnUse(itemID int32)
- func NewSpellDataStatConsumable(itemID int32)
- func NewSpellDataTemporaryEnchant(itemID int32, piercing SchoolPiercing, equipSpellIDs ...int32)
- func NewStackingStatBonusCD(config StackingStatBonusCD)
- func NewStackingStatBonusEffectWithVariants(config ProcStatBonusEffect, variants []ItemVariant)
- func OnUseCast(character *core.Character, itemEffect *proto.ItemEffect) core.CastConfig
- func OneAtATimeCategory(itemEffect *proto.ItemEffect) int32
- func OnlyAgainst(targets core.VersusTargets) spelldata.ProcOpt
- func ParsedSetBonus(rows ...*spelldata.Spell) core.ApplySetBonus
- func RegisterItemGuardian(itemID int32, summon *spelldata.Spell, creature GuardianCreature)
- func RegisterShoot(character *core.Character)
- func RegisterVersus(character *core.Character, source core.ActionID, kind proto.VersusEffectKind, ...) *core.VersusBonus
- func RollCastTimePPM(sim *core.Simulation, character *core.Character, row *spelldata.Spell, ...) bool
- func SetBonusUnsupported(row *spelldata.Spell) []string
- func SpellCastPPMTrigger(character *core.Character, row *spelldata.Spell, handler core.ProcHandler) core.ProcTrigger
- func SpendsItsCharges(row *spelldata.Spell) bool
- func StatConsumableUnsupported(row *spelldata.Spell) []string
- func SummonGuardians(sim *core.Simulation, guardians []*Guardian, target *core.Unit)
- func TemporaryEnchantEquipSpellProcs(row *spelldata.Spell) bool
- func WearerAuraTriggers(row *spelldata.Spell) []*spelldata.Effect
- type CustomProcHandler
- type DamageEffect
- type ExtraSpellInfo
- type Guardian
- func (guardian *Guardian) CreatureStats() core.CreatureStats
- func (guardian *Guardian) ExecuteCustomRotation(sim *core.Simulation)
- func (guardian *Guardian) GetPet() *core.Pet
- func (guardian *Guardian) Initialize()
- func (guardian *Guardian) OnEncounterStart(_ *core.Simulation)
- func (guardian *Guardian) Reset(_ *core.Simulation)
- type GuardianCast
- type GuardianCreature
- type GuardianGlance
- type GuardianSwing
- type ItemVariant
- type OutcomeType
- type ProcDamageEffect
- type ProcStatBonusEffect
- type SchoolPiercing
- type SpellDataProc
- type StackingStatBonusCD
Constants ¶
This section is empty.
Variables ¶
var DamageProcExtras = map[int32]func(character *core.Character, config *core.SpellConfig){}
What an item adds to the spell its NewSpellDataDamageProc proc casts where the spells leave it to a script, by item id, given the spell's config before it registers: Pendulum of Doom's execute bonus. Hand-written code fills it from init, so the item's effect stays generated.
var EightPieceSlots = []proto.ItemSlot{ proto.ItemSlot_ItemSlotHead, proto.ItemSlot_ItemSlotShoulder, proto.ItemSlot_ItemSlotChest, proto.ItemSlot_ItemSlotWrist, proto.ItemSlot_ItemSlotHands, proto.ItemSlot_ItemSlotWaist, proto.ItemSlot_ItemSlotLegs, proto.ItemSlot_ItemSlotFeet, }
The eight armor slots of a crafted or dungeon set.
var EnchantProcTriggerExtras = map[int32]func(character *core.Character, trigger *core.ProcTrigger){}
The same for an enchant's generated proc, by enchant id, given the wearer: Insight rolls once per cast.
var ProcBuffDurationExtras = map[int32]time.Duration{}
How much longer than its spells state the buff of an item's generated proc lasts, by item id: Felstriker's buff counts its 3 s from the spell batch its proc would land in.
var ProcTriggerExtras = map[int32]func(trigger *core.ProcTrigger){}
What an item changes on the listener its generated proc builds, by item id, before the handler is set: Felstriker's buff goes up in the instant of the hit that procs it. Hand-written code fills it from init, so the item's effect stays generated.
var TierThreeSlots = slices.Concat(EightPieceSlots, []proto.ItemSlot{proto.ItemSlot_ItemSlotFinger1, proto.ItemSlot_ItemSlotFinger2})
A Naxxramas tier 3 set: the eight armor pieces and the ring, all worn only by the set's class.
Functions ¶
func AbsorbBreakDamage ¶
The spell dealing the damage the absorb's shield deals when it breaks early, where one is listed.
func AbsorbLinkedDamage ¶
The spells dealing damage that an absorb triggers or its tooltip references. The shield deals only the one AbsorbBreakDamage names; any other is damage the absorb shape does not model.
func AttachSpellDamageVersus ¶ added in v1.0.15
The spell damage the spell's A_MOD_DAMAGE_DONE_CREATURE effect grants against the mob types its mask names while the aura is up, credited to the spell. The parse table reads this aura on an item, a consumable or a set bonus as physical and spell damage. A class set bonus that raises "damage done by your spells and effects" against a creature type grants spell damage alone, and registers through this helper.
func AuraDurationUnsupported ¶
Why the aura of the effect cannot be put up: its spell states no duration.
func CarriedProcUnsupported ¶
Why the proc a stat buff carries cannot be built, or nil where it can.
func ConsumableDamages ¶
Whether a consumable's spell deals damage to enemies: a hit or a damage over time of its own, or a cloud's.
func ConsumableRestores ¶
Whether the parts of a consumable's spell the builder models restore power, and whether they heal or absorb.
func ConsumableSpells ¶
The consumable's on-use spell and each spell it triggers on the user. A periodic trigger with a value hands its amount to every effect of the spell it triggers.
func ConsumableUnsupported ¶
Why the consumable builders cannot run the spell, or nil where they can.
func DamageCloudOf ¶
The cloud a consumable's missile leaves where it lands, and the damage over time the cloud puts on the enemies inside it (Caustic Smog Potion's 1252525 fires 1252526, which puts 1252543 on the enemies).
func DamageConsumableUnsupported ¶
Why the damage builders cannot run the spell, or nil where they can.
func EnemyDebuffAuras ¶
func EnemyDebuffAuras(character *core.Character, row *spelldata.Spell, duration time.Duration, effects []int32) core.AuraArray
The spell's debuff on each enemy, carrying the effects at the given positions. The aura is the spell's, so every character applying the spell refreshes one debuff on the target, and the first to register it parses it. A spell a raid debuff reads is that debuff's player copy instead, or is the raid's copy where the raid's driver makes it the player's own.
func EnergizesABar ¶
Whether the power type is one of the bars a gain fills: mana, rage or energy.
func FiredSpellHandler ¶
func FiredSpellHandler(character *core.Character, actionID core.ActionID, row *spelldata.Spell) core.ProcHandler
What the spell a proc fires does, or nil where the wearer has no bar its gain fills. A cooldown change moves the whole category's timer, which is where a spell whose only recovery is its category's keeps its cooldown; the game files state a reduction as a negative time, Spark's 1306610 -100000.
func FiredSpellUnsupported ¶
Why the spell a proc fires cannot be built, or nil where it can: the proc's spell states no effect beside its trigger, and the spell it fires (FiredSpell) puts mana, rage or energy into the wearer's bar at once or changes the cooldown of one of the wearer's spell categories.
func GainLeechHealth ¶
func GainLeechHealth(sim *core.Simulation, character *core.Character, dealt float64, leech *spelldata.Effect, healthMetrics *core.ResourceMetrics)
Health for the damage a leech dealt, an E_HEALTH_LEECH's or an A_PERIODIC_LEECH's: its Amplitude share, times the caster's healing taken multiplier.
func Generated ¶
func Generated() func()
Marks the registrations that run until the returned function is called as the generated files'. A class file's call to the same constructor is a hand-written effect: it registers with core on its own.
func GetOutcome ¶
func GetOutcome(spell *core.Spell, outcome OutcomeType) core.OutcomeApplier
func GrantsCrit ¶ added in v1.0.4
Whether the consumable's spells put a crit chance on the user.
func IsSetBonusProc ¶
A spell whose one effect triggers another spell off its own proc flags.
func LandsOnTheUser ¶
The user, or the one friendly unit the spell is cast on, which in the sim is the user: a scroll states the latter.
func NewGuardianOnUse ¶ added in v1.0.6
func NewGuardianOnUse(itemID int32, summonID int32, creatures map[int32]GuardianCreature)
A use item whose spell summons a guardian. The item keeps only its stats until the creature is measured.
func NewParsedItemSet ¶
A set gen_db registers from the game files, each piece count's bonus parsed from its spells. A set written by hand under the same id keeps it off.
func NewParsedProfessionItemSet ¶
func NewParsedProfessionItemSet(id int32, name string, profession proto.Profession, slots []proto.ItemSlot, bonuses map[int32][]int32)
A generated set whose ItemSet row gates the bonuses on a profession (RequiredSkill).
func NewProcDamageEffect ¶
func NewProcDamageEffect(config ProcDamageEffect)
func NewProcStatBonusEffect ¶
func NewProcStatBonusEffect(config ProcStatBonusEffect)
func NewProcStatBonusEffectWithDamageProc ¶
func NewProcStatBonusEffectWithDamageProc(config ProcStatBonusEffect, damage DamageEffect)
func NewProcStatBonusEffectWithVariants ¶
func NewProcStatBonusEffectWithVariants(config ProcStatBonusEffect, variants []ItemVariant)
func NewSimpleStatActive ¶
func NewSimpleStatActive(itemID int32)
func NewSpellDataAbsorbOnUse ¶
func NewSpellDataAbsorbOnUse(itemID int32)
An on-use item whose spell shields the wearer with an A_SCHOOL_ABSORB aura. The stats beside the absorb go with the shield (EV-0100).
func NewSpellDataAbsorbProc ¶
func NewSpellDataAbsorbProc(cfg SpellDataProc, variants []ItemVariant)
An item or enchant proc whose spell shields the wearer with an A_SCHOOL_ABSORB aura. BuffSpellID names that spell.
func NewSpellDataAuraOnUse ¶
func NewSpellDataAuraOnUse(itemID int32)
An on-use item whose spell applies auras: the wearer's buff, its pets' and the debuff on the enemy it is used on, for the spell's duration. One that lowers the wearer's threat is never used on its own: the sim gains nothing from less threat and a tank loses by it.
func NewSpellDataAuraProc ¶
func NewSpellDataAuraProc(cfg SpellDataProc, variants []ItemVariant)
An item or enchant proc whose buff applies auras: the wearer's, its pets' and the debuff on the unit the proc answers, for the buff's duration.
func NewSpellDataDamageOnUse ¶
func NewSpellDataDamageOnUse(itemID int32)
An on-use item whose spell deals damage to its target: the direct damage its spell rolls, the damage over time it applies, or both.
func NewSpellDataDamageProc ¶
func NewSpellDataDamageProc(cfg SpellDataProc, variants []ItemVariant)
An item or enchant proc whose "buff" is a damage spell: the game files apply no aura at all, it casts a spell that deals damage. BuffSpellID names that spell.
func NewSpellDataDebuffProc ¶
func NewSpellDataDebuffProc(cfg SpellDataProc, variants []ItemVariant)
An item or enchant proc whose spell puts a debuff on the enemy it lands on and does nothing else the sim models. BuffSpellID names the spell where it is not the trigger.
func NewSpellDataEnergizeOnUse ¶
func NewSpellDataEnergizeOnUse(itemID int32)
An on-use item whose spell restores the wearer's mana, rage or energy, at once or over time. Each aura the spell triggers on the wearer goes up with the gain. The cooldown manager uses it once the whole gain fits under the bar's maximum.
func NewSpellDataEnergizeProc ¶
func NewSpellDataEnergizeProc(cfg SpellDataProc, variants []ItemVariant)
An item or enchant proc whose trigger fires a spell that restores the wearer's mana, rage or energy, read off the trigger alone the way FiredSpellUnsupported reads it.
func NewSpellDataEquipAura ¶
func NewSpellDataEquipAura(cfg SpellDataProc, variants []ItemVariant)
An item or enchant whose equip spell applies auras: the spell's auras on the wearer and on each summoned pet for as long as the item or the enchant is worn. An equip spell that only re-applies another aura on a period is read as that aura. The generator emits no equip spell that states spell modifiers: each class registers its own through this constructor.
func NewSpellDataExplosive ¶
func NewSpellDataExplosive(itemID int32)
An explosive used from the bar: the damage its on-use spell deals, on the item's cooldown and the category cooldown every explosive shares.
Throwing one leaves the melee swing timer running (EV-0088). A bomb or grenade whose spell's mechanic is stun is a stun as a whole: a stun-immune target is immune to its damage too.
func NewSpellDataExtraAttackProc ¶
func NewSpellDataExtraAttackProc(cfg SpellDataProc, variants []ItemVariant)
An item proc whose spell grants the wearer extra attacks. Each is a main-hand swing tagged with the granting spell, so the metrics tell it from the swing that procced it.
func NewSpellDataHealOnUse ¶
func NewSpellDataHealOnUse(itemID int32)
An on-use item whose spell heals the wearer, at once or over time, and with the heal restores the resource its spell's energize effect states: Major Recombobulator's 23064 restores mana too.
func NewSpellDataHealProc ¶
func NewSpellDataHealProc(cfg SpellDataProc, variants []ItemVariant)
An item or enchant proc whose "buff" heals the wearer: it casts an E_HEAL_PCT or E_HEAL spell, or one applying an A_PERIODIC_HEAL aura to the wearer. BuffSpellID names that spell.
func NewSpellDataOnUseConsumable ¶
func NewSpellDataOnUseConsumable(itemID int32)
A consumable whose on-use spell the potion builder runs on the user, or whose damage it deals to enemies, on the item's cooldown and the category it shares. A potion is a major cooldown only while the consumes pick it for an APL potion placeholder, the other potions are the rotation's; a conjured item is one only while it is the spec's chosen one; any other is one whenever the spec names it.
func NewSpellDataPeriodicDamageOnUse ¶
func NewSpellDataPeriodicDamageOnUse(itemID int32)
An on-use item whose spell keeps an A_PERIODIC_TRIGGER_SPELL aura on the wearer, which casts the spell it triggers every period. The label carries the item, since two items may apply the same spell.
func NewSpellDataProc ¶
func NewSpellDataProc(cfg SpellDataProc, variants []ItemVariant)
Registers the same effect once per item that carries it, the way the stat-bonus constructors do it.
func NewSpellDataSpeedOnUse ¶
func NewSpellDataSpeedOnUse(itemID int32)
An on-use item whose spell raises the wearer's melee, ranged or cast speed. Every speed the spell states is on one aura, up for the spell's duration.
func NewSpellDataStatConsumable ¶
func NewSpellDataStatConsumable(itemID int32)
A consumable whose on-use spell puts auras on the user that the parser attaches: an elixir, a flask, a scroll, food's Well Fed. A scroll's stats count with the elixirs' (R-0054).
func NewSpellDataTemporaryEnchant ¶
func NewSpellDataTemporaryEnchant(itemID int32, piercing SchoolPiercing, equipSpellIDs ...int32)
A temporary enchant consumable. Its stats, speed percents and flat weapon damage are core's, on the item carrying the enchant. The equip spells named are the enchant's that grant no stat of the enchant's own: their auras are parsed onto an aura per hand, since each weapon carries its own copy of the equip aura, and one that procs is a listener of its own. The piercing is a stat slot of the enchant that has no place in the stat array.
func NewStackingStatBonusCD ¶
func NewStackingStatBonusCD(config StackingStatBonusCD)
A stacking stats bonus aura, its values read from the item's effects.
func NewStackingStatBonusEffectWithVariants ¶
func NewStackingStatBonusEffectWithVariants(config ProcStatBonusEffect, variants []ItemVariant)
func OnUseCast ¶
func OnUseCast(character *core.Character, itemEffect *proto.ItemEffect) core.CastConfig
The item effect's own cooldown and the category cooldown it shares, whatever the spell states.
func OneAtATimeCategory ¶
func OneAtATimeCategory(itemEffect *proto.ItemEffect) int32
The category a stat consumable is used one at a time with the others of, or 0: one whose cooldown lasts as long as each of the consumable's buffs, which are up from the pull.
func OnlyAgainst ¶ added in v1.0.15
func OnlyAgainst(targets core.VersusTargets) spelldata.ProcOpt
Narrows a proc to hits on the targets, before any condition it already has.
func ParsedSetBonus ¶
func ParsedSetBonus(rows ...*spelldata.Spell) core.ApplySetBonus
A bonus whose spells the parse states whole. A spell's modifiers name its class's spells by class flags, so on another class they reach nothing.
func RegisterItemGuardian ¶ added in v1.0.6
func RegisterItemGuardian(itemID int32, summon *spelldata.Spell, creature GuardianCreature)
Builds the guardians an item summons with the item's owner: as many as the summon brings at once. Where more can be up than one summon brings, each piece carrying one registers its own under its own name.
func RegisterShoot ¶
Shoot is a channel during which the wand fires one shot per wand speed, until something takes a shot's slot. A shot rolls the wand's damage in its school: no attack power, no spell power. It misses on the ranged weapon table, which wand skill sets and physical and ranged hit lower. It has no dodge, parry or block, and crits on the caster's spell crit, for 1.5 times like a spell.
func RegisterVersus ¶ added in v1.0.15
func RegisterVersus(character *core.Character, source core.ActionID, kind proto.VersusEffectKind, row *spelldata.Spell) *core.VersusBonus
The factor the spell deals or restores against its targets, kept for the source on the stats sheet, or nil where the spell states none.
func RollCastTimePPM ¶
func RollCastTimePPM(sim *core.Simulation, character *core.Character, row *spelldata.Spell, flags core.ClassFlags, castTime time.Duration) bool
Whether a cast that took castTime procs the spell's procs per minute: the rate on that time, at least the global cooldown's 1.5 s. The character's proc chance mods for flags raise it.
func SetBonusUnsupported ¶
Why a generated set cannot register the spell, or nil where it can. A proc spell of a class family whose proc effect names none of the family's spells is refused: the spells its tooltip names are missing from that effect's class flags, so its listener would hear every spell (Symbols of Unending Life's 26107 refunds on finishing moves that miss).
func SpellCastPPMTrigger ¶
func SpellCastPPMTrigger(character *core.Character, row *spelldata.Spell, handler core.ProcHandler) core.ProcTrigger
A listener for the spell's procs per minute on spell casts. A cast of a damaging or healing spell rolls once, and so does any other cast whose spell costs mana. Any other cast never rolls (EV-0144). The chance depends on the cast, so Chance(1) leaves core no roll of its own and the condition draws it.
func SpendsItsCharges ¶
Whether a buff on the wearer drops after its ProcCharges are used, and its spell names the hits that use them. A spell stating more than one stack as well is read as a stacking one, whose charges the aura cannot keep apart from its stacks.
func StatConsumableUnsupported ¶
Why the stat builder cannot put up the auras of the consumable's spells, or nil where it can.
func SummonGuardians ¶ added in v1.0.6
func SummonGuardians(sim *core.Simulation, guardians []*Guardian, target *core.Unit)
Puts up as many guardians as the summon brings against the target for the spell's duration. A summon takes the guardians that are not up first, then the first ones.
Types ¶
type CustomProcHandler ¶
type CustomProcHandler func(sim *core.Simulation, procAura *core.StatBuffAura)
type DamageEffect ¶
type DamageEffect struct {
SpellID int32
School core.SpellSchool
DefenseType core.DefenseType // From SpellCategories. Left unset, it is inferred from School and IsMelee.
MinDmg float64
MaxDmg float64
BonusCoefficient float64
IsMelee bool
ProcMask core.ProcMask
Outcome OutcomeType
Flags core.SpellFlag
// Set when the game files bar the damage spell from critting, which the sim has no way to know:
// it is a spell attribute, so only the database generator can see it.
CannotCrit bool
}
type ExtraSpellInfo ¶
type ExtraSpellInfo struct {
Spell *core.Spell
Trigger func(sim *core.Simulation, spell *core.Spell, result *core.SpellResult)
}
type Guardian ¶ added in v1.0.6
func Guardians ¶ added in v1.0.6
The guardians the character owns for a summon, in the order it built them.
func (*Guardian) CreatureStats ¶ added in v1.0.10
func (guardian *Guardian) CreatureStats() core.CreatureStats
The creature numbers for the guardian's level, which its spells scale with.
func (*Guardian) ExecuteCustomRotation ¶ added in v1.0.6
func (guardian *Guardian) ExecuteCustomRotation(sim *core.Simulation)
A guardian casts only standing within its range (R-0055). One with no spell only swings, so its rotation sleeps for as long as it can be up once it stands in melee range.
func (*Guardian) Initialize ¶ added in v1.0.6
func (guardian *Guardian) Initialize()
func (*Guardian) OnEncounterStart ¶ added in v1.0.6
func (guardian *Guardian) OnEncounterStart(_ *core.Simulation)
func (*Guardian) Reset ¶ added in v1.0.6
func (guardian *Guardian) Reset(_ *core.Simulation)
type GuardianCast ¶ added in v1.0.6
type GuardianCast struct {
FirstMax time.Duration
WaitMin, WaitMax time.Duration
FirstLabel, WaitLabel string
Config func(guardian *Guardian) core.SpellConfig
}
A spell the guardian casts on its target: the first within FirstMax of the summon, each next one a uniform wait of WaitMin to WaitMax after the last one's cast end. A hardcast holds the swing. The wait is drawn as the cast ends, before the cast's own rolls, and a cast that fails to start waits a fresh draw from then.
type GuardianCreature ¶ added in v1.0.6
type GuardianCreature struct {
Name string // The pet's name; with more than one up at once, numbered.
Level int32 // The creature's own level when it does not take its owner's; 0 takes the owner's.
Health float64 // Share of the creature health.
Armor float64 // Share of the creature armor.
Swing GuardianSwing // A zero Speed: the guardian never swings.
Cast *GuardianCast // The one spell the guardian casts between swings, or nil.
}
A creature an item or a set bonus summons as a guardian, as the logs measure it. The game files hold no creature row, only the summon's, so the creature's health, armor, swing and spells are stated as shares of the creature numbers for its level.
type GuardianGlance ¶ added in v1.0.10
Glancing blows that follow the target's level: a chance of 2% for each point of defense, 5 a level, the target has over Skill, and a glancing blow's share of a hit drawn uniformly from the range Damage gives for the target's level.
type GuardianSwing ¶ added in v1.0.6
type GuardianSwing struct {
Speed float64
Variance float64
Glance *GuardianGlance // Glancing blows as the logs read them, in place of the attack table's; nil keeps the table's.
}
A physical swing whose normal hit before armor is Share of Speed seconds of the creature dps, Variance either side.
type ItemVariant ¶
type OutcomeType ¶
type OutcomeType uint64
const ( OutcomeDefault = 0 OutcomeMeleeCanCrit OutcomeType = iota OutcomeMeleeNoCrit OutcomeSpellCanCrit OutcomeSpellNoCrit OutcomeSpellNoMissCanCrit OutcomeRangedCanCrit OutcomeRangedNoCrit OutcomeAlwaysHit )
type ProcDamageEffect ¶
type ProcDamageEffect struct {
ItemID int32
SpellID int32
EnchantID int32
Trigger core.ProcTrigger
TriggerDPM func(*core.Character) *core.DynamicProcManager
School core.SpellSchool
// From SpellCategories. Left unset, it is inferred from School and IsMelee.
DefenseType core.DefenseType
MinDmg float64
MaxDmg float64
BonusCoefficient float64
IsMelee bool
Flags core.SpellFlag
Outcome OutcomeType
// Set when the game files bar the damage spell from critting, which the sim has no way to know:
// it is a spell attribute, so only the database generator can see it.
CannotCrit bool
}
type ProcStatBonusEffect ¶
type ProcStatBonusEffect struct {
Name string
ItemID int32
EnchantID int32
MaxStacks int32
Callback core.AuraCallback
ProcMask core.ProcMask
Outcome core.HitOutcome
RequireDamageDealt bool
ClassSpellsOnly bool
// See core.ProcTrigger.
RequireDamageComponent bool
// The listener's Can Proc From Procs attribute. See core.ProcTrigger.
CanProcFromProcs bool
// A "Chance on hit" item effect or a combat enchant (core.ProcTrigger); the generator reads it
// from the trigger type.
IsWeaponProc bool
// The generator sets SpellFlagSuppressWeaponProcs here when the listener's aura is marked Aura Is
// Weapon Proc.
SpellFlagsExclude core.SpellFlag
// What adds a stack while a stacking trinket's window is open: the container spell's own proc
// flags, which are not the ones that open the window.
StackCallback core.AuraCallback
StackProcMask core.ProcMask
StackOutcome core.HitOutcome
// Any other custom proc conditions not covered by the above fields.
CustomProcCondition core.CustomStatBuffProcCondition
}
type SchoolPiercing ¶
type SchoolPiercing struct {
School stats.SchoolIndex
Amount float64
}
Target resistance a temporary enchant ignores on one school's spells.
type SpellDataProc ¶
type SpellDataProc struct {
// Filled per variant by NewSpellDataProc. An enchant, which has no variants, states its own.
Name string
ItemID int32
// Set for an enchant, which registers through the enchant registry rather than the item one.
EnchantID int32
// The spell the item effect names: the one carrying the proc flags, the chance and the ICD.
TriggerSpellID int32
// The buff the proc applies, where the game files make it a spell of its own. Zero where the
// trigger itself is the buff.
BuffSpellID int32
// A "Chance on hit" item effect or a combat enchant. The game casts those off the hit itself
// without consulting a proc mask, so the game files state no listener and the shape is stated here.
IsWeaponProc bool
// A rate option in place of the one the item's entry and the trigger give, for a rate priced on
// something neither states. It may reshape the listener.
Rate spelldata.ProcOpt
}
An item or enchant proc as the game files state it: the listener, rate and ICD from the spell carrying the proc, the buff's duration and stacks from the spell it applies, and only the stats from the item's effect entry, where the sim's item level scaling lives.
type StackingStatBonusCD ¶
type StackingStatBonusCD struct {
Name string
ID int32
CD time.Duration
Callback core.AuraCallback
ProcMask core.ProcMask
SpellFlags core.SpellFlag
Outcome core.HitOutcome
RequireDamageDealt bool
// See core.ProcTrigger.
RequireDamageComponent bool
// See core.ProcTrigger. The generator reads them off the stack proc's aura, which is always an
// Equip aura, so there is no weapon-proc counterpart here.
CanProcFromProcs bool
SpellFlagsExclude core.SpellFlag
// The stacks will only be granted as long as the trinket is active
TrinketLimitsDuration bool
}