From a6dbe3b5710f719b3f02ba0044a72c64ee4155ac Mon Sep 17 00:00:00 2001 From: JozanLeClerc Date: Mon, 30 Mar 2020 13:54:11 +0200 Subject: Bug fix --- src/ft_get_fps_count.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) (limited to 'src/ft_get_fps_count.c') diff --git a/src/ft_get_fps_count.c b/src/ft_get_fps_count.c index f7f0177..1f717e8 100644 --- a/src/ft_get_fps_count.c +++ b/src/ft_get_fps_count.c @@ -1,7 +1,7 @@ /* ************************************************************************** */ /* */ /* ::: :::::::: */ -/* ft_key_loop.c :+: :+: :+: */ +/* ft_get_fps_count.c :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: rbousset +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ @@ -16,25 +16,6 @@ #include #include -static float - ft_clock_to_ms(clock_t ticks) -{ - return ((ticks / (float)CLOCKS_PER_SEC) * 1000.0); -} - -static void - ft_handle_firing(clock_t dt, t_cub *cl) -{ - static clock_t curr_time = 0; - - curr_time += dt; - if (dt > 0 && ft_clock_to_ms(curr_time) > 300.0) - { - cl->plist.fire = 0; - curr_time -= CLOCKS_PER_SEC; - } -} - void ft_get_fps_count(clock_t dt, t_cub *cl) { -- cgit v1.2.3