Welcome to the world of Scratch, where you can make stories, animations, games, and art! Today, we’re exploring a very cool feature in Scratch called the Pen Tool. With the Pen Tool, you can make your sprites draw amazing shapes and patterns directly on the Stage. Let’s dive in and see how it works, and then we’ll try making some cool shapes and patterns together!
What is the Pen Tool?
The Pen Tool is like giving your sprite a magic pencil. With it, your sprite can draw lines, doodles, shapes, and patterns as it moves around the Stage. You can choose the color, thickness, and even make rainbow-like effects with the Pen Tool. It’s a lot of fun and great for learning how to code by drawing!
How to Find the Pen Tool in Scratch
To use the Pen Tool, you first need to add the Pen Extension to your project. Here’s how to do it:
- Open your Scratch project.
- Look in the bottom-left corner of your screen for the blue button with a plus sign that says Add Extension.
- Click on it, and you’ll see different extensions pop up. Select the Pen Extension (it has a little paintbrush icon).
Now, you’ll have new blocks in the Pen category, which you can find in the Blocks Palette on the left side of your screen!
Getting Started with Pen Blocks
Here are some of the main blocks in the Pen Extension and what they do:
- Erase All: Clears everything drawn on the screen.
- Pen Down: Puts the pen down, allowing your sprite to start drawing as it moves.
- Pen Up: Lifts the pen up so your sprite can move without drawing.
- Set Pen Color to [color]: Changes the color of the pen.
- Change Pen Color by [number]: Gradually changes the pen color for cool effects.
- Set Pen Size to [number]: Changes the thickness of the lines your sprite draws.
- Change Pen Size by [number]: Increases or decreases the pen size by a certain amount.
Finding Angles for Shapes
To make shapes, your sprite needs to turn the right angle at each corner. The angle depends on how many sides the shape has. You can use this simple formula to figure it out:
Turn Angle = 360° ÷ Number of Sides
Here’s how it works for common shapes:
For example, to make a triangle, use a turn angle of 120° because a triangle has 3 sides. A square has 4 sides, so use 90°. This formula works for any shape!
Let’s Draw a Square with the Pen Tool!
Let’s start with a simple shape: a square. We’ll write a script to make our sprite draw a square. Follow these steps:
- Choose a sprite, like the Cat or any other character you like!
- Add the following blocks to your sprite’s code area:
- Click the green flag to run your code. You should see your sprite draw a square!
Drawing a Triangle
Ready to try another shape? Here’s how to make your sprite draw a triangle:
- Erase your previous drawing with Erase All.
- Change the code to create a triangle shape by changing the number of repeats and the angle the sprite turns.
- Run the code and watch your sprite draw a triangle!
Creating Patterns with the Pen Tool
Now that we know how to draw basic shapes, let’s make a pattern! Patterns are created by repeating shapes in a specific way. We’ll draw a simple square pattern by turning and drawing lines.
- Erase all with Erase All to start fresh.
- Try the following code:
- This code will draw a square pattern! Experiment with changing the angle in the “Turn” block and the number of repeats to see what kind of designs you can create.
Tips for More Advanced Patterns
- Change colors within a loop to make rainbow patterns.
- Change pen size for thicker and thinner lines in your patterns.
- Try different shapes like hexagons, stars, or even letters!
Challenge: Design Your Own Patterns!
Now that you know the basics, try creating your own patterns! Experiment with different shapes, pen colors, and pen sizes. You could make flower patterns, stars, spirals, or anything you can imagine. Just remember to have fun and keep trying new things!
With the Pen Tool in Scratch, there’s no limit to the shapes and patterns you can create. Each project lets you build a new design and learn more about coding along the way. Enjoy drawing with code, and happy Scratching!





