Class StatModifierDef

Namespace
TDMaker.Core.Defs
Assembly
TDMaker.Core.dll

Immutable reversible stat changes, recomputed from base values in attachment order.

public sealed class StatModifierDef
Inheritance
StatModifierDef
Inherited Members

Constructors

StatModifierDef(float, float, float, float, float, float, float, bool)

Creates a reversible modifier.

public StatModifierDef(float speedScale = 1, float outputScale = 1, float inputScale = 1, float magicalInputScale = 1, float physicalShift = 0, float magicalShift = 0, float poisonShift = 0, bool stun = false)

Parameters

speedScale float
outputScale float
inputScale float
magicalInputScale float
physicalShift float
magicalShift float
poisonShift float
stun bool

Properties

Combat

Additional reversible range and control modifiers.

public CombatModifierDef Combat { get; }

Property Value

CombatModifierDef

InputScale

Multiplicative incoming damage change.

public float InputScale { get; }

Property Value

float

MagicalInputScale

Additional incoming magical damage change.

public float MagicalInputScale { get; }

Property Value

float

MagicalShift

Additive magical resistance change.

public float MagicalShift { get; }

Property Value

float

OutputScale

Multiplicative outgoing damage change.

public float OutputScale { get; }

Property Value

float

PhysicalShift

Additive physical defense change.

public float PhysicalShift { get; }

Property Value

float

PoisonShift

Additive poison resistance change.

public float PoisonShift { get; }

Property Value

float

SpeedScale

Multiplicative movement change; zero is supported.

public float SpeedScale { get; }

Property Value

float

Stun

Adds one independent stun reference.

public bool Stun { get; }

Property Value

bool

Methods

WithCombat(CombatModifierDef)

Copies numeric modifiers and adds combat modifiers.

public StatModifierDef WithCombat(CombatModifierDef combat)

Parameters

combat CombatModifierDef

Returns

StatModifierDef