All Classes Namespaces Functions Variables Enumerations Enumerator Properties
plyGame.MarkersAsset Class Reference

Contains a list of the defined markers that where detected. More...

Inherits ScriptableObject.

Public Member Functions

void UpdateCacheIfNeeded ()
 Updates the list of skills from skillFabs list. More...
 
bool UpdateCache ()
 Updates the list of skills from skillFabs list. return true if markerFabs list contained null entries. More...
 
GameObject GetPrefab (UniqueID id)
 Gets the prefab by Id. Return null if failed. More...
 
GameObject GetPrefab (string name)
 Gets the prefab by name. Return null if failed. More...
 
Marker GetDefinition (UniqueID id)
 Gets the definition by Id. Return null if failed. More...
 
Marker GetDefinition (string name)
 Get the defined by its name. Return null if not found. More...
 
UniqueID GetDefinitionUniqueId (string name)
 Get the defined by its name. Return UniqueID.Empty if not found. More...
 
UniqueID GetDefinitionUniqueId (int idx)
 Get the defined by its index in list. Return UniqueID.Empty if not found. More...
 
int GetDefinitionIdx (UniqueID id)
 Get the definition index into the list by its Id. Return -1 if not found. More...
 
string GetScreenName (UniqueID id)
 Get name by Id. Return "-invalid-" if not found. More...
 
string[] GetNames ()
 Get a list of names of all defined. More...
 

Public Attributes

List< GameObject > markerFabs = new List<GameObject>(0)
 List of detected prefabs.
 
List< Marker > markers = new List<Marker>(0)
 List of the actual objects. Should call UpdateCache() or UpdateCacheIfNeeded() before using this for first time.
 

Properties

static MarkersAsset Instance [get]
 Provide access to asset at runtime More...
 

Detailed Description

Contains a list of the defined markers that where detected.

Member Function Documentation

Marker plyGame.MarkersAsset.GetDefinition ( UniqueID  id)

Gets the definition by Id. Return null if failed.

Marker plyGame.MarkersAsset.GetDefinition ( string  name)

Get the defined by its name. Return null if not found.

int plyGame.MarkersAsset.GetDefinitionIdx ( UniqueID  id)

Get the definition index into the list by its Id. Return -1 if not found.

UniqueID plyGame.MarkersAsset.GetDefinitionUniqueId ( string  name)

Get the defined by its name. Return UniqueID.Empty if not found.

UniqueID plyGame.MarkersAsset.GetDefinitionUniqueId ( int  idx)

Get the defined by its index in list. Return UniqueID.Empty if not found.

string [] plyGame.MarkersAsset.GetNames ( )

Get a list of names of all defined.

GameObject plyGame.MarkersAsset.GetPrefab ( UniqueID  id)

Gets the prefab by Id. Return null if failed.

GameObject plyGame.MarkersAsset.GetPrefab ( string  name)

Gets the prefab by name. Return null if failed.

string plyGame.MarkersAsset.GetScreenName ( UniqueID  id)

Get name by Id. Return "-invalid-" if not found.

bool plyGame.MarkersAsset.UpdateCache ( )

Updates the list of skills from skillFabs list. return true if markerFabs list contained null entries.

void plyGame.MarkersAsset.UpdateCacheIfNeeded ( )

Updates the list of skills from skillFabs list.

Property Documentation

MarkersAsset plyGame.MarkersAsset.Instance
staticget

Provide access to asset at runtime