Ball Toss Game and Bowling with Rigid Bodies! Andrew Acosta
Introduction
For my final project in CPE 500 during Spring Quarter 2015, I choose to create two games: one where you toss a ball to knock down stacked cans and one for bowling! These games both use the rigid body system we discussed in class, as well as friction!
The program has 3 game settings to represent the two game modes and a demo of the rigid body system. The mode setup on start is the demo mode. This has three boxes that fly at up toward the middle and hit each other. This is to show the rigid body contact, and let the player mess with controls. The ball toss game can be started with R, and the bowling game can be loaded with F.
The final product of the program can be seen in the video below:
Controls Throw Controls
Use these controls to throw the ball and setup the throw variables. The current state of the variables are printed to the terminal.
  • W - Adjusts the aim to be higher
  • S - Adjusts the aim to be lower
  • A - Rotates aim to the left
  • D - Rotates aim to the right
  • O - Decrease throw strength up to 5
  • P - Incrase throw strength up to 25
  • Q - Increases the spin on the X axis
  • E - Decreases the spin on the X axis
  • Z - Increases the spin on the Y axis
  • C - Decreases the spin on the Y axis
  • T - Throws the ball based on the throw variables
Switching Games
These controls are used to switch the game setup. It will also remove all of the balls thrown.
  • R - Toggles if in segment mode.
  • F - Selects the teal segment
Conclusion Things to Work On
The biggest issue with this program is that it uses bounding boxes and not bounding cylinders. The cans and bowling pins would have been much better as cylinders. Also, the shader has issues, but I never fixed it because it works well enough and the emphasis is on the physics anyway.