Struct HalfVector3
Implements
Inherited Members
Namespace: Unity.Netcode.Components
Assembly: solution.dll
Syntax
public struct HalfVector3 : INetworkSerializable
Constructors
Name | Description |
---|---|
HalfVector3(float, float, float) | Constructor that defaults to all axis being synchronized. |
HalfVector3(float, float, float, bool3) | Constructor |
HalfVector3(Vector3) | Constructor that defaults to all axis being synchronized. |
HalfVector3(Vector3, bool3) | Constructor |
Fields
Name | Description |
---|---|
Axis | Used to store the half float precision values as a half3 |
AxisToSynchronize | Determine which axis will be synchronized during serialization |
Properties
Name | Description |
---|---|
X | The half float precision value of the x-axis as a half. |
Y | The half float precision value of the y-axis as a half. |
Z | The half float precision value of the z-axis as a half. |
Methods
Name | Description |
---|---|
NetworkSerialize<T>(BufferSerializer<T>) | The serialization implementation of INetworkSerializable. |
ToVector3() | Gets the full precision value as a Vector3. |
UpdateFrom(ref Vector3) | Converts a full precision Vector3 to half precision and updates the current instance. |