docs.unity3d.com
    Show / Hide Table of Contents

    Class IKUtility

    General utilities for 2D IK.

    Inheritance
    Object
    IKUtility
    Namespace: UnityEngine.U2D.IK
    Syntax
    public class IKUtility : object

    Methods

    GetAncestorCount(Transform)

    Gets the hierarchy depth of a Unity Transform.

    Declaration
    public static int GetAncestorCount(Transform transform)
    Parameters
    Type Name Description
    Transform transform

    Unity Transform to check.

    Returns
    Type Description
    Int32

    Integer value for hierarchy depth.

    GetMaxChainCount(IKChain2D)

    Gets the maximum chain count for a IKChain2D.

    Declaration
    public static int GetMaxChainCount(IKChain2D chain)
    Parameters
    Type Name Description
    IKChain2D chain

    IKChain2D to query.

    Returns
    Type Description
    Int32

    Integer value for the maximum chain count.

    IsDescendentOf(Transform, Transform)

    Check if a Unity Transform is a descendent of another Unity Transform.

    Declaration
    public static bool IsDescendentOf(Transform transform, Transform ancestor)
    Parameters
    Type Name Description
    Transform transform

    Unity Transform to check.

    Transform ancestor

    Unity Transform ancestor.

    Returns
    Type Description
    Boolean

    Returns true if the Unity Transform is a descendent. False otherwise.

    Back to top
    Terms of use
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023