From 9628c2c097b10f22aafd4890ab8e98375b5740da Mon Sep 17 00:00:00 2001 From: Paweł Redman Date: Tue, 19 Dec 2017 22:21:17 +0100 Subject: Replace clock_gettime with std::chrono. --- src/game/interface.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/game/interface.cpp') diff --git a/src/game/interface.cpp b/src/game/interface.cpp index 5e5dc70..1300e95 100644 --- a/src/game/interface.cpp +++ b/src/game/interface.cpp @@ -247,13 +247,13 @@ void state_t::render_to(render::state_t *render) ss << render->stats.entities; render->render_text(x, em, ss.str(), render::ALIGN_LEFT_TOP, sf::Color::White); - perf_hist_index = (perf_hist_index + 1) % count(perf_hist); + perf_hist_index = (perf_hist_index + 1) % COUNT(perf_hist); perf_hist[perf_hist_index] = 1.0 / render->dt; fps = 0.0; - for (size_t i = 0; i < count(perf_hist); i++) + for (size_t i = 0; i < COUNT(perf_hist); i++) fps += perf_hist[i]; - fps /= count(perf_hist); + fps /= COUNT(perf_hist); x[1] += em; ss.str(std::string()); -- cgit