Modifica

Condividi tramite


GameObjectExtensions.SetLayerRecursively Method

Definition

Overloads

SetLayerRecursively(GameObject, Int32)

Set the layer to the given object and the full hierarchy below it.

SetLayerRecursively(GameObject, Int32, Dictionary<GameObject,Int32>)

Set the layer to the given object and the full hierarchy below it and cache the previous layers in the out parameter.

SetLayerRecursively(GameObject, Int32)

Set the layer to the given object and the full hierarchy below it.

public:
[System::Runtime::CompilerServices::Extension]
 static void SetLayerRecursively(UnityEngine::GameObject ^ root, int layer);
public static void SetLayerRecursively (this UnityEngine.GameObject root, int layer);
static member SetLayerRecursively : UnityEngine.GameObject * int -> unit
<Extension()>
Public Sub SetLayerRecursively (root As GameObject, layer As Integer)

Parameters

root
UnityEngine.GameObject

Start point of the traverse

layer
Int32

The layer to apply

Applies to

SetLayerRecursively(GameObject, Int32, Dictionary<GameObject,Int32>)

Set the layer to the given object and the full hierarchy below it and cache the previous layers in the out parameter.

public:
[System::Runtime::CompilerServices::Extension]
 static void SetLayerRecursively(UnityEngine::GameObject ^ root, int layer, [Runtime::InteropServices::Out] System::Collections::Generic::Dictionary<UnityEngine::GameObject ^, int> ^ % cache);
public static void SetLayerRecursively (this UnityEngine.GameObject root, int layer, out System.Collections.Generic.Dictionary<UnityEngine.GameObject,int> cache);
static member SetLayerRecursively : UnityEngine.GameObject * int * Dictionary -> unit
<Extension()>
Public Sub SetLayerRecursively (root As GameObject, layer As Integer, ByRef cache As Dictionary(Of GameObject, Integer))

Parameters

root
UnityEngine.GameObject

Start point of the traverse

layer
Int32

The layer to apply

cache
Dictionary<UnityEngine.GameObject,Int32>

The previously set layer for each object

Applies to