C# Class CharacterNetworkSync, unity-unet-authoritative-networking

Inheritance: NetworkBehaviour
Show file Open project: atrakeur/unity-unet-authoritative-networking Class Usage Examples

Public Methods

Method Description
OnDeserialize ( NetworkReader reader, bool initialState ) : void

All Clients: Deserialize the state from network

OnSerialize ( NetworkWriter writer, bool initialState ) : bool

Server: Serialize the state over network

Private Methods

Method Description
ServerStateReceived ( int clientInputState ) : void

Server: Called when a state from client was received and update finished

Start ( ) : void

Method Details

OnDeserialize() public method

All Clients: Deserialize the state from network
public OnDeserialize ( NetworkReader reader, bool initialState ) : void
reader NetworkReader
initialState bool
return void

OnSerialize() public method

Server: Serialize the state over network
public OnSerialize ( NetworkWriter writer, bool initialState ) : bool
writer UnityEngine.Networking.NetworkWriter
initialState bool
return bool