Class SynthesizedObject
Class that automatically inserts and updates data in MARS' reality database Intrinsically linked to the Real World Object it is parented to
Namespace: Unity.MARS.Data.Synthetic
Syntax
public class SynthesizedObject : MonoBehaviour, IMatchAcquireHandler, IMatchUpdateHandler, IMatchLossHandler, IAction, ISimulatable, IUsesMARSData<SynthesizedObject>, IUsesFunctionalityInjection
Methods
OnDataBaseLost()
Called if the database that the synthesized object feeds into shuts down. In that case, we just reset our data ID so we don't try to interact with the database anymore.
Declaration
public void OnDataBaseLost()
OnMatchAcquire(QueryResult)
Called when a query match has been found
Declaration
public void OnMatchAcquire(QueryResult queryResult)
Parameters
Type | Name | Description |
---|---|---|
QueryResult | queryResult | Data associated with this event |
Implements
OnMatchLoss(QueryResult)
Called when a query match has been lost
Declaration
public void OnMatchLoss(QueryResult queryResult)
Parameters
Type | Name | Description |
---|---|---|
QueryResult | queryResult | Data associated with this event |
Implements
OnMatchUpdate(QueryResult)
Called when a query match's data has updated
Declaration
public void OnMatchUpdate(QueryResult queryResult)
Parameters
Type | Name | Description |
---|---|---|
QueryResult | queryResult | Data associated with this event |
Implements
SyncModifications()
Flags the SynthesizedObject to do a full update on the next frame. Useful for traits that are normally static upon creation, but can be changed dynamically by user scripts.
Declaration
public void SyncModifications()