diff --git a/srcs/events/key_events.c b/srcs/events/key_events.c index 5dce330..f3bf8fd 100644 --- a/srcs/events/key_events.c +++ b/srcs/events/key_events.c @@ -6,7 +6,7 @@ /* By: jteissie +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/08/27 18:40:50 by jteissie #+# #+# */ -/* Updated: 2024/09/02 17:24:13 by jteissie ### ########.fr */ +/* Updated: 2024/09/02 17:28:10 by jteissie ### ########.fr */ /* */ /* ************************************************************************** */ @@ -57,15 +57,9 @@ static void key_move_camera(t_data *data, t_rot dir) static void pause_game(t_data *data) { if (data->pause == TRUE) - { - mlx_mouse_hide(data->mlx, data->window); data->pause = FALSE; - } else - { - mlx_mouse_show(data->mlx, data->window); data->pause = TRUE; - } } int key_events(int keycode, t_data *data) diff --git a/srcs/main.c b/srcs/main.c index 8d42f65..2fb4953 100644 --- a/srcs/main.c +++ b/srcs/main.c @@ -61,7 +61,6 @@ static int init_data(t_data *data, char *map_file) void start_game(t_data *data) { - mlx_mouse_hide(data->mlx, data->window); mlx_loop_hook(data->mlx, rc_rendering, data); mlx_hook(data->window, KeyPress, KeyPressMask, &key_events, data); mlx_hook(data->window, DestroyNotify, StructureNotifyMask, &cleanup, data);