1 | #ifndef _OrxoBloxWall_H__ |
---|
2 | #define _OrxoBloxWall_H__ |
---|
3 | |
---|
4 | #include "OrxoBlox/OrxoBloxPrereqs.h" |
---|
5 | #include "worldentities/StaticEntity.h" |
---|
6 | #include "tools/Timer.h" |
---|
7 | |
---|
8 | namespace orxonox |
---|
9 | { |
---|
10 | |
---|
11 | /** |
---|
12 | @brief |
---|
13 | |
---|
14 | @author |
---|
15 | |
---|
16 | @ingroup OrxoBlox |
---|
17 | */ |
---|
18 | class _OrxoBloxExport OrxoBloxWall : public StaticEntity |
---|
19 | { |
---|
20 | public: |
---|
21 | OrxoBloxWall(Context* context); //!< Constructor. Registers and initializes the object. |
---|
22 | virtual ~OrxoBloxWall() {} |
---|
23 | // this.destroy(); |
---|
24 | //} |
---|
25 | OrxoBloxStones* getStone(unsigned int i); |
---|
26 | /** |
---|
27 | @brief Set the Health of the stone. |
---|
28 | @param size The dimensions a stone has in the game world. (A stone is a cube) |
---|
29 | */ |
---|
30 | void setHealth(unsigned int health) |
---|
31 | { |
---|
32 | this->totalhealth_ = health; |
---|
33 | } |
---|
34 | |
---|
35 | /** |
---|
36 | @brief Get the size of the stone. |
---|
37 | @return Returns the dimensions a stone has in the game world. (A stone is a cube) |
---|
38 | */ |
---|
39 | unsigned int getHealth(void) const |
---|
40 | { return this->totalhealth_; } |
---|
41 | |
---|
42 | void setGame(OrxoBlox* orxoblox) |
---|
43 | { assert(orxoblox); orxoblox_ = orxoblox; } |
---|
44 | int getNumberOfStones(); |
---|
45 | bool isEmpty(); |
---|
46 | void reduceNumberOfStones(); |
---|
47 | void setNumberOfStones(int number); |
---|
48 | private: |
---|
49 | void createWall(void); |
---|
50 | OrxoBlox* getOrxoBlox(); |
---|
51 | unsigned int totalhealth_; |
---|
52 | unsigned int num_Stones_; |
---|
53 | unsigned int size_; |
---|
54 | std::vector<OrxoBloxStones*> TotalStones_; //!< A list of all stones in a Wall. |
---|
55 | bool delay_; |
---|
56 | OrxoBlox* orxoblox_; |
---|
57 | WeakPtr<OrxoBloxCenterpoint> center_; //!< The playing field. |
---|
58 | |
---|
59 | }; |
---|
60 | } |
---|
61 | |
---|
62 | #endif /* _OrxoBloxWall_H__ */ |
---|