docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method Angle

    Angle(Vector3, Vector3)

    Much more stable for small angles than Unity's native implementation

    Declaration
    public static float Angle(Vector3 v1, Vector3 v2)
    Parameters
    Type Name Description
    Vector3 v1

    The first vector

    Vector3 v2

    The second vector

    Returns
    Type Description
    float

    Angle between the vectors, in degrees

    In This Article
    Back to top
    Copyright © 2023 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)