Kostadin Chakarov / Mbed 2 deprecated el17kec

Dependencies:   mbed

GameObject/GameObject.h

Committer:
kocemax
Date:
2019-04-08
Revision:
6:39bda45efeed
Child:
7:cd3cafda3dd4

File content as of revision 6:39bda45efeed:

#ifndef GAMEOBJECT_H
#define GAMEOBJECT_H

#include "mbed.h"
#include "N5110.h"
#include "Gamepad.h"

/** GameObject Class
@author Kostadin Chakarov, University of Leeds
@brief Draws and controls the objects in the Breakout game, which can either be static or non-static
@date April 2019
*/ 

class StaticGameObject
{
public:
    StaticGameObject();
    ~StaticGameObject();
    
    virtual void move();
    virtual void draw(N5110 &lcd);
    const Vector2D& getballPos();
    int getW() { return w; };
    int getH() { return h; };
    
protected:
    int w, h;
    Vector2D ballpos;
};


class GameObject : public StaticGameObject
{
public:
    virtual void move();
    
protected:
    Vector2D velocity;
    
};
#endif