Style Slasher
A dressup combat roguelike created by Scrungle Studios for the 2025 Swinburne Capstone project.
Slasher.Entity.EntityParam Class Reference
Collaboration diagram for Slasher.Entity.EntityParam:
Collaboration graph

Public Member Functions

 EntityParam (ParamID id, ParamDefinition definition)
 
 EntityParam (ParamID id, ParamModifier modifier)
 
void AddModifier (ParamModifier modifier)
 
void RemoveModifier (ParamModifier modifier)
 
bool IsUnused ()
 
void RequestRecalculate ()
 

Properties

static EntityParam Empty [get]
 
float Value [get]
 The total final value, calculated using this formula: (baseValue + (additive sum)) * (multiplicative sum)
 
bool ValueAsBool [get]
 The boolean value of this parameter.
 
float Base [get]
 
float Additive [get]
 
float Multiplicative [get]
 The multiplicative value of this parameter, offset from 1.
 
int Influencers [get]
 

Events

Action OnChanged [add, remove]
 
Action OnChangedInternal = () => { }
 

Private Member Functions

 EntityParam ()
 Creates a blank EntityParam.
 
void Recalculate ()
 

Private Attributes

ParamID id
 
ParamDefinition baseValue
 
ParamModifierList modifiers
 
bool stale
 
float addCache
 
float multiplyCache
 
int listeners
 

Static Private Attributes

static EntityParam empty
 

Constructor & Destructor Documentation

◆ EntityParam() [1/3]

Slasher.Entity.EntityParam.EntityParam ( ParamID id,
ParamDefinition definition )
Here is the call graph for this function:

◆ EntityParam() [2/3]

Slasher.Entity.EntityParam.EntityParam ( ParamID id,
ParamModifier modifier )
Here is the call graph for this function:

◆ EntityParam() [3/3]

Slasher.Entity.EntityParam.EntityParam ( )
private

Creates a blank EntityParam.

Should only exist to return dummy values.

Member Function Documentation

◆ AddModifier()

void Slasher.Entity.EntityParam.AddModifier ( ParamModifier modifier)

◆ IsUnused()

bool Slasher.Entity.EntityParam.IsUnused ( )

◆ Recalculate()

void Slasher.Entity.EntityParam.Recalculate ( )
private

◆ RemoveModifier()

void Slasher.Entity.EntityParam.RemoveModifier ( ParamModifier modifier)

◆ RequestRecalculate()

void Slasher.Entity.EntityParam.RequestRecalculate ( )
Here is the call graph for this function:

Member Data Documentation

◆ addCache

float Slasher.Entity.EntityParam.addCache
private

◆ baseValue

ParamDefinition Slasher.Entity.EntityParam.baseValue
private

◆ empty

EntityParam Slasher.Entity.EntityParam.empty
staticprivate

◆ id

ParamID Slasher.Entity.EntityParam.id
private

◆ listeners

int Slasher.Entity.EntityParam.listeners
private

◆ modifiers

ParamModifierList Slasher.Entity.EntityParam.modifiers
private

◆ multiplyCache

float Slasher.Entity.EntityParam.multiplyCache
private

◆ stale

bool Slasher.Entity.EntityParam.stale
private

Property Documentation

◆ Additive

float Slasher.Entity.EntityParam.Additive
get

◆ Base

float Slasher.Entity.EntityParam.Base
get

◆ Empty

EntityParam Slasher.Entity.EntityParam.Empty
staticget

◆ Influencers

int Slasher.Entity.EntityParam.Influencers
get

◆ Multiplicative

float Slasher.Entity.EntityParam.Multiplicative
get

The multiplicative value of this parameter, offset from 1.

Multiplying by this value should directly work.

◆ Value

float Slasher.Entity.EntityParam.Value
get

The total final value, calculated using this formula: (baseValue + (additive sum)) * (multiplicative sum)

◆ ValueAsBool

bool Slasher.Entity.EntityParam.ValueAsBool
get

The boolean value of this parameter.

Do NOT use this unless the ParamID is a bool!

Event Documentation

◆ OnChanged

Action Slasher.Entity.EntityParam.OnChanged
addremove

◆ OnChangedInternal

Action Slasher.Entity.EntityParam.OnChangedInternal = () => { }
private

The documentation for this class was generated from the following file: