Simple Gravity in Scratch

About this lesson

Use a Velocity variable for Simple Gravity.

Step 1
To start, paint a black ground on your backdrop:

Step 2
Make a new "Velocity" variable:

Step 3
Now, add this code to your cat sprite. Here, we are adjusting the velocity when the cat jumps and lands.

Step 4
Awesome! Now add this code to the cat sprite. This code will make the cat move Left and Right.

Step 5
That's it! It will work like this:

Step 6
OPTIONAL: We can animate the cat's legs to move when he goes Left or Right.

Simple Gravity in Scratch Info


MVCode Clubs

Created By

Matie matie

Access Level


For Teachers and Schools

Teach coding to your students with MVCode Teach

MVCode offers an integrated product designed to teach coding to students.

Learn more about MVCode Teach