TransformExt.FindRecursive Method
Tries to find an object by its name in the given Transform or any of its children recursively
Namespace: UltimateXR.Extensions.Unity
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0
Syntax
C#
public static Transform FindRecursive(
this Transform self,
string name,
StringComparison stringComparison = StringComparison.Ordinal
)
Parameters
- self
- Type: Transform
Transform whose hierarchy to search - name
- Type: System.String
Name of the transform to find - stringComparison (Optional)
- Type: System.StringComparison
Comparison rules to use
Return Value
Type: Transform
First transform found with the given name, or null if not found
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type Transform. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).