This project involved creating an accessible F1-inspired racing game designed to be fully playable using a single on-screen button or an external switch. The player controls a Mercedes race car and must avoid colliding with a Ferrari opponent, reflecting the known rivalry between the two teams. Pressing the button changes the x-position of the Mercedes moving it between four lanes. To keep the game unpredictable, a clock interval was used to trigger changes in the Ferrari, while a random integer generator determined which lane it would move into. The clock interval was set to 20 seconds to control when the Ferrari would repopulate or change position. This combination of simple input and randomized movement made the game engaging while remaining accessible to users with limited hand dexterity.
The app game was created using MIT App Inventor and its visual block-based programming system. Animated car sprites were placed on the game canvas, with the player car controlled through a single button. The program used if/then/else statements, random integer blocks, initialize global variable blocks, and global variable calls to manage lane positions and game behavior. Clock components controlled timed events, while random number generation determined the enemy car’s movements. Notifier blocks were also incorporated to provide feedback to the player, such as signaling a collision or the end of a race round.
Programming and controlling image sprites by changing their x-position on a game canvas
Using random integer generation to create unpredictable enemy movement for more dynamic gameplay
Learning to create and manage global variables for storing and updating game image sprite states and positions
Integrating Notifier components and single-button input to create a functional, accessible game interface
Blocks of code used to code buttons to code sprite movement, randomization, and game restart.
Designer display of button.
Project Created & Finished: October 1, 2026 from 9am - 12:45pm