Parent turtle

parent

Returns a turtle which created the current turtle. Note: causes an error if called in context of the #first turtle.

Example:

"t := (newturtles 3)
print children
foreach "i children [print parent @ :i]

Output:

[t1 t2 t3]
first
first
first

See also:

Turtle - object
children - list of child turtles

Table of Content