Class EntitiesManager
public sealed class EntitiesManager
- Inheritance
-
EntitiesManager
Constructors
EntitiesManager(ICoherenceBridge, CoherenceClientConnectionManager, CoherenceInputManager, UniquenessManager, IDefinition, Logger)
public EntitiesManager(ICoherenceBridge bridge, CoherenceClientConnectionManager clientConnectionsManager, CoherenceInputManager inputManager, UniquenessManager uniquenessManager, IDefinition definition, Logger logger)
Parameters
bridge
ICoherenceBridgeclientConnectionsManager
CoherenceClientConnectionManagerinputManager
CoherenceInputManageruniquenessManager
UniquenessManagerdefinition
IDefinitionlogger
Logger
Fields
internalEntities
A set of known non-toolkit entities.
public HashSet<Entity> internalEntities
Field Value
Properties
ConnectionEntityID
public Entity ConnectionEntityID { get; }
Property Value
EntityCount
public int EntityCount { get; }
Property Value
NetworkEntities
public IEnumerable<NetworkEntityState> NetworkEntities { get; }
Property Value
Methods
EntityIdToCoherenceSync(Entity)
Get the CoherenceSync for a Entity.
public ICoherenceSync EntityIdToCoherenceSync(Entity from)
Parameters
from
Entity
Returns
EntityIdToGameObject(Entity)
Get the GameObject
for a Entity.
public GameObject EntityIdToGameObject(Entity from)
Parameters
from
Entity
Returns
- GameObject
EntityIdToRectTransform(Entity)
Get the RectTransform
for a Entity.
public RectTransform EntityIdToRectTransform(Entity from)
Parameters
from
Entity
Returns
EntityIdToTransform(Entity)
Get the Transform
for a Entity.
public Transform EntityIdToTransform(Entity from)
Parameters
from
Entity
Returns
GetCoherenceSyncForEntity(Entity)
Get a CoherenceSync from the mapper.
public ICoherenceSync GetCoherenceSyncForEntity(Entity id)
Parameters
id
EntityA valid Entity (meaning it exists in the mapper)
Returns
GetEnumerator()
public Dictionary<Entity, NetworkEntityState>.Enumerator GetEnumerator()
Returns
GetNetworkEntityStateForEntity(Entity)
Get a Network Entity State from the mapper.
public NetworkEntityState GetNetworkEntityStateForEntity(Entity id)
Parameters
id
EntityA valid Entity (meaning it exists in the mapper)
Returns
InterpolateBindings(InterpolationLoop)
public void InterpolateBindings(CoherenceSync.InterpolationLoop interpolationLoop)
Parameters
interpolationLoop
CoherenceSync.InterpolationLoop
InvokeCallbacks(InterpolationLoop)
public void InvokeCallbacks(CoherenceSync.InterpolationLoop interpolationLoop)
Parameters
interpolationLoop
CoherenceSync.InterpolationLoop
SampleBindings(InterpolationLoop)
public void SampleBindings(CoherenceSync.InterpolationLoop interpolationLoop)
Parameters
interpolationLoop
CoherenceSync.InterpolationLoop
SetActiveScene()
Set the Active Unity Scene based on this CoherenceBridge instance. If the CoherenceBridge has an instantiation scene set, that one will be used. Otherwise it will fall back on the current scene of the Coherence Bridge game object.
public Scene? SetActiveScene()
Returns
SyncAndSend()
public void SyncAndSend()
TryGetNetworkEntityState(Entity, out NetworkEntityState)
public bool TryGetNetworkEntityState(Entity id, out NetworkEntityState networkEntityState)
Parameters
id
EntitynetworkEntityState
NetworkEntityState
Returns
UnityObjectToEntityId(CoherenceSync)
Get the Entity for a CoherenceSync.
public Entity UnityObjectToEntityId(CoherenceSync from)
Parameters
from
CoherenceSync
Returns
UnityObjectToEntityId(GameObject)
Get the Entity for a
GameObject
with CoherenceSync.
public Entity UnityObjectToEntityId(GameObject from)
Parameters
from
GameObject
Returns
UnityObjectToEntityId(Transform)
Get the Entity for a
Transform
with CoherenceSync.
public Entity UnityObjectToEntityId(Transform from)
Parameters
from
Transform