ToggleFlags
Toggles the specified flags on all hierarchy nodes.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Method
- Namespace: Unity.Hierarchy
- Assembly: UnityEngine.HierarchyCoreModule
ToggleFlags(HierarchyNodeFlags)
Toggles the specified flags on all hierarchy nodes.
public void ToggleFlags(HierarchyNodeFlags flags)
Parameters
The hierarchy node flags.
ToggleFlags(HierarchyNode, HierarchyNodeFlags)
Toggles the specified flags on the hierarchy node.
public void ToggleFlags(in HierarchyNode node, HierarchyNodeFlags flags)
Parameters
ToggleFlags(ReadOnlySpan<HierarchyNode>, HierarchyNodeFlags)
Toggles the specified flags on the hierarchy nodes.
public int ToggleFlags(ReadOnlySpan<HierarchyNode> nodes, HierarchyNodeFlags flags)
Parameters
The hierarchy nodes.
The hierarchy node flags.
Returns
Type | Description |
|---|---|
| int | The number of nodes that had their flags cleared. |
Remarks
Null or invalid nodes are ignored.
ToggleFlags(ReadOnlySpan<int>, HierarchyNodeFlags)
Toggles the specified flags on the hierarchy node indices.
public int ToggleFlags(ReadOnlySpan<int> indices, HierarchyNodeFlags flags)
Parameters
Returns
Type | Description |
|---|---|
| int | The number of nodes that had their flags cleared. |
Remarks
Invalid node indices are ignored.
ToggleFlags(HierarchyNode, HierarchyNodeFlags, bool)
Toggles the specified flags on all hierarchy nodes.
public void ToggleFlags(in HierarchyNode node, HierarchyNodeFlags flags, bool recurse)