Class LayerMaskExtensions | Unity Reflect | 1.1.0-preview.6
docs.unity.cn
    Show / Hide Table of Contents

    Class LayerMaskExtensions

    Inheritance
    Object
    LayerMaskExtensions
    Namespace: Unity.Labs.Utils
    Syntax
    public static class LayerMaskExtensions

    Methods

    Contains(LayerMask, Int32)

    Extension method to check if a layer is in a LayerMask

    Declaration
    public static bool Contains(this LayerMask mask, int layer)
    Parameters
    Type Name Description
    LayerMask mask

    The layer mask

    Int32 layer

    The layer index to check for

    Returns
    Type Description
    Boolean

    GetFirstLayerIndex(LayerMask)

    Get the index first enabled layer in this layerMask

    Declaration
    public static int GetFirstLayerIndex(this LayerMask layerMask)
    Parameters
    Type Name Description
    LayerMask layerMask
    Returns
    Type Description
    Int32

    The index of the first enabled layer

    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX