Arcade
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
GameAPI.BudgetBoy.CoroutineCollection Class Reference

Holds a collection of active Coroutines, and implements coroutine execution logic. More...

Public Member Functions

 CoroutineCollection ()
 Constructs an empty CoroutineCollection. More...
 
void Clear ()
 Suspends and clears all Coroutines added to this instance. More...
 
Coroutine Start (IEnumerator enumerator)
 Starts a coroutine from an IEnumerator that is expected to yeild Awaitable instances, null references (to delay until next the update), or other IEnumerator coroutines. When another IEnumerator is yielded the parent IEnumerator will pause execution until the child IEnumerator has finished. More...
 
Coroutine Start (Func< IEnumerator > function)
 Starts a coroutine from a function returning IEnumerator that is expected to yeild Awaitable instances, null references (to delay until next the update), or other IEnumerator coroutines. When another IEnumerator is yielded the parent IEnumerator will pause execution until the child IEnumerator has finished. More...
 
bool Contains (Coroutine routine)
 Tests whether the given coroutine is a member of this collection. More...
 
void Update ()
 Executes one step of all active Coroutine instances held within the collection. More...
 

Detailed Description

Holds a collection of active Coroutines, and implements coroutine execution logic.

Constructor & Destructor Documentation

GameAPI.BudgetBoy.CoroutineCollection.CoroutineCollection ( )
inline

Constructs an empty CoroutineCollection.

Member Function Documentation

void GameAPI.BudgetBoy.CoroutineCollection.Clear ( )
inline

Suspends and clears all Coroutines added to this instance.

bool GameAPI.BudgetBoy.CoroutineCollection.Contains ( Coroutine  routine)
inline

Tests whether the given coroutine is a member of this collection.

Parameters
routineCoroutine to look for.
Returns
True if the coroutine is active and held within this collection.
Coroutine GameAPI.BudgetBoy.CoroutineCollection.Start ( IEnumerator  enumerator)
inline

Starts a coroutine from an IEnumerator that is expected to yeild Awaitable instances, null references (to delay until next the update), or other IEnumerator coroutines. When another IEnumerator is yielded the parent IEnumerator will pause execution until the child IEnumerator has finished.

Parameters
enumeratorIEnumerator representing a Coroutine.
Returns
A Coroutine instance corresponding to the enumerator.
Coroutine GameAPI.BudgetBoy.CoroutineCollection.Start ( Func< IEnumerator >  function)
inline

Starts a coroutine from a function returning IEnumerator that is expected to yeild Awaitable instances, null references (to delay until next the update), or other IEnumerator coroutines. When another IEnumerator is yielded the parent IEnumerator will pause execution until the child IEnumerator has finished.

Parameters
functionFunction representing a Coroutine.
Returns
A Coroutine instance corresponding to the function.
void GameAPI.BudgetBoy.CoroutineCollection.Update ( )
inline

Executes one step of all active Coroutine instances held within the collection.