Remembrance Day – Procedures

Predict

This code is split into two sections. The main program is on the left and a procedure on the right.
The sprite costumes are on the right of the screen.

Think carefully about each part of the program and what it will do.

Write down what you think it will produce when the Green Flag is clicked


Run

You can run the program by visiting this link on Scratch


Investigate

Thinking about the Pattern procedure,…

  1. Which group of instructions are responsible for placing the red spots?
    Circle them on the code.


  2. Which instruction decides how many red spots are in each pattern?
    Write it here.


  3. Why is the forward 45 instruction needed?
    Write it here.


  4. Why does it turn 90 degrees?
    Write your thoughts here


  5. Which group of instructions are responsible for placing the black spots?


  6. Why does it only turn 45 degrees and just move 25 before stamping?
    Write your ideas here.




  7. What would be a better name for the Pattern procedure?
    Write down your idea


Thinking about the Main Program…

  1. How many of the patterns are drawn by the main program?


  2. Which instruction decides where they will be drawn?



  3. Describe in your own words what the call pattern command does.


  4. What do you think the purpose of the turn 15 instruction is?
    Write your thoughts here.




Modify

These tasks allow you to investigate the program further. It is advisable to remix the project so that you can save your edits.

  1. Change the name of the Procedure to something more appropriate
    What did you change? Write it down.


  2. Change the pattern so that it has 5 equally spaced red spots.
    Write down a list of instructions you changed.



  3. Add an instruction to the start of the procedure which says “Set size to 15%”
    Use instructions like the one below to replace the distances moved in each forward statement.

    Write down what you changed.


  4. Experiment with changing the percentage size.
    What do you think is the smallest or largest number which works well?


  5. Change the “Set size to 15%” command, to use a random size between the numbers you chose in the last question.




Make

Try some of these coding challenges

  1. Make a wreath by making poppies appear all the same size in a circle.

  2. Make a row of 5 poppies appear along the bottom of the screen

  3. Make 2 more rows appear above the rows at the bottom.

  4. Make the size of the poppies be related to the y position (coordinate)
    e.g.


5. Make a field of poppies where those at the bottom which appear closer are larger, and those further away are smaller.