diff options
| author | Kelly Rauchenberger <fefferburbia@gmail.com> | 2018-02-08 12:34:42 -0500 | 
|---|---|---|
| committer | Kelly Rauchenberger <fefferburbia@gmail.com> | 2018-02-08 12:34:42 -0500 | 
| commit | cefe66cdbb8786dc455657376e36f0ff8785d5bc (patch) | |
| tree | 7e90536fad90f2954b3834dc4959f402883c32b3 /src/components/orientable.h | |
| parent | cec0ed92c4035c4421d3cc2448f5423fcbb7f7d4 (diff) | |
| download | therapy-cefe66cdbb8786dc455657376e36f0ff8785d5bc.tar.gz therapy-cefe66cdbb8786dc455657376e36f0ff8785d5bc.tar.bz2 therapy-cefe66cdbb8786dc455657376e36f0ff8785d5bc.zip  | |
Introduced animated sprites
Also restyled a lot of the code.
Diffstat (limited to 'src/components/orientable.h')
| -rw-r--r-- | src/components/orientable.h | 24 | 
1 files changed, 24 insertions, 0 deletions
| diff --git a/src/components/orientable.h b/src/components/orientable.h new file mode 100644 index 0000000..8f56912 --- /dev/null +++ b/src/components/orientable.h | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | #ifndef ORIENTABLE_H_EDB6C4A1 | ||
| 2 | #define ORIENTABLE_H_EDB6C4A1 | ||
| 3 | |||
| 4 | #include "component.h" | ||
| 5 | |||
| 6 | class OrientableComponent : public Component { | ||
| 7 | public: | ||
| 8 | |||
| 9 | inline bool isFacingRight() const | ||
| 10 | { | ||
| 11 | return facingRight_; | ||
| 12 | } | ||
| 13 | |||
| 14 | inline void setFacingRight(bool v) | ||
| 15 | { | ||
| 16 | facingRight_ = v; | ||
| 17 | } | ||
| 18 | |||
| 19 | private: | ||
| 20 | |||
| 21 | bool facingRight_ = false; | ||
| 22 | }; | ||
| 23 | |||
| 24 | #endif /* end of include guard: ORIENTABLE_H_EDB6C4A1 */ | ||
