FAST SDK Coding Reference 1.0.3
Loading...
Searching...
No Matches
StartupLoader Class Referenceabstract

A base class to help load resources or dependencies on startup. More...

Inheritance diagram for StartupLoader:
AssetsLoader DisplayLoader InstallationLoader MarkerTrackingSettingsLoader SerialConnectionLoader SettingsLoader UdpConnectionLoader WebRequestLoader

Public Member Functions

void Load ()
 Runs the FAST.StartupLoader.ExecuteLoad() Coroutine
 

Public Attributes

StartupErrorMessageEvent errorEvent
 Inspector, Code
Calls the function(s) subscribed to this UnityEvent when there is an error message.
 
StartupLoadingMessageEvent loadingEvent
 Inspector, Code
Calls the function(s) subscribed to this UnityEvent when there is a loading progress message.
 
StartupSuccessEvent successEvent
 Inspector, Code
Calls the function(s) subscribed to this UnityEvent when loading is done.
 

Static Public Attributes

static int needToLoadCount = 0
 The number of FAST.StartupLoaders to execute on startup.
 

Protected Member Functions

virtual void Awake ()
 The default behavior is to increment the FAST.StartupLoader.needToLoadCount.
 
IEnumerator ExecuteLoad ()
 The Coroutine function that executes the loading of a resource or dependency, including progress and error messages.
 

Protected Attributes

string errorMessage
 A variable to compose an error message and details before invoking the FAST.StartupLoader.errorEvent.
 
string errorTitle
 A variable to compose an error message title before invoking the FAST.StartupLoader.errorEvent.
 
string loadingMessage
 A variable to compose a loading progress message and details before invoking the FAST.StartupLoader.loadingEvent.
 
float loadingMessageDuration = 0f
 Inspector
The amount of time in seconds to show a FAST.LoadingProgress message.
 
string loadingTitle
 A variable to compose a loading progress message title before invoking the FAST.StartupLoader.loadingEvent.
 

Detailed Description

A base class to help load resources or dependencies on startup.

Each type of StartupLoader executes different loading steps depending on the resource or dependency, but every StartupLoader communicates updates and state to the FAST.StartupManager and the FAST.LoadingScreenManager.

See also
UnityEngine.Events.UnityEvent
UnityEngine.Coroutine

Member Function Documentation

◆ Awake()

virtual void Awake ( )
protectedvirtual

The default behavior is to increment the FAST.StartupLoader.needToLoadCount.

◆ ExecuteLoad()

IEnumerator ExecuteLoad ( )
abstractprotected

The Coroutine function that executes the loading of a resource or dependency, including progress and error messages.

◆ Load()

void Load ( )

Member Data Documentation

◆ errorEvent

Inspector, Code
Calls the function(s) subscribed to this UnityEvent when there is an error message.

◆ errorMessage

string errorMessage
protected

A variable to compose an error message and details before invoking the FAST.StartupLoader.errorEvent.

Using this to implement a derived class is a convention, but not strictly required.

◆ errorTitle

string errorTitle
protected

A variable to compose an error message title before invoking the FAST.StartupLoader.errorEvent.

Using this to implement a derived class is a convention, but not strictly required.

◆ loadingEvent

Inspector, Code
Calls the function(s) subscribed to this UnityEvent when there is a loading progress message.

◆ loadingMessage

string loadingMessage
protected

A variable to compose a loading progress message and details before invoking the FAST.StartupLoader.loadingEvent.

Using this to implement a derived class is a convention, but not strictly required.

◆ loadingMessageDuration

float loadingMessageDuration = 0f
protected

Inspector
The amount of time in seconds to show a FAST.LoadingProgress message.

◆ loadingTitle

string loadingTitle
protected

A variable to compose a loading progress message title before invoking the FAST.StartupLoader.loadingEvent.

Using this to implement a derived class is a convention, but not strictly required.

◆ needToLoadCount

int needToLoadCount = 0
static

The number of FAST.StartupLoaders to execute on startup.

This is used by the FAST.StartupManager to determine when resource and dependency loading is done.

◆ successEvent

StartupSuccessEvent successEvent

Inspector, Code
Calls the function(s) subscribed to this UnityEvent when loading is done.


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