Hardware Reference
In-Depth Information
block repeat under the pen down block to contain the motion blocks and
change the value to 5 (see Figure 4-3).
3. Click the green lag to test that your turtle will draw a pentagon.
4. Click File Save As to save your changes.
A
The turtle can turn 360 degrees in a circle, either left or right. This helps you draw
shapes. For example, to draw a square you would change the value of degrees to
90 to get the right-angled turn needed before drawing the next line.
FIGURE 4-3 he Turtle pentagon script in Scratch
CHALLENGE
If the value of steps and the value of degrees to turn were set to 1, and the
repeat value set to 360, what shape do you think the turtle would draw?
Now that you have created a pentagon shape, how could you go about making
a hexagon shape, or an octagon shape?
Search WWH ::




Custom Search