Version: Unity 6.5 Beta (6000.5)
LanguageEnglish
  • C#

HierarchyExtensions.GetNode

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public static HierarchyNode GetNode(Hierarchy hierarchy, EntityId entityId);

Parameters

Parameter Description
hierarchy The hierarchy.
entityId The entity id.

Returns

HierarchyNode The hierarchy node.

Description

Get the hierarchy node corresponding to the given entity id.

This method will loop through all Unity.Hierarchy.IHierarchyEntityIdConverter handlers and return the first valid hierarchy node. It is more efficient to call Unity.Hierarchy.IHierarchyEntityIdConverter.GetNodes when multiple entity ids need to be converted.