Class NetCodeUtils
ToFixedString utilities for enums.
Assembly: Unity.NetCode.dll
Syntax
public static class NetCodeUtils
Methods
ToFixedString(State)
Returns the Fixed String enum value name.
Declaration
public static FixedString32Bytes ToFixedString(this ConnectionState.State state)
Parameters
Returns
Type |
Description |
FixedString32Bytes |
Returns the Fixed String enum value name.
|
ToFixedString(NetworkStreamDisconnectReason)
Returns the Fixed String enum value name.
Declaration
public static FixedString32Bytes ToFixedString(this NetworkStreamDisconnectReason reason)
Parameters
Returns
Type |
Description |
FixedString32Bytes |
Returns the Fixed String enum value name.
|
ToNetcodeState(State, bool)
Converts from the Transport state to ours.
Declaration
public static ConnectionState.State ToNetcodeState(this NetworkConnection.State transportState, bool hasHandshaked)
Parameters
Type |
Name |
Description |
NetworkConnection.State |
transportState |
|
bool |
hasHandshaked |
|
Returns
Exceptions