Class NetworkAuthenticator
Base class for implementing component-based authentication during the Connect phase
Namespace: Mirror
Assembly: doc.dll
Syntax
public abstract class NetworkAuthenticator : MonoBehaviour
Fields
| Improve this Doc View SourceOnClientAuthenticated
Notify subscribers on the client when the client is authenticated
Declaration
public UnityEvent OnClientAuthenticated
Field Value
Type | Description |
---|---|
UnityEvent |
OnServerAuthenticated
Notify subscribers on the server when a client is authenticated
Declaration
public UnityEventNetworkConnection OnServerAuthenticated
Field Value
Type | Description |
---|---|
UnityEventNetworkConnection |
Methods
| Improve this Doc View SourceClientAccept()
Declaration
protected void ClientAccept()
ClientReject()
Declaration
protected void ClientReject()
OnClientAuthenticate()
Called on client from OnClientConnectInternal when a client needs to authenticate
Declaration
public virtual void OnClientAuthenticate()
OnServerAuthenticate(NetworkConnectionToClient)
Called on server from OnServerConnectInternal when a client needs to authenticate
Declaration
public virtual void OnServerAuthenticate(NetworkConnectionToClient conn)
Parameters
Type | Name | Description |
---|---|---|
NetworkConnectionToClient | conn |
OnStartClient()
Called when client starts, used to register message handlers if needed.
Declaration
public virtual void OnStartClient()
OnStartServer()
Called when server starts, used to register message handlers if needed.
Declaration
public virtual void OnStartServer()
OnStopClient()
Called when client stops, used to unregister message handlers if needed.
Declaration
public virtual void OnStopClient()
OnStopServer()
Called when server stops, used to unregister message handlers if needed.
Declaration
public virtual void OnStopServer()
ServerAccept(NetworkConnectionToClient)
Declaration
protected void ServerAccept(NetworkConnectionToClient conn)
Parameters
Type | Name | Description |
---|---|---|
NetworkConnectionToClient | conn |
ServerReject(NetworkConnectionToClient)
Declaration
protected void ServerReject(NetworkConnectionToClient conn)
Parameters
Type | Name | Description |
---|---|---|
NetworkConnectionToClient | conn |