diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-13 18:09:55 +0100 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-13 18:09:55 +0100 |
commit | 273459283c98b5f10814fdf74c74c2e6a13f10c0 (patch) | |
tree | 6959619028e32cb5452e7ca6b65cccf5a7ca0072 /src/ft_key_loop.c | |
parent | New sfx, clean exit (diff) | |
download | 42-cub3d-273459283c98b5f10814fdf74c74c2e6a13f10c0.tar.gz 42-cub3d-273459283c98b5f10814fdf74c74c2e6a13f10c0.tar.bz2 42-cub3d-273459283c98b5f10814fdf74c74c2e6a13f10c0.tar.xz 42-cub3d-273459283c98b5f10814fdf74c74c2e6a13f10c0.tar.zst 42-cub3d-273459283c98b5f10814fdf74c74c2e6a13f10c0.zip |
Not ideal
Diffstat (limited to 'src/ft_key_loop.c')
-rw-r--r-- | src/ft_key_loop.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ft_key_loop.c b/src/ft_key_loop.c index a7af38e..647b887 100644 --- a/src/ft_key_loop.c +++ b/src/ft_key_loop.c @@ -83,6 +83,8 @@ int { cl->key_ptr[cl->key_input[i]](cl); ft_collision(old_y, old_x, cl->key_input[i], cl); + if (cl->key_input[i] >= 0 && cl->key_input[i] <= 3) + ft_sfx_footstep(cl); if (cl->mlist.isnlvl && !cl->plist.isdead) { if ((uint32_t)cl->plist.pos_x == cl->mlist.nlx && @@ -94,7 +96,7 @@ int } i++; } - /* if (cl->key_input[0] != -1) */ + if (cl->key_input[0] != -1) ft_draw_scene(cl); return (0); } |