shared

package
v0.0.250 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetOutcome

func GetOutcome(spell *core.Spell, outcome OutcomeType) core.OutcomeApplier

func NewProcDamageEffect

func NewProcDamageEffect(config ProcDamageEffect)

func NewProcStatBonusEffect

func NewProcStatBonusEffect(config ProcStatBonusEffect)

func NewProcStatBonusEffectWithDamageProc

func NewProcStatBonusEffectWithDamageProc(config ProcStatBonusEffect, damage DamageEffect)

func NewSimpleStatActive added in v0.0.241

func NewSimpleStatActive(itemID int32)

func NewStackingStatBonusCD

func NewStackingStatBonusCD(config StackingStatBonusCD)

func NewStackingStatBonusEffect

func NewStackingStatBonusEffect(config StackingStatBonusEffect)

Types

type CustomProcHandler

type CustomProcHandler func(sim *core.Simulation, procAura *core.StatBuffAura)

type DamageEffect

type DamageEffect struct {
	SpellID          int32
	School           core.SpellSchool
	MinDmg           float64
	MaxDmg           float64
	BonusCoefficient float64
	IsMelee          bool
	ProcMask         core.ProcMask
	Outcome          OutcomeType
}

type ExtraSpellInfo

type ExtraSpellInfo struct {
	Spell   *core.Spell
	Trigger func(sim *core.Simulation, spell *core.Spell, result *core.SpellResult)
}

type OutcomeType

type OutcomeType uint64
const (
	OutcomeDefault                  = 0
	OutcomeMeleeCanCrit OutcomeType = iota
	OutcomeMeleeNoCrit
	OutcomeMeleeNoBlockDodgeParryCrit
	OutcomeSpellCanCrit
	OutcomeSpellNoCrit
	OutcomeSpellNoMissCanCrit
	OutcomeRangedCanCrit
)

type ProcDamageEffect

type ProcDamageEffect struct {
	ItemID    int32
	SpellID   int32
	EnchantID int32
	Trigger   core.ProcTrigger

	School  core.SpellSchool
	MinDmg  float64
	MaxDmg  float64
	IsMelee bool
	Flags   core.SpellFlag
	Outcome OutcomeType
}

type ProcStatBonusEffect

type ProcStatBonusEffect struct {
	Name      string
	ItemID    int32
	EnchantID int32
	Callback  core.AuraCallback
	ProcMask  core.ProcMask
	Outcome   core.HitOutcome
	Harmful   bool

	// Any other custom proc conditions not covered by the above fields.
	CustomProcCondition core.CustomStatBuffProcCondition
}

type StackingStatBonusCD

type StackingStatBonusCD struct {
	Name        string
	ID          int32
	AuraID      int32
	Bonus       stats.Stats
	Duration    time.Duration
	MaxStacks   int32
	CD          time.Duration
	Callback    core.AuraCallback
	ProcMask    core.ProcMask
	SpellFlags  core.SpellFlag
	Outcome     core.HitOutcome
	Harmful     bool
	ProcChance  float64
	IsDefensive bool

	// The stacks will only be granted as long as the trinket is active
	TrinketLimitsDuration bool
}

type StackingStatBonusEffect

type StackingStatBonusEffect struct {
	Name       string
	ItemID     int32
	AuraID     int32
	Bonus      stats.Stats
	Duration   time.Duration
	MaxStacks  int32
	Callback   core.AuraCallback
	ProcMask   core.ProcMask
	SpellFlags core.SpellFlag
	Outcome    core.HitOutcome
	Harmful    bool
	ProcChance float64
	Icd        time.Duration
}

Jump to

Keyboard shortcuts

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