diff options
Diffstat (limited to 'include/entities.h')
-rw-r--r-- | include/entities.h | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/include/entities.h b/include/entities.h index 1e6d316..412ec42 100644 --- a/include/entities.h +++ b/include/entities.h @@ -43,7 +43,8 @@ enum BUILD_SUB{ HOUSE3 = 3, HOUSE4 = 4, FOUNTAIN = 5, - LAMP_POST = 6 + LAMP_POST = 6, + FIRE_PIT = 7 }; typedef struct { @@ -81,9 +82,12 @@ public: float velx; float vely; Color color; - int duration; + float duration; bool canMove; - Particles(float x, float y, float w, float h, float vx, float vy, Color c, int d){ + bool fountain; + bool gravity; + bool behind; + Particles(float x, float y, float w, float h, float vx, float vy, Color c, float d){ loc.x = (x); loc.y = (y); width = (w); @@ -94,16 +98,22 @@ public: color.green = (c.green); color.blue = (c.blue); duration = d; + fountain = false; + gravity = true; + behind = false; + } + ~Particles(){ + } - ~Particles(){} void draw(){ glColor3f(color.red,color.green,color.blue); glRectf(loc.x,loc.y,loc.x+width,loc.y+height); } bool kill(float delta){ duration -= delta; - if(duration <= 0) + if(duration <= 0.0f){ return true; + } else return false; } }; |