Dear Reader,
I have been working with coding for more than twenty-five yearsfrom when I was just starting eighth grade in Australia. I never took a computer science class in school, so I mostly learned how to code from older kids who already knew how to code. Seeing the computer react to the code I created made me excited and motivated me to learn more. This connection to friends and a personal curiosity led me to building games from a young age, just like you!
Its my pleasure to be able to help other young coders use this tool to dream up and build their own creations. I am pleased to be part of this new wave of computer science resurgence Scratch has helped create. Remember to always be creative. Your path to being a computer scientist will go much farther when you use your inner curiosity. Picture a project that you are passionate about, start your research, make it a reality.
Have fun!
For the powerful girls in my life, Emma, Amelia, and Ayla, and the ever-increasing world of technology that will shape their world.
ACKNOWLEDGMENTS
Thanks to Amelia and Cheryl for all your help reviewing, as well as trying the multitude of Scratch projects and activities.
Id also like to thank Steven for his encouragement and passion along with helping build fun projects and activities.
INTRODUCTION
Why have an entire book on Scratch? Well, Scratch is a great way for kids to learn computer science! It takes learning about geeky coding and makes it fun and creative. Youll learn about computers and coding while building and making your own games! Scratch coding is all about creating projects with passion and peers through play, as Mitchel Resnick, the creator of Scratch, has said in the past.
If you havent played around with Scratch, you dont know what youre missing! Scratching results in some pretty incredible games. A lot of times, you can put just a few blocks together and get a wow moment where you realize you can create whatever you imagine! Scratch makes it really easy for you to learn coding with some simple tools that can do really amazing things.
Why should you learn coding? Well, first of all, its really fun! With coding, you can make anything you want. Someone even made a version of Minecraft using the same Scratch coding youre going to learn about! Plus, it helps you get awesome jobs when youre older. Imagine getting paid to make your favorite video games. Someone has to do it, right? Well, a lot of those video game developers probably first got started learning about computers and coding around your age.
Youll see a lot of examples in this book. Theyre a great way to learn how to code. Once you understand how the example code works, you can make it your own and change it however you like. Thats really important when you are learning to code. Its hard to come up with something from nothing. When you work from an example, you are starting from something that can give you some great ideas to tweak and that will help you create your own masterpiece!
This book is going to teach you exactly how to code in Scratch. It will teach you about all the different blocks and extensions, so youll be a master in no time! Whether youre creating a Scratch project for the first time or you have played around with it before, this book is meant for you. It will teach you a whole bunch of tips and tricks that youll need to take your project to the next level. Think of this book as a jumping-off point so you can take off and soar into the world of Scratch!
BEGIN HERE
THE BASICS OF SCRATCH
Before you learn how to code with Scratch, you need to know where it came from and what each part of Scratch is. You wouldnt be able to prepare a meal without knowing which ingredients you need! Here, youll learn what interfaces, sprites, and blocks are and how theyre used to make awesome games for you and your friends!
Scratchs Beginnings
Scratch was originally created in 2003 by Mitchel Resnick and Seymour Papert at MIT Media Labs Lifelong Kindergarten research group. They wanted to help children of all backgrounds to find and follow their own passions, to explore and experiment with new ideas, to develop and deliver their own voices. By 2007, their new program was ready, and Scratch 1.0 was released.
To make it easy for kids to learn, Dr. Resnick and Dr. Papert decided to make it a visual programming language (VPL). This means you write your code with blocks instead of letters and numbers. This block-coding style is a great beginners coding language because you can experiment with the code and try different combinations with the blocks.
Since all the blocks always do exactly what theyre told, its tough to write code that doesnt work at all. But be careful! Its still very easy to create code that doesnt do what you expect it to do.
Scratch 2.0 Interface
The Different Parts of Scratch
Now that you know where Scratch comes from, lets learn about the modern version of Scratch. There are seven different elements to Scratch that you need to know to get good at coding: the interface, the sprites, the stage, the blocks, the costumes, the backdrops, and the sounds. Lets jump in!
FACT
Interface
The interface controls how a program looks on the screen. A program like Scratch has many coding options you can click on to do different things.
Interface
When you use a program like Scratch, what you see when you go to the website is called its interface . The interface for Scratch will change a little bit over time as new features are made by the Scratch team. This is what the interface for the current version of Scratch looks like. There are three main areas of the interface. The sprite area in the bottom right is for adding different characters and objects to your game. The Scratch workspace area is where youll create your code, adjust costumes, and make any other changes in Scratch. And the stage is where you play your game! The areas wont have these borders in the actual program. This just helps highlight each separate area so you can see each one more easily. A good understanding of how these work together will help you create your projects in no time!
Scratch 3.0 Interface
Sprites
Imagine a game without any characters or objects. That would just be a blank screen! You need something on the screen to have some fun. In Scratch you can add these different characters or objects to your projectsthings like a cartoon character walking around, flying balls or meteors, and even objects in the background like a swaying tree or setting sunset. Scratch calls these characters and objects sprites .