Projectile Library

Committer:
ll14c4p
Date:
Tue May 02 16:24:52 2017 +0000
Revision:
6:70b35ebfa8c8
Parent:
4:977109f7b9f6
Child:
9:64ba68ae2640
Added Set Position;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
ll14c4p 0:6914458c54cd 1 #ifndef PROJECTILE_H
ll14c4p 0:6914458c54cd 2 #define PROJECTILE_H
ll14c4p 0:6914458c54cd 3
ll14c4p 0:6914458c54cd 4 #include "mbed.h"
ll14c4p 0:6914458c54cd 5 #include "N5110.h"
ll14c4p 0:6914458c54cd 6 #include "Gamepad.h"
ll14c4p 2:b079859c59ba 7 #include "Player.h"
ll14c4p 0:6914458c54cd 8
ll14c4p 0:6914458c54cd 9 class Projectile
ll14c4p 0:6914458c54cd 10 {
ll14c4p 0:6914458c54cd 11 public:
ll14c4p 0:6914458c54cd 12 Projectile();
ll14c4p 0:6914458c54cd 13 ~Projectile();
ll14c4p 4:977109f7b9f6 14 void init(int playerx, int playery);
ll14c4p 1:2aee0cb1ebf9 15 void draw(N5110 &lcd);
ll14c4p 1:2aee0cb1ebf9 16 void set_velocity(Vector2D v);
ll14c4p 1:2aee0cb1ebf9 17 Vector2D get_velocity();
ll14c4p 1:2aee0cb1ebf9 18 Vector2D get_pos();
ll14c4p 1:2aee0cb1ebf9 19 void update();
ll14c4p 2:b079859c59ba 20 int playerx;
ll14c4p 2:b079859c59ba 21 int playery;
ll14c4p 4:977109f7b9f6 22 int _playerx;
ll14c4p 4:977109f7b9f6 23 int _playery;
ll14c4p 6:70b35ebfa8c8 24 void set_pos(Vector2D p);
ll14c4p 0:6914458c54cd 25
ll14c4p 0:6914458c54cd 26 private:
ll14c4p 3:70c599d9f191 27 int m;
ll14c4p 1:2aee0cb1ebf9 28 Vector2D _velocity;
ll14c4p 1:2aee0cb1ebf9 29 int _size;
ll14c4p 1:2aee0cb1ebf9 30 int _x;
ll14c4p 1:2aee0cb1ebf9 31 int _y;
ll14c4p 2:b079859c59ba 32
ll14c4p 0:6914458c54cd 33 };
ll14c4p 0:6914458c54cd 34 #endif