diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2017-11-08 12:26:43 +0100 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2017-11-08 12:26:43 +0100 |
commit | cdd75000effac0216588766234cfa5b3e8e304d5 (patch) | |
tree | 3832063bf12dae9e8b29c9e787d08dc75a9ba704 /src/render.cpp | |
parent | c5a621b3ebeb180d2181df35038ed856714b64e2 (diff) |
Frametime-independent dynamics.
Diffstat (limited to 'src/render.cpp')
-rw-r--r-- | src/render.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/render.cpp b/src/render.cpp index 259d898..d1b9752 100644 --- a/src/render.cpp +++ b/src/render.cpp @@ -65,9 +65,10 @@ state_t::state_t(sf::RenderWindow *window_) font.loadFromFile("assets/LiberationMono-Regular.ttf"); } -void state_t::begin_frame(double time_) +void state_t::begin_frame(double now_, double dt_) { - now = time_; + now = now_; + dt = dt_; window->clear(); } |