0% found this document useful (0 votes)
843 views17 pages

How To Make A Football Game in Scratch: Instructables

This document provides step-by-step instructions for making a simple 2-player football (soccer) game in Scratch. The game allows two players to control sprites using keyboard arrows to move the ball toward goals on opposite sides of the screen. Over 16 steps, it describes how to code the player sprites, ball, goals, and score tracking. Customization ideas are provided at the end to encourage readers to get creative with additional elements.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
843 views17 pages

How To Make A Football Game in Scratch: Instructables

This document provides step-by-step instructions for making a simple 2-player football (soccer) game in Scratch. The game allows two players to control sprites using keyboard arrows to move the ball toward goals on opposite sides of the screen. Over 16 steps, it describes how to code the player sprites, ball, goals, and score tracking. Customization ideas are provided at the end to encourage readers to get creative with additional elements.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

instructables

How to Make a Football Game in Scratch

by A_J_M

Have a good day friends. Today i am going to share you how to make a Football (soccer) game in scratch. It is a advanced
scratch tutorial, but even if you are a beginner you can make this project if you just follow my instructions. This is my rst
instructuble so please support.

What type of game is it ?

It is a pretty simple game. It is a 2 player game. You have 2 player Red and Blue ( of course you can change the colors. )
They will be shooting a ball to the goal. you can control it by the arrow keys and wasd keys.

You can check it out here :-https://scratch.mit.edu/projects/471356367

Supplies:

All the supplies you need is

A computer/ laptop/ mobile( I am not sure. )


Internet connection
Some time
Patience

Step 1: How to Open Scratch

How to Make a Football Game in Scratch: Page 1


You can do this in 2 ways, you can download the o ine your browser. Isn't it fascinating. This is the link to there
version of scratch from their o cial website. We are website :-https://scratch.mit.edu/
using the latest version of scratch which is scratch 3. You
can do this even in older versions. Scratch 3 is available Click in the create button. It will take some time for
for both windows and mac. Both the older versions (1 & loading. If you want to publish your work in the scratch
2) is available in Linux also. I am a Linux user and I want community you need to create an account which is
the latest version of scratch I am using their website to pretty simple.
make this game. Yes you can make a game just using

Step 2: Delete Current Sprite

First you need to click on the sprite. Click on costume. delete the current costumes.

Step 3: Create Your First Sprite

Convert the costume window to bitmap. Draw a circle using the red circle draw tool. Draw 2 white eyes using the paint

How to Make a Football Game in Scratch: Page 2


tool.

Step 4: First Codes............

Go to code window. Drag down the 'when ag clicked' new variable. rst one is redspeedX and the redspeedY.
block. Here is a tip:- when you cannot nd where a Now you need to place list of block under the 'when ag
block is look it's color and go to the panel of the clicked' block. I had put the photo of the codes above.
color, and you will nd that block in there. you need Just look at codes and be a copycat.
to create some variables. go to variables panels. click on

How to Make a Football Game in Scratch: Page 3


Step 5: Making the Football

Hover the mouse above the create new sprite and click on paint. Convert it to bitmap. select the circle tool and select the
outline. change ll colour to black. Daw a circle and ll it with white color.

How to Make a Football Game in Scratch: Page 4


Step 6: Back to Coding

Click sprite one. And do the coding just like shown in the second photo. We using the 'w,a,s,d' keys to control the read
ball. Try controlling the red ball with 'w,a,s,d' keys, isn't it smooth.

How to Make a Football Game in Scratch: Page 5


Step 7: Shrink......................

we are going to shrink the ball and the sprite. set the size to 50 or any other number you want.

How to Make a Football Game in Scratch: Page 6


Step 8: More Codes an Broadcasting

Add the blocks shown in the rst image. and then click on new message in broadcast. change it to 'redpoint'.

then go to variable make a new variable named 'balldirection'. create another variable called 'ballspeed'. And drop down
the codes done in the last image just above.

How to Make a Football Game in Scratch: Page 7


Step 9: Creating the Blue Player

The blue player is identical to the red player,I am simply duplicating the red player.

then create a new variables named bluesppedx and bluespeedY.

to change the color, go to costume change the color to blue.

Go to codes and change the codes as shown as in the last image.

How to Make a Football Game in Scratch: Page 8


Step 10: Coding the Ball Again

Duplicate code from 'if touching sprite 1 then'. delete last two block. and place the duplicated code over the last 2 blocks

How to Make a Football Game in Scratch: Page 9


of the main code. Now we are going to change the dupliccted codes . change sprite 1 to sprite 3. change broad cast
redpoint to bluepoint. change'ball direction' to sprite 3.

Check your code with the last image above.

How to Make a Football Game in Scratch: Page 10


Step 11: Coding Again..........
How to Make a Football Game in Scratch: Page 11
go to sprite 1 (red) and the codes in the rst image above. then go to sprite 3(blue) and drag the blocks shown in image
2.

Step 12: Adding Backdrop

okay now we are going to add the football eld to this game. yes we are adding the backdrop. Download the image from
this link:- https://drive.google.com/ le/d/0B4DzEoZJ4i8KdGV3Y...

click on the upload backdrop option as shown in the picture. select the downloaded image.

Step 13: Adding Goals

How to Make a Football Game in Scratch: Page 12


Go to code window and click on sprite 2 (football). Then codes shown in the second last image. duplicate the
add the codes shown in the second image.and click in code and make the changes as shown in the last image.
color icon in the 'if touching color' block. select the color Make sure the color of our sprites and the color of your
picking tool and click on the blue color as shown in the goal posts are not same. other wise this game will have
third image. Make two variables 'bluescore' and some errors.
'redscore'.we are also making a broadcast, we have done
a broadcast earliear don't you rember it. Add all the

How to Make a Football Game in Scratch: Page 13


Step 14: Coding Again

Go to sprite one (red) and drag the block codes shown in rst image. Go to sprite 3 (blue) and do the codes shown in the
second image. Go to sprite 2 (ball) and do the codes shown in third image.we have done a error in a code in sprite 2 . lets
change that. Like in image 4 change 'x position' to 'direction'.

How to Make a Football Game in Scratch: Page 14


Step 15: Score

Now our game is somewhat completed , but it not look good right. the variables are all over the screen. To hide the
variables, go to variables unmark/untick all the variables except redscore and bluescore. that is our score line. place the
variables in the goal posts like in the image 2. Double click the variables to change it to a di erent format.

How to Make a Football Game in Scratch: Page 15


Step 16: The Rule of CREATIVITY

At last our game game is complete. Hurrah...... friends so thank you. please support me. Special Thanks for
you have just created a football game. Do you know Mcguy for inspiration. De nitely check out his
what is the rule creativity is? If you creative or you want channel:-https://www.youtube.com/channel/UC2MtlTiL
to be creative, don't just copy anything you see add your xWNQAjHyF...
own elements to it, customize it ,then that is what i
called creative. you can add an opening title to this BE CREATIVE
game or a timer or a ending were you can know who
won, anything you want. This was my rst instructuble

How to Make a Football Game in Scratch: Page 16


How to Make a Football Game in Scratch: Page 17

You might also like