Sky Zone Omega - PC Version
 All Classes Namespaces Files Functions Variables Macros
EE_Archer.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <SDL.h>
4 #include "..//Base/EB_VelocityAnimated.h"
5 #include "../../Core/C_Vec2.h"
6 #include "../../Core/C_Timer.h"
7 
13 {
14 public:
23 
27  ~EE_Archer();
28 
33  void update(float dt);
34 
39  void setDeadStatus(bool dead);
40 
45  bool getDeadStatus();
46 
52 
57  bool getDeathParticles();
58 
63  void setCoinSpawn(bool coinSpawn);
64 
69  bool getCoinSpawn();
70 
75  void setFireArrow(bool fireArrow);
76 
81  bool getFireArrow();
82 
87  void decreaseHealth(int damage);
88 
89 private:
91  bool dead;
93  bool coinSpawn;
97  bool fireArrow;
99  int health;
100 
105  void animate(float dt);
106 };
int health
The health of the Archer.
Definition: EE_Archer.h:99
void setDeathParticles(bool deathParticles)
Sets the value of deathParticles.
Definition: EE_Archer.cpp:39
bool getDeadStatus()
Returns the value of dead.
Definition: EE_Archer.cpp:34
bool getDeathParticles()
Returns the value of deathParticles.
Definition: EE_Archer.cpp:44
void setDeadStatus(bool dead)
Sets the value of dead.
Definition: EE_Archer.cpp:29
Contains the data and functions for the Archer.
Definition: EE_Archer.h:12
bool getCoinSpawn()
Gets the value of the coinSpawn boolean.
Definition: EE_Archer.cpp:54
bool deathParticles
A boolean for if the Archer should spawn particles upon death.
Definition: EE_Archer.h:95
C_Vec2 dimensions
The dimensions of the Entity.
Definition: EB_Entity.h:94
void setCoinSpawn(bool coinSpawn)
Sets the value of the coinSpawn boolean.
Definition: EE_Archer.cpp:49
Contains the Vec2 structure with functions and overloaded operators.
Definition: C_Vec2.h:7
An Entity that contains velocities and uses a spritesheet for animation.
Definition: EB_VelocityAnimated.h:10
EE_Archer(C_Texture *sprite, C_Vec2 pos, C_Vec2 dimensions, float *universalSpeed)
Constructs the Archer object.
Definition: EE_Archer.cpp:3
void update(float dt)
A function that updates the Archer.
Definition: EE_Archer.cpp:13
C_Vec2 pos
The position of the Entity.
Definition: EB_Entity.h:92
void setFireArrow(bool fireArrow)
Sets the value of the fireArrow boolean.
Definition: EE_Archer.cpp:59
bool dead
A boolean for if the Archer is dead and to be deleted.
Definition: EE_Archer.h:91
C_Texture * sprite
A pointer to the Entity Texture.
Definition: EB_Entity.h:90
void animate(float dt)
Animates the sprite of the Archer.
Definition: EE_Archer.cpp:80
bool coinSpawn
A boolean for if the Archer should turn into coins on death.
Definition: EE_Archer.h:93
void decreaseHealth(int damage)
Decreases the health of the Archer.
Definition: EE_Archer.cpp:69
bool fireArrow
A boolean for if the Archer should fire an arrow.
Definition: EE_Archer.h:97
bool getFireArrow()
Gets the value of the fireArrow boolean.
Definition: EE_Archer.cpp:64
~EE_Archer()
Destructs the Archer object.
Definition: EE_Archer.cpp:9
float * universalSpeed
A pointer for the universal speed of the game.
Definition: EB_Entity.h:98
Creates a Texture for use with a renderer.
Definition: C_Texture.h:13