diff options
| author | tom <tom@ground-control> | 2015-11-21 12:30:13 -0600 |
|---|---|---|
| committer | tom <tom@ground-control> | 2015-11-21 12:30:13 -0600 |
| commit | 7f79b2e216617ff74ebd41ac02663b20ef3d0904 (patch) | |
| tree | e0eb8f820c61c45afcb1506f5b025eeb7e534691 /inc/Character.hpp | |
| parent | 032d4f98c809bde6231ff78ba50e8c244334739f (diff) | |
began adding collision *added a location class for ease *much refractoring needed to fully implement it*
Diffstat (limited to 'inc/Character.hpp')
| -rw-r--r-- | inc/Character.hpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/inc/Character.hpp b/inc/Character.hpp index f2753a9..1f948f2 100644 --- a/inc/Character.hpp +++ b/inc/Character.hpp @@ -2,18 +2,28 @@ #define character_h #include <ncurses.h> +#include <cstdlib> +#include <vector> +#include <string> +#include "Location.hpp" +using namespace std; class Character { public: Character(char nSymbol, int nColor,int nRow, int nCol); - void move(int nRow, int nCol); + void move(Location L); void draw(WINDOW * w); + bool action(vector <Location> occupied); + bool check(Location L, vector <Location> occupied); int getRow(); int getCol(); + Location getLocation(){return l;} char getSymbol(); private: + string order = "wander"; + Location l; char symbol; int row; int col; |
