CustomAssets
Askowl Custom Assets
CustomAsset.Base Class Reference

Base class for all custom assets - implementing initialisation More...

Inheritance diagram for CustomAsset.Base:
CustomAsset.Constant.Enumeration CustomAsset.Constant.OfType< T > CustomAsset.Manager CustomAsset.Mutable.WithEmitter CustomAsset.Constant.Integer Askowl.AssetWizard Askowl.CustomAssets.Transcripts.HealthManagerTranscript Askowl.Transcripts.PlayerDeathManager Askowl.Transcripts.SceneManager CustomAsset.Mutable.OfType< T > CustomAsset.Mutable.Trigger CustomAsset.Mutable.Boolean CustomAsset.Mutable.String CustomAsset.Mutable.ChangeOverTime

Public Member Functions

void Initialiser ()
 Called by Managers MonoBehaviour More...
 

Static Public Member Functions

static T Instance< T > (string path)
 If this is a project asset, then you will need to reference it somewhere. Other classes can get a reference using Instance() or Instance(string name). Also useful for creating in-memory versions to share between hosts More...
 

Public Attributes

string Description => description
 Editor only description of what the asset is all about More...
 

Protected Member Functions

virtual void Initialise ()
 Called by Managers MonoBehaviour or when mutual data is first accessed More...
 
virtual void OnEnable ()
 make sure that this item will be initialised at least one frame after it is enabled and the scene is loaded More...
 
virtual void OnDisable ()
 clear the decks as all is being destroyed More...
 

Protected Attributes

bool Initialised
  More...
 

Static Protected Attributes

static readonly Emitter InitialiseAssetEmitter = Emitter.SingleFireInstance
 triggered by scene load in Manager More...
 
static readonly Fifo< BaseAssetsWaitingInitialisation = Fifo<Base>.Instance
 initialisation for all assets loaded before the related/first scene More...
 

Detailed Description

Member Function Documentation

◆ Initialise()

◆ Initialiser()

void CustomAsset.Base.Initialiser ( )

Called by Managers MonoBehaviour

Definition at line 21 of file Base.cs.

◆ Instance< T >()

◆ OnDisable()

virtual void CustomAsset.Base.OnDisable ( )
protectedvirtual

clear the decks as all is being destroyed

Reimplemented in CustomAsset.Mutable.OfType< T >.

◆ OnEnable()

virtual void CustomAsset.Base.OnEnable ( )
protectedvirtual

make sure that this item will be initialised at least one frame after it is enabled and the scene is loaded

Reimplemented in CustomAsset.Mutable.OfType< T >, and CustomAsset.Mutable.WithEmitter.

Definition at line 30 of file Base.cs.

Member Data Documentation

◆ AssetsWaitingInitialisation

readonly Fifo<Base> CustomAsset.Base.AssetsWaitingInitialisation = Fifo<Base>.Instance
staticprotected

initialisation for all assets loaded before the related/first scene

Definition at line 38 of file Base.cs.

◆ Description

string CustomAsset.Base.Description => description

◆ InitialiseAssetEmitter

readonly Emitter CustomAsset.Base.InitialiseAssetEmitter = Emitter.SingleFireInstance
staticprotected

triggered by scene load in Manager

Definition at line 35 of file Base.cs.

◆ Initialised

bool CustomAsset.Base.Initialised
protected

Definition at line 18 of file Base.cs.


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