Skip to main content

Class NetworkMatchChecker

Component that controls visibility of networked objects based on match id. Any object with this component on it will only be visible to other objects in the same match. This would be used to isolate players to their respective matches within a single game server instance.

Inheritance
System.Object
Mirage.NetworkBehaviour
Mirage.NetworkVisibility
Inherited Members
Show

Mirage.NetworkVisibility.OnVisibilityChanged

Mirage.NetworkBehaviour._nextSyncTime

Mirage.NetworkBehaviour.SyncSettings

Mirage.NetworkBehaviour.IsServer

Mirage.NetworkBehaviour.IsClient

Mirage.NetworkBehaviour.IsLocalClient

Mirage.NetworkBehaviour.IsHost

Mirage.NetworkBehaviour.IsLocalPlayer

Mirage.NetworkBehaviour.IsServerOnly

Mirage.NetworkBehaviour.IsClientOnly

Mirage.NetworkBehaviour.HasAuthority

Mirage.NetworkBehaviour.NetId

Mirage.NetworkBehaviour.Server

Mirage.NetworkBehaviour.ServerObjectManager

Mirage.NetworkBehaviour.Client

Mirage.NetworkBehaviour.ClientObjectManager

Mirage.NetworkBehaviour.Owner

Mirage.NetworkBehaviour.World

Mirage.NetworkBehaviour.NetworkTime

Mirage.NetworkBehaviour.BehaviourId

Mirage.NetworkBehaviour.SyncVarDirtyBits

Mirage.NetworkBehaviour.AnySyncObjectDirty

Mirage.NetworkBehaviour.syncObjects

Mirage.NetworkBehaviour.Identity

Mirage.NetworkBehaviour.COMPONENT_INDEX_NOT_FOUND

Mirage.NetworkBehaviour.ComponentIndex

Mirage.NetworkBehaviour.InitSyncObject(Mirage.Collections.ISyncObject)

Mirage.NetworkBehaviour.UpdateSyncObjectShouldSync()

Mirage.NetworkBehaviour.SyncVarEqual<T>(T, T)

Mirage.NetworkBehaviour.ClearDirtyBits()

Mirage.NetworkBehaviour.AnyDirtyBits()

Mirage.NetworkBehaviour.SerializeObjectsAll(Mirage.Serialization.NetworkWriter)

Mirage.NetworkBehaviour.SerializeObjectsDelta(Mirage.Serialization.NetworkWriter)

Mirage.NetworkBehaviour.GetRpcCount()

Mirage.NetworkBehaviour.RegisterRpc(Mirage.RemoteCalls.RemoteCallCollection)

Syntax
public class NetworkMatchChecker : NetworkVisibility, INetworkVisibility

Fields

currentMatchDebug

Declaration
public string currentMatchDebug

Properties

MatchId

Set this to the same value on all networked objects that belong to a given match

Declaration
public Guid MatchId { get; set; }

Methods

Awake()

Declaration
public void Awake()

OnStartServer()

Declaration
public void OnStartServer()

OnCheckObserver(INetworkPlayer)

Callback used by the visibility system to determine if an observer (player) can see this object. If this function returns true, the network connection will be added as an observer.

Declaration
public override bool OnCheckObserver(INetworkPlayer player)
Parameters
TypeNameDescription
Mirage.INetworkPlayerplayerNetwork connection of a player.
Returns
TypeDescription
System.BooleanTrue if the player can see this object.

OnRebuildObservers(HashSet<INetworkPlayer>, Boolean)

Callback used by the visibility system to (re)construct the set of observers that can see this object. Implementations of this callback should add network connections of players that can see this object to the observers set.

Declaration
public override void OnRebuildObservers(HashSet<INetworkPlayer> observers, bool initialize)
Parameters
TypeNameDescription
System.Collections.Generic.HashSet<Mirage.INetworkPlayer>observersThe new set of observers for this object.
System.BooleaninitializeTrue if the set of observers is being built for the first time.