GroIMP Module XL English
Spoken text
The most common geometric form to be generated by the turtle is a cylinder. Its state variables are the length, thickness and color.
The basic command to generate a cylinder is the F0 command. This causes a progression of the turtle with simultaneous drawing without setting an explicit length. This is also shown in the attribute editor where no length specification for the element to be produced is available. The current length for F0 can be determined and changed by the L(x) command, what is shown here. The LAdd(x) and LMul(x) commands cause an addition or multiplication of the current length with x. For a better visibility the color of the cylinder to be drawn is changed by the P(x) command. The actual thickness - or diameter - of the element to be created by F0 can be changed with the D(x) command. Analogous to the length, one can manipulate the diameter by using DAdd(x) and DMul(x).
To move the turtle forward without drawing an element there is the M0 command, which lets the turtle jump to another location, and thus can create a gap within the generated sequence of cylinders.
If you want to specify an explicit length, thickness and color instantly during constructing the element, you can use the F(x,d,c) command instead of the L(x) and the F0 command. Thereby a cylinder with the respective length, diameter, and color is generated directly. It is not necessary to enter all parameters. It is also sufficient to define only the length and the diameter or the length only. These values are listed as parameters or attributes of the object in the attribute editor.
In addition to the cylinder, more geometric primitives can be drawn by the turtle. If you add the command "Box" with a length, width and height, a box is drawn after the cylinder. This shows once again very well the principle of turtle geometry: After drawing the cylinder the position of the turtle is at the end of it, with the result that the box is directly drawn attached to the cylinder by the new command. If you additionally draw a sphere of a given diameter, this becomes even clearer. The center of the sphere is equal to the current position of the turtle.