diff options
| author | Kelly Rauchenberger <fefferburbia@gmail.com> | 2015-03-13 11:14:01 -0400 |
|---|---|---|
| committer | Kelly Rauchenberger <fefferburbia@gmail.com> | 2015-03-13 11:14:01 -0400 |
| commit | b8d62ce8d2f7c8f38aa9c52ab8d7dd32dc3aba64 (patch) | |
| tree | 42720ef2eefaf42abc25937e9a2a78cd6998f0f6 /src/entity.h | |
| parent | 47d9d7884c57c2c14dd363b4ccb0df1dcbb5375e (diff) | |
| download | therapy-b8d62ce8d2f7c8f38aa9c52ab8d7dd32dc3aba64.tar.gz therapy-b8d62ce8d2f7c8f38aa9c52ab8d7dd32dc3aba64.tar.bz2 therapy-b8d62ce8d2f7c8f38aa9c52ab8d7dd32dc3aba64.zip | |
Fixed my timestep!
http://gafferongames.com/game-physics/fix-your-timestep/
Diffstat (limited to 'src/entity.h')
| -rw-r--r-- | src/entity.h | 4 |
1 files changed, 2 insertions, 2 deletions
| diff --git a/src/entity.h b/src/entity.h index 04772e9..e22fd10 100644 --- a/src/entity.h +++ b/src/entity.h | |||
| @@ -37,7 +37,7 @@ class Entity { | |||
| 37 | public: | 37 | public: |
| 38 | void addComponent(std::shared_ptr<Component> c); | 38 | void addComponent(std::shared_ptr<Component> c); |
| 39 | void send(Game& game, const Message& msg); | 39 | void send(Game& game, const Message& msg); |
| 40 | void tick(Game& game); | 40 | void tick(Game& game, double dt); |
| 41 | void input(Game& game, int key, int action); | 41 | void input(Game& game, int key, int action); |
| 42 | void render(Game& game, Texture& buffer); | 42 | void render(Game& game, Texture& buffer); |
| 43 | void detectCollision(Game& game, Entity& collider, std::pair<double, double> old_position); | 43 | void detectCollision(Game& game, Entity& collider, std::pair<double, double> old_position); |
| @@ -53,7 +53,7 @@ class Component { | |||
| 53 | public: | 53 | public: |
| 54 | virtual void receive(Game&, Entity&, const Message&) {} | 54 | virtual void receive(Game&, Entity&, const Message&) {} |
| 55 | virtual void render(Game&, Entity&, Texture&) {} | 55 | virtual void render(Game&, Entity&, Texture&) {} |
| 56 | virtual void tick(Game&, Entity&) {} | 56 | virtual void tick(Game&, Entity&, double) {} |
| 57 | virtual void input(Game&, Entity&, int, int) {} | 57 | virtual void input(Game&, Entity&, int, int) {} |
| 58 | virtual void detectCollision(Game&, Entity&, Entity&, std::pair<double, double>) {} | 58 | virtual void detectCollision(Game&, Entity&, Entity&, std::pair<double, double>) {} |
| 59 | }; | 59 | }; |
