docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct HalfVector3

    Implements
    INetworkSerializable
    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    ValueType.ToString()
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetType()
    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.

    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)