Sunday, August 7, 2022

Car and Driver

   The updownleft, and right arrow keys and a car sprite are all we need to drive a car in Scratch. This project will give you a list of cars (top down view) to choose from and then the code to “drive” the car will be developed in this document.

   There is a Scratch project called Rowdy Rud’s Sprite Pack that can be viewed and downloaded at this link: Rowdy Rud’s sprite pack contains a large number of cars and each car is well drawn.

   Below is a picture of the track (optional) of the car after a test drive.

    Griffpatch ( is a Master Scratch coder and the creator of the following line of code. This line plus a similar line that codes the left and right arrows are at the heart of my Car and Driver project

   If you would like a free PDF document that walks through the code, one by line, send your request by email to:

Things to Do
1. Create sprites as obstacles and use the touching sprite# blocks to detect collisions
2. Add car sounds.
3. Create a sprite parking space and use collision detection to determine if you have parked
    the car correctly.
4. Make a two-player game.
5. Use the arrow key commands in another scenario like a spacecraft.

No comments:

Post a Comment