![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
Doxygen comments added
Dependencies: mbed Gamepad N5110
Diff: Scoring/Scoring.h
- Revision:
- 11:c85abe88ad7a
- Parent:
- 10:75de0f4da176
- Child:
- 12:736e8561b81e
diff -r 75de0f4da176 -r c85abe88ad7a Scoring/Scoring.h --- a/Scoring/Scoring.h Wed May 08 20:59:02 2019 +0000 +++ b/Scoring/Scoring.h Wed May 08 21:10:18 2019 +0000 @@ -6,34 +6,34 @@ #include "Gamepad.h" class Scoring { - /* Class Scoring + /** Class Scoring @brief Class for counting,updating and checking scores @author Rafeh Ishtiaq @date May 2019 */ public: - /* Constructor */ + /** Constructor */ Scoring(); - /* Destructor */ + /** Destructor */ ~Scoring(); - /* Sets the score + /** Sets the score @param score */ void set_score(int score); - /* Displays the score and high score after the player has lost + /** Displays the score and high score after the player has lost */ void display_score(N5110 &lcd, Gamepad &pad); - /* Boolean function to check weather the score is higher or lower than the high score + /** Boolean function to check weather the score is higher or lower than the high score @param highscore @details The existing high score which is compared to the recent score to check for high score */ bool check_for_highscore(int highscore); - /* updates the Highscore + /** updates the Highscore @param highscore @details The current high score */ void update_highscore(int highscore); - /* Adds to the score if conditions are met (i.e. when bird gets ahead of a pipe) + /** Adds to the score if conditions are met (i.e. when bird gets ahead of a pipe) @param score @details The existing score @param pipe_x @details X coordinate of the pipes @param bird_x @details X coordinate of the position of the bird @@ -42,7 +42,7 @@ */ int add_score(int score, int pipe_x,int bird_x,int pipe_width); - /* Checks for the collision between the bird and the pipes + /** Checks for the collision between the bird and the pipes @param bir_y @details Y coordinate of the position of the bird @param pipe_x @details X coordinate of the pipes @param pipe_height @details Height of the top pipe