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

Method HasActorInHierarchy

Source/Engine/Level/Actor.cpp:1657–1674  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1655}
1656
1657bool Actor::HasActorInHierarchy(Actor* a) const
1658{
1659 bool result = false;
1660 if (Children.Contains(a))
1661 {
1662 result = true;
1663 }
1664 else
1665 {
1666 for (int32 i = 0; i < Children.Count(); i++)
1667 {
1668 result = Children[i]->HasActorInHierarchy(a);
1669 if (result)
1670 break;
1671 }
1672 }
1673 return result;
1674}
1675
1676bool Actor::HasActorInChildren(Actor* a) const
1677{

Callers 3

ApplyAllMethod · 0.80
SpawnPrefabMethod · 0.80

Calls 2

ContainsMethod · 0.45
CountMethod · 0.45

Tested by

no test coverage detected