MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / Find

Method Find

Source/Editor/SceneGraph/ActorNode.cs:113–131  ·  view source on GitHub ↗

Tries to find the tree node for the specified actor. The actor. Tree node or null if cannot find it.

(Actor actor)

Source from the content-addressed store, hash-verified

111 /// <param name="actor">The actor.</param>
112 /// <returns>Tree node or null if cannot find it.</returns>
113 public ActorNode Find(Actor actor)
114 {
115 // Check itself
116 if (_actor == actor)
117 return this;
118
119 // Check deeper
120 for (int i = 0; i < ChildNodes.Count; i++)
121 {
122 if (ChildNodes[i] is ActorNode node)
123 {
124 var result = node.Find(actor);
125 if (result != null)
126 return result;
127 }
128 }
129
130 return null;
131 }
132
133 /// <summary>
134 /// Adds the child node.

Callers 15

EndInitMethod · 0.45
UpdateTitleMethod · 0.45
RemoveMethod · 0.45
UpdateFiltersMethod · 0.45
GetCollisionDataMethod · 0.45
OnAddColliderMethod · 0.45
OnSelectMethod · 0.45
ValidateDragActorMethod · 0.45
PasteMethod · 0.45
SelectMethod · 0.45
ApplyExpandedFoldersMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected