Provides utility methods for reading and writing data. More...
Static Public Member Functions | |
static float | ReadFloat (int *data) |
Reads a float value from the provided memory location. | |
static NetworkBehaviour | ReadNetworkBehaviourRef (int *data, NetworkRunner runner, out bool isValid) |
Reads a NetworkBehaviour reference from the provided memory location. Null is considered valid (0,1). | |
static Quaternion | ReadQuaternion (int *data) |
Reads a Quaternion value from the provided memory location. | |
static Vector2 | ReadVector2 (int *data) |
Reads a Vector2 value from the provided memory location. | |
static Vector3 | ReadVector3 (int *data) |
Reads a Vector3 value from the provided memory location. | |
static Vector4 | ReadVector4 (int *data) |
Reads a Vector4 value from the provided memory location. | |
static void | WriteEmptyNetworkBehaviourRef (int *data) |
Writes an empty NetworkBehaviour reference to the provided memory location. | |
static void | WriteFloat (int *data, float f) |
Writes a float value to the provided memory location. | |
static void | WriteNetworkBehaviourRef (int *data, NetworkRunner runner, NetworkBehaviour reference) |
Writes a NetworkBehaviour reference to the provided memory location. | |
static void | WriteNullBehaviourRef (int *data) |
Writes a null NetworkBehaviour reference to the provided memory location. | |
static void | WriteQuaternion (int *data, Quaternion value) |
Writes a Quaternion value to the provided memory location. | |
static void | WriteVector2 (int *data, Vector2 value) |
Writes a Vector2 value to the provided memory location. | |
static void | WriteVector3 (int *data, Vector3 value) |
Writes a Vector3 value to the provided memory location. | |
static void | WriteVector4 (int *data, Vector4 value) |
Writes a Vector4 value to the provided memory location. | |
Static Public Attributes | |
const float | ACCURACY = 1 << 10 |
Accuracy of floating point values when serialized. | |
Provides utility methods for reading and writing data.
|
static |
Reads a float value from the provided memory location.
data | The memory location to read from. |
|
static |
Reads a NetworkBehaviour reference from the provided memory location. Null is considered valid (0,1).
data | The memory location to read from. |
runner | The NetworkRunner associated with the NetworkBehaviour. |
isValid | Out parameter indicating whether the read operation was valid. |
|
static |
Reads a Quaternion value from the provided memory location.
data | The memory location to read from. |
|
static |
Reads a Vector2 value from the provided memory location.
data | The memory location to read from. |
|
static |
Reads a Vector3 value from the provided memory location.
data | The memory location to read from. |
|
static |
Reads a Vector4 value from the provided memory location.
data | The memory location to read from. |
|
static |
Writes an empty NetworkBehaviour reference to the provided memory location.
data | The memory location to write to. |
|
static |
Writes a float value to the provided memory location.
data | The memory location to write to. |
f | The float value to write. |
|
static |
Writes a NetworkBehaviour reference to the provided memory location.
data | The memory location to write to. |
runner | The NetworkRunner associated with the NetworkBehaviour. |
reference | The NetworkBehaviour reference to write. |
|
static |
Writes a null NetworkBehaviour reference to the provided memory location.
data | The memory location to write to. |
|
static |
Writes a Quaternion value to the provided memory location.
data | The memory location to write to. |
value | The Quaternion value to write. |
|
static |
Writes a Vector2 value to the provided memory location.
data | The memory location to write to. |
value | The Vector2 value to write. |
|
static |
Writes a Vector3 value to the provided memory location.
data | The memory location to write to. |
value | The Vector3 value to write. |
|
static |
Writes a Vector4 value to the provided memory location.
data | The memory location to write to. |
value | The Vector4 value to write. |