Final Project Proposal

HAILSTORM HAIVOC CONTINUED

Concept for the project

For my final project, I am building on my midterm project, which involves a game where players dodge falling hail. Initially, I had envisioned this game with a car maneuvering to avoid the hail, but the concept became too complex. Through trial and error, I simplified the gameplay to where players now use the mouse click to move the car away from the hail. This feature unexpectedly also allows control over another sprite, adding a unique twist to the gameplay. Taking this project to the next level, I plan to integrate an arcade button to start and re-start the game and a toy car that players can manipulate/move to control the game car on the screen through a sensor. Differing from the midterm which was consistently playing, my game has an end after a couple seconds of playing where the player would have won and arrived home safely from the storm, and this would enhance the interactive experience and depth of the game.

Description of what your Arduino program will do with each input and output and what it will send to and/or receive from P5:

  1. Inputs:
    • HC-SR04 Ultrasonic Sensor: This sensor will measure the distance of an object from it. It uses two pins, TRIG and ECHO, to send out ultrasonic waves and measure the time it takes for the echo to return.
    • Arcade Button: The button will act as a simple digital input, where pressing the button changes its state from LOW to HIGH.
  2. Outputs:
    • Serial Data to P5: The Arduino program will continuously send two pieces of data to the P5 sketch via the serial port:
      • Distance measured by the ultrasonic sensor, translated into a value that indicates the position of the car on the screen, hopefully when the toy car is moved left (close to the sensor it will move the car on screen left) and vise versa.
      • The state of the arcade button to control game states (start and restart).

Description of what P5 program will do and what it will send to and/or receive from Arduino:

As of my game, I don’t think P5 is going to send anything to Arduino other than:  Serial Data from Arduino: The P5 sketch receives the distance and button state as a serialized string. Game Controls: Based on the received data, the P5 sketch adjusts the position of the car on the screen and manages the game state (starting and restarting).

Leave a Reply