From 920866d8af8e9504188f9a6d9fef8a253e5f6da1 Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Date: Wed, 8 Mar 2023 16:52:18 +0100 Subject: [PATCH] Print remaining time with 0.1 second precision --- src/emu/emu_stat.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/emu/emu_stat.c b/src/emu/emu_stat.c index b43d2ba..f83b2a7 100644 --- a/src/emu/emu_stat.c +++ b/src/emu/emu_stat.c @@ -62,8 +62,8 @@ emu_stat_report(struct emu_stat *stat, struct player *player, int last) nprocessed, time_elapsed); } else { int tmin = (int) (time_left / 60.0); - int tsec = (int) ((time_left / 60.0 - tmin) * 60.0); - info("%5.1f%% done at %.0f kev/s (%d min %d s left) \r", + double tsec = ((time_left / 60.0 - tmin) * 60.0); + info("%5.1f%% done at %.0f kev/s (%d min %.1f s left) \r", progress * 100.0, speed * 1e-3, tmin, tsec); }