C# Class UnityEngine.Networking.NetworkIdentity

Inheritance: UnityEngine.MonoBehaviour
Show file Open project: CarlosHBC/UnityDecompiled Class Usage Examples

Public Properties

Property Type Description
clientAuthorityCallback ClientAuthorityCallback

Public Methods

Method Description
AssignClientAuthority ( NetworkConnection conn ) : bool

This assigns control of an object to a client via the client's NetworkConnection.

ForceSceneId ( int newSceneId ) : void

Force the scene ID to a specific value.

RebuildObservers ( bool initialize ) : void

This causes the set of players that can see this object to be rebuild. The OnRebuildObservers callback function will be invoked on each NetworkBehaviour.

RemoveClientAuthority ( NetworkConnection conn ) : bool

Removes ownership for an object for a client by its conneciton.

Private Methods

Method Description
AddNetworkId ( uint id ) : void
AddObserver ( NetworkConnection conn ) : void
AssignAssetID ( GameObject prefab ) : void
CacheBehaviours ( ) : void
ClearClientOwner ( ) : void
ClearObservers ( ) : void
ForceAuthority ( bool authority ) : void
GetInvokeComponent ( int cmdHash, System invokeClass, NetworkBehaviour &invokeComponent ) : bool
GetNextNetworkId ( ) : NetworkInstanceId
HandleClientAuthority ( bool authority ) : void
HandleCommand ( int cmdHash, NetworkReader reader ) : void
HandleRPC ( int cmdHash, NetworkReader reader ) : void
HandleSyncEvent ( int cmdHash, NetworkReader reader ) : void
HandleSyncList ( int cmdHash, NetworkReader reader ) : void
OnCheckObserver ( NetworkConnection conn ) : bool
OnDestroy ( ) : void
OnNetworkDestroy ( ) : void
OnSetLocalVisibility ( bool vis ) : void
OnStartAuthority ( ) : void
OnStartClient ( ) : void
OnStartServer ( bool allowNonZeroNetId ) : void
OnStopAuthority ( ) : void
OnUpdateVars ( NetworkReader reader, bool initialState ) : void
OnValidate ( ) : void
RemoveObserver ( NetworkConnection conn ) : void
RemoveObserverInternal ( NetworkConnection conn ) : void
Reset ( ) : void
SetClientOwner ( NetworkConnection conn ) : void
SetConnectionToClient ( NetworkConnection conn, short newPlayerControllerId ) : void
SetConnectionToServer ( NetworkConnection conn ) : void
SetDynamicAssetId ( NetworkHash128 newAssetId ) : void
SetLocalPlayer ( short localPlayerControllerId ) : void
SetNetworkInstanceId ( NetworkInstanceId newNetId ) : void
SetNotLocalPlayer ( ) : void
SetupIDs ( ) : void
ThisIsAPrefab ( ) : bool
ThisIsASceneObjectWithPrefabParent ( GameObject &prefab ) : bool
UNetDomainReload ( ) : void
UNetSerializeAllVars ( NetworkWriter writer ) : void
UNetStaticUpdate ( ) : void
UNetUpdate ( ) : void
UpdateClientServer ( bool isClientFlag, bool isServerFlag ) : void

Method Details

AssignClientAuthority() public method

This assigns control of an object to a client via the client's NetworkConnection.

public AssignClientAuthority ( NetworkConnection conn ) : bool
conn NetworkConnection The connection of the client to assign authority to.
return bool

ForceSceneId() public method

Force the scene ID to a specific value.

public ForceSceneId ( int newSceneId ) : void
newSceneId int
return void

RebuildObservers() public method

This causes the set of players that can see this object to be rebuild. The OnRebuildObservers callback function will be invoked on each NetworkBehaviour.

public RebuildObservers ( bool initialize ) : void
initialize bool True if this is the first time.
return void

RemoveClientAuthority() public method

Removes ownership for an object for a client by its conneciton.

public RemoveClientAuthority ( NetworkConnection conn ) : bool
conn NetworkConnection The connection of the client to remove authority for.
return bool

Property Details

clientAuthorityCallback public static property

A callback that can be populated to be notified when the client-authority state of objects changes.

public static ClientAuthorityCallback clientAuthorityCallback
return ClientAuthorityCallback