Final Project Doc
Shooting Game
User Part
1. Start Program 2. Display Controls (`w`, `a`, `s`, `d`, `l`, `esc`, etc.) 3. Move `player unit` around the board and destroy your enemies and try not to get hit 4. When you loose all the health gauge display your `final score` and `rank` 5. Display the Greeting Screen and go to 1.
Programmer Part
1. Start Program 2. Use `w`,`a`,`s`,`d` to move the `player unit` 3. Press `l` to shoot the bullet 4. Use 'esc' to open the option menu 5. If the `player unit` is hit by enemy's attack * Decrease the health gauge * If there is no health left - End the game - Record the score to offline DB * Reset the location and status of `player unit` * Apply penalty in score 6. If the enemy is hit by `player unit's` Bullet * Illuminate the hit enemy * Make Bullet disappear * Increase the score 7. If there are no enemy left * Increase the Level * Locate new enemies 8. Display the `Real-time` Ranking * Update the ranking when every hit occurred
Pseudocode part
1. Start Program * Set the basic settings * Print the starting screen -Show how to play the game * Show the loading screen * Read the offline DB and load the ranking to the structure array do { a) If keyboard is hit * If the key pressed is one of `w`,`a`,`s`,`d` - Move the player unit in the area of the boundary * If the key pressed is `l` - Shoot the bullet from the location of the `player unit` * If the key pressed is 'esc' - Display the option of the game b) If the `player unit` is hit by enemy's attack * Decrease the health gauge * If there is no health left - End the game - Record the score to offline DB * Reset the location and status of `player unit` * Apply penalty in score c) If the enemy is hit by `player unit's` Bullet * Illuminate the hit enemy * Make Bullet disappear * Increase the score * If there are no enemies left - Increase the Level - Locate new enemies d) If it's specific enemy's tern to shoot * Shoot the bullet * Set the cool-time timer for specific enemy to shoot bullet again e) Decrease the cool-time timer by 1 f) Display the `Real-time` Ranking * Update the ranking when every hit occurred } while (health gauge is not empty)
Flowchart part
Due Dates
■Fix error of player shooting basic bullets: May 31st■Fix errors of enemy shooting bullets: May 31st■Make enemy to move: June 10th■Display Health gauge: June 5th■ Create the option tab: June 8th ■Create the user manual & tutorials: June 14th■ Fix other errors: June 14th
Done
■ Fix error of player shooting basic bullets ■ Fix errors of enemy shooting bullets ■ Display Health gauge ■ Create the user manual & tutorials ■ Make enemy to move(Partly done) ■ Real-time Ranking ■ File I/O for the offline DB ■ Make enemy bullets to move in angles(Linear function) (partly done)
Nice to have
■Real-time Ranking■ Add player name input Part ■File I/O for the offline DB■Make enemy bullets to move in angles(Linear function)
Testing Chart
Test Date | Test Name | Input | Expected Output | Actual Output | Remark |
---|---|---|---|---|---|
June 13 | Moving Player Up | Keyboard Hit (w) | Move Player up until the height limitation on the array and screen | Move Player up until the height limitation on the array and screen | PASS |
June 13 | Moving Player Left | Keyboard Hit (a) | Move Player left on the array and screen | Move Player left until the end of the map on the array and screen | PASS |
June 13 | Moving Player Down | Keyboard Hit (s) | Move Player down on the array and screen | Move Player down until the end of the map on the array and screen | PASS |
June 13 | Moving Player Right | Keyboard Hit (d) | Move Player right on the array and screen | Move Player right until the end of the map on the array and screen | PASS |
June 14 | Player Shooting type1 Bullet | Keyboard Hit (L) | Player Shoots bullet and moves on the array and screen | Player Shoots bullet and moves on the array and screen | PASS |
June 15 | Enemy Type5 Shooting Bullet | Not Required | Type5 Enemy(%) Shoots bullet down on the array and screen | Type5 Enemy(%) Shoots bullet down on the array and screen | PASS |
June 15 | Enemy Type5 Moving | Not Required | Type5 Enemy(%) moves down randomly on the array and screen | Type5 Enemy(%) moves down randomly on the array and screen | FAIL |
June 16 | Losing Score when Hit | Not Required | Player loses 25% of the total score when it gets hit by Type5 Bullet(@) has shot | Player loses 25% of the total score when it gets hit by Type5 Bullet(@) has shot | PASS |
June 16 | Gets Score when Enemy Type5(%) is Hit | Not Required | Player gets 15 point when Enemy Type5(%) gets hit by Player's Bullet(|) | Player gets 15 point when Enemy Type5(%) gets hit by Player's Bullet(|) | PASS |
June 16 | Gets Score when Enemy Type7(&) is Hit | Not Required | Player gets 25 point when Enemy Type7(&) gets hit by Player's Bullet(|) | Player gets 25 point when Enemy Type7(&) gets hit by Player's Bullet(|) | PASS |
June 24 | Enemy type7 determine the path of the Bullet | Not Required | Enemy Type7(&) Calculates the linear function of the bullet to hit the player | Enemy Type7(&) Calculates the linear function of the bullet to hit the player | PASS |
June 24 | File IO for DB | Not Required | Open the correct DB file and loads the ranking data | Open the correct DB file and loads the ranking data | PASS |