Yang Zhenye 201199680

Dependencies:   mbed

Ball/Ball.h

Committer:
yangzhenye
Date:
2020-04-28
Revision:
1:74f525027af6
Child:
5:fcad75e9b9e1

File content as of revision 1:74f525027af6:

#ifndef BALL_H
#define BALL_H

#include "mbed.h"
#include "N5110.h"
#include "Gamepad.h"
 
class Ball
{

public:
    Ball();
    ~Ball();
    void init(int size,int speed);
    void draw(N5110 &lcd);
    void update();
    void set_velocity(Vector2D v);
    Vector2D get_velocity();
    Vector2D get_pos();
    void set_pos(Vector2D p);
    
private:

    Vector2D _velocity;
    int _size;
    int _x;
    int _y;
};
#endif