Enum NetworkConnection.State
Different states in which a NetworkConnection can be.
Namespace: Unity.Networking.Transport
Syntax
public enum State
Fields
Name | Description | Value |
---|---|---|
Disconnected | Connection is closed. No data may be sent on it, and no further event will be received for the connection. |
0 |
Disconnecting | Indicates the connection is in the process of being disconnected. This is an internal state, and will be mapped to Disconnected when calling GetConnectionState(NetworkConnection). |
1 |
Connecting | Connection is in the process of being established. No data may be sent on it and the next event will be either Connect if the connection was successfully established, or Disconnect if it failed to reach the server. |
2 |
Connected | Connection is open. Can send and receive data on it. |
3 |