Transform

Transform (Unity3D API Documentation)

Transforms are one of the two fundamental, complimentary 'things' that make up all objects in Unity. Transforms are components, but they're special components, they dictate the position, rotation, size, parent, and children of all GameObjects.

Transforms are also the targets we use in many properties or functions, like TransformPoint for example.

Usage example:

ourGameObjectReference.transform:TransformPoint(Vector3(0.5,1.5,0))

Parenting
A Transform may be 'parented' to another Transform so that they act as a single object, using

transform.parent = theTransformToParentTo which will parent the child using the current vector between the child and parent as the local position. Alternatively may be used.

A Transform may only have one parent, but may have any number of children.

To get the parent of a transform, use

theParent = transform.parent

To get a child of the transform, you can either fetch it by index using

theChild = transform:GetChild(index) or by name

theChild = transform:Find("theChildName")

To get the number of children a transform has, use

numberOfChildren = transform.childCount

To get the sibling index of a transform, use

siblingIndex = transform:GetSiblingIndex (A Transform's sibling index is its child position in the parent transform. For example, if GetSiblingIndex in a child transform returns 5, running GetChild(5) on the parent will return the child in question.)