Getting a Child Object by Name from a Parent Object

Orx provides a pair of functions for finding objects in an object hierarchy by name. The two functions are orxObject_FindChild and orxObject_FindOwnedChild. These functions will filter out any camera or spawner and retrieve the child matching the provided path.

Paths

Paths are composed by object names separated by .. A wildcard can be used * instead of a name to find children at any depth inside the hierarchy, using depth-first search. Lastly, C subscript syntax, [N], can be used to access the N+1th (indices are 0-based) object matching the path until there.

For example: