In this video you'll learn how
to use the Print Prepare procedure in your starter project
to print a pattern.
Using the Print Prepare procedure, moves the sprite
across a specified distance.
When the sprite reaches the edge of the stage
it starts again one row up at the left side of the stage.
To use the procedure you'll need to call it,
that means you tell the computer
to follow the list of tasks contained in one procedure
at a specific point in your code.
Go to the more blocks menu, drag out the print prepare block
and place it under the repeat and tell loop
that was included in your starter project.
Enter the number 40 in each of the two value spaces.
These numbers set the distances
the sprites move horizontally and vertically.
To run the code press the one key.
The sprite moves across and up the stage
however it doesn't create a pattern.
That's because the procedure moves the sprite
it doesn't make it stamp.
To stamp the sprite go to the pen menu
and drag out the stamp block
and place it under the print prepare block.
Press one and the sprite will move across the screen
and print a copy of itself as it travels.
But the pattern only prints once.
Nothing happens if you press the one key a second time.
in the next video you'll learn how to create a procedure
to reset the stage allowing the user to reprint the pattern.
Now it's your turn.
Click on the more blocks menu
and drag the print prepare block into the repeat
and tell loop.
Select the pen menu and add a stamp block
under the print prepare procedure.
Press one to see the code print a set of stamps once
then move on to the next video to learn how
to make the pattern print multiple times.
Sign in to save your project and track your progress.