Skip to content

Format

typescript
Transform.FindChild(name)

class: Transform

Description

Find the child Transform of the current Transform attached to the game object by its name.

This method searches for the child Transform using a relative path, which means it is relative to the current Transform object.

Parameters

param_nametypedescription
namestringThe name of the child game object attached to the Transform.

Return

typedescription
TransformThe child Transform.

Code Example

typescript
OnStart(): void {
    let transform = this.transform;
    let child = transform.FindChild("childname");
    }