0% found this document useful (0 votes)
18 views25 pages

CL4 - CH2 - Drawing A Square 2

The document discusses drawing shapes in PictoBlox. It explains what shapes are, prepping the stage by choosing a backdrop and deleting sprites. It introduces pen extension blocks for drawing and provides examples of using blocks like pen down, move and turn to manually draw a square. The activity asks the reader to create a script using repeat blocks to automate drawing the square using the same blocks.

Uploaded by

shubhamvats078
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views25 pages

CL4 - CH2 - Drawing A Square 2

The document discusses drawing shapes in PictoBlox. It explains what shapes are, prepping the stage by choosing a backdrop and deleting sprites. It introduces pen extension blocks for drawing and provides examples of using blocks like pen down, move and turn to manually draw a square. The activity asks the reader to create a script using repeat blocks to automate drawing the square using the same blocks.

Uploaded by

shubhamvats078
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 25

Drawing a Square

Session 2

1
Recap

2
What is a Program?

• A program is a set of instructions that a


computer follows to complete a task.

• The computer receives the information,


handles it, utilizes it and then gives an
output based on it by following a
program.

3
What is a Program?

Programming consist of three parts:

• Planning the program


• Writing the program in a
programming language into a code

• Testing and debugging the program

4
PictoBlox Interface

5
What is Backdrop?

6
Backdrop

• A backdrop is one out of possibly


many frames, or backgrounds of
the Stage.

• The Stage can change its look to any


of its backdrops.

7
Choosing a Backdrop

• You can choose a backdrop from the


backdrop library.

• Uploading a file from the computer.

• Creating one using the paint editor.

• Click on the backdrop library and


select any backdrop.

8
Changing the Backdrop
• Click on Choose the Backdrop and select forest as backdrop.

9
What is Costume?

10
What is Costume?
• A costume is one out of possibly many
“frames” or alternate appearances of
a sprite.
• Sprites can change their look to any of
its costumes.
• Every sprite must have at least one
costume.
• One of the most common uses of
costumes is to make an animation for a
game or other project.
• Available costume for the sprite are
shown on the left side in Costumes tab.

11
Costumes Tab

12
How to create costumes?
There are four main ways of getting a
costume or background for a sprite
or stage.
• From the costume library.
• Drawing one yourself using the
inbuilt Scratch Paint Editor, by clicking on
the costume and clicking the “paint”
button
• Getting an image or multiple images
that exist as files on the computer.
• Taking an image from a webcam,
by clicking the “camera” button.

13
Another cool thing that you can do in PictoBlox
other than creating animations is drawing
shapes. Let explore it in this lesson.

14
What are Shapes?

A shape is an external form, boundary,


or outline of an object. Some of the
common shapes are:
• Circle
• Rectangle
• Square
• Triangle
• Oval
• Star
• Diamond
• Pentagon
15
Prepping the Stage for Drawing

• Click on the File button and select New


to open a new project.

• First, we will set the Backdrop. Choose


the Xy-grid backdrop from the
Backdrop library.

16
Prepping the Stage for Drawing

• In the sprite palette, you’ll see both


Tobi and the pencil. Select Tobi and
right-click on him. In doing so, a menu
will drop down.

• Click on ‘delete’.

17
Pen Extension

• To draw anything with the pen, we will


need pen extension blocks.

• Click on the Add Extension button.

• Then, click on the Pen extension to add


use the blocks.

18
Pen Extension Blocks
We will be using the following blocks
from the pen extension in the next topic.

• When you run the pen down block, you


enable a mode where, whenever the
sprite moves, it will draw lines on the
stage.

• When you run the pen up block, you


enable a mode where the sprite does
not draw while moving. To erase all the
lines, we will use erase all block.

19
Making the Square Manually

• Click the pen down block.

• Then, click the move 100 steps


block.

• Next, click the turn clockwise 90


degrees block.

• Repeat steps 2 & 3 three more


times.

20
Activity : Let’s make a Square
Using script

21
• Now, let's create the script to draw the
square by stacking all the blocks
together.
ACTIVITY

• To draw the square, you had to click each


of the 3 blocks 4 times.

• To make a script that does the same, you


need to add all 3 blocks in the given
sequence 4 times!

22
• You can simplify all this by using a repeat
block. Just add it around the 3 blocks and
write 4 in the space.
ACTIVITY

• Place a pen down block above the repeat


block to draw the square and place a
when () key pressed block above the
entire script. That's it.

23
Final Output
• Click the Green Flag to run the script.
ACTIVITY

24
25

You might also like