Action: attach(target, parent)

Related Actions: glue, detach, letchild, letparent, letsibling
Related Events: detached
See also: FKiSS, Events, Actions

attach(target, parent)

First defined in: FKiSS4
The attach action attaches target to parent, becoming a child object of parent. If target was already attached to an object, it is first detached from that object, triggering a detached event if necessary.
An object which is attached will move with its parent object. It can be detached with the detach action or by the user moving the child object.

target

may be an object number or a variable representing an object number.

parent

may be an object number or a variable representing an object number.

Example:

;@ attach(#5, #10)
;@ attach(VarEgg, VarBasket)