Ben Evans / Mbed 2 deprecated Defender_Game

Dependencies:   mbed

People/People.h

Committer:
evanso
Date:
2020-05-14
Revision:
33:7fedd8029473
Child:
34:85ccc16f24d2

File content as of revision 33:7fedd8029473:

#ifndef PEOPLE_H
#define PEOPLE_H
 
// Included libraries ----------------------------------------------------------
#include "mbed.h"
#include "N5110.h"
#include "Gamepad.h"
#include "Position.h"

/** People class
 * @brief Draws people and moves them if collected by aliens
 * @author Benjamin Evans, University of Leeds
 * @date May 2020
 */ 
class People: public Position {
    public:
        /** Constructor */
        People();
        
        /** Destructor */
        ~People();
        
        /** Initalises Alien 
         * @param position_x_start @details Random x start pos of people
         */
        void init(Gamepad &pad, int position_x_start);
        
        /** Draws the people
         * @param lcd @details N5110 object
         */
        void draw_people(N5110 &lcd, Direction d_);
    
    // Accessors and mutators --------------------------------------------------
    
        
    private:
    // Function prototypes -----------------------------------------------------
    
        /** Calulates the people movement depeding on spaceship positions and 
         * joystick input 
         * @param d_ @details : Direction object of joystick
         * @retrun integer @details move alien value for alien draw function 
         */
        int calc_people_movement(Direction d_);
        
    // Variables ---------------------------------------------------------------
         
 
        
};
 
#endif