Class Effect

Namespace
SurvivorsMaker.Core
Assembly
SurvivorsMaker.Core.dll

One effect: a target id, an amount and how they are stored. Items, characters, level-up choices and buffs are lists of effects.

public sealed class Effect
Inheritance
Effect
Inherited Members

Constructors

Effect()

public Effect()

Effect(string, int, EffectMethod, string)

public Effect(string target, int amount, EffectMethod method = EffectMethod.Add, string list = "")

Parameters

target string
amount int
method EffectMethod
list string

Fields

Amount

public int Amount

Field Value

int

Buffer

public float Buffer

Field Value

float

ConversionFraction

public float ConversionFraction

Field Value

float

ExternalSource

public bool ExternalSource

Field Value

bool

Handler

Id of a custom IEffectHandler. Empty means the built-in rules of Method apply.

public string Handler

Field Value

string

HasOutputMax

public bool HasOutputMax

Field Value

bool

HasOutputMin

public bool HasOutputMin

Field Value

bool

InputMax

public float InputMax

Field Value

float

InputMin

public float InputMin

Field Value

float

Invert

public bool Invert

Field Value

bool

IsMinimum

public bool IsMinimum

Field Value

bool

Lifetime

public EffectLifetime Lifetime

Field Value

EffectLifetime

LifetimeTicks

Zero means no tick expiry. AdvanceCombatTicks is called only during combat.

public int LifetimeTicks

Field Value

int

LifetimeWaves

Zero means no wave expiry. Active on acquisition wave through start + N - 1.

public int LifetimeWaves

Field Value

int

LimitMode

public StatLimitMode LimitMode

Field Value

StatLimitMode

Linear

Map [InputMin + Buffer, InputMax] to [OutputMin, OutputMax], clamped.

public bool Linear

Field Value

bool

List

Name of the list the list methods write to, e.g. "loadout" or "on_wave_start".

public string List

Field Value

string

Method

public EffectMethod Method

Field Value

EffectMethod

OutputMax

public float OutputMax

Field Value

float

OutputMin

public float OutputMin

Field Value

float

ReadLayer

public StatReadLayer ReadLayer

Field Value

StatReadLayer

Rounding

public EffectRounding Rounding

Field Value

EffectRounding

Source

Stat id, or external key when ExternalSource is true.

public string Source

Field Value

string

Target

Stat id for Add/Set; entry id for list methods.

public string Target

Field Value

string

Temporary

public bool Temporary

Field Value

bool

Unit

public float Unit

Field Value

float

Properties

IsCustom

public bool IsCustom { get; }

Property Value

bool

IsListMethod

True for methods that write to List.

public bool IsListMethod { get; }

Property Value

bool

Methods

Add(string, int)

Creates a built-in additive stat effect in integer stat points.

public static Effect Add(string stat, int amount)

Parameters

stat string
amount int

Returns

Effect

Set(string, int)

Creates a built-in stat assignment effect.

public static Effect Set(string stat, int value)

Parameters

stat string
value int

Returns

Effect

ToString()

public override string ToString()

Returns

string