 | TransformXFindTransformInHierarchy Method |
Locate a
Transform by name in a hierarchy starting from the specified root.
Namespace: CandlelightAssembly: Assembly-CSharp-firstpass (in Assembly-CSharp-firstpass.dll) Version: 0.0.0.0
Syntaxpublic static Transform FindTransformInHierarchy(
this Transform root,
string transformName,
TransformXSearchNamespacesMode searchMode = TransformXSearchNamespacesMode.Respect,
char namespaceDelimiter = ':'
)
Parameters
- root
- Type: Transform
Transform whose hierarchy should be searched. - transformName
- Type: SystemString
Name of the Transform being sought. - searchMode (Optional)
- Type: CandlelightTransformXSearchNamespacesMode
If set to Respect, then transformName must specify the
namespace-qualified search query (e.g., "Character:LeftHand"). If set to
Ignore, then the method will return the first
match found for any Transform containing the specified namespaceDelimiter (e.g.,
"Character:LeftHand" would match a search for "LeftHand", given a namespace delimiter of ':').
- namespaceDelimiter (Optional)
- Type: SystemChar
Namespace delimiter.
Return Value
Type:
Transform
The
Transform in the hierarchy with the supplied name, if it exists; otherwise,
.
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).
See Also