diff options
author | drumsetmonkey <abelleisle@roadrunner.com> | 2015-09-28 10:51:18 -0400 |
---|---|---|
committer | drumsetmonkey <abelleisle@roadrunner.com> | 2015-09-28 10:51:18 -0400 |
commit | 34e2794d647447f6ddb29419abbe2f44593ba1fa (patch) | |
tree | 7883ce4c783fc02923ed3312ef7d0715aa4a43a8 /include/entities.h | |
parent | 7125200e83a9255b8da6745b4a457996705bf263 (diff) |
Commented Entity Class, added more to debug screen, and changed colors of objects
Diffstat (limited to 'include/entities.h')
-rw-r--r-- | include/entities.h | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/include/entities.h b/include/entities.h index df81ad2..53a8057 100644 --- a/include/entities.h +++ b/include/entities.h @@ -6,25 +6,31 @@ class Entity{ public: void *inWorld; - float width; + float width; //width and height of the player float height; - float speed; + float speed; //speed of the play + //type and subtype int subtype; _TYPE type; - vec2 loc; + //example: + //type 1(NPC) + // |(subtype) + // |-> 0 Base NPC + // |-> 1 Merchant + vec2 loc; //location and velocity of the entity vec2 vel; - bool right,left, canMove; - bool alive; - unsigned char ground; + bool right,left, canMove; //movement variables + bool alive; //the flag for whether or not the entity is alive + unsigned char ground; //variable for testing what ground the entity is on to apply certain traits - unsigned int texture[]; + unsigned int texture[]; //TODO: ADD TEXTURES void spawn(float, float); void draw(void); void wander(int, vec2*); virtual void interact(){} private: - int ticksToUse; + int ticksToUse; //The variable for deciding how long an entity should do a certain task }; class Player : public Entity{ |