fix: the keyhook to move in the good way (Left != Right)
This commit is contained in:
parent
0d432c6ba3
commit
6f2677dde3
5 changed files with 7 additions and 7 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -1,5 +1,5 @@
|
||||||
.direnv/
|
.direnv/
|
||||||
Cub3D
|
Cub3D*
|
||||||
build/
|
build/
|
||||||
.clangd
|
.clangd
|
||||||
.clang*
|
.clang*
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
/* By: bgoulard <bgoulard@student.42.fr> +#+ +:+ +#+ */
|
/* By: bgoulard <bgoulard@student.42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/11/28 13:53:54 by bgoulard #+# #+# */
|
/* Created: 2024/11/28 13:53:54 by bgoulard #+# #+# */
|
||||||
/* Updated: 2024/11/29 17:07:00 by bgoulard ### ########.fr */
|
/* Updated: 2024/12/01 17:33:48 by rparodi ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
/* By: bgoulard <bgoulard@student.42.fr> +#+ +:+ +#+ */
|
/* By: bgoulard <bgoulard@student.42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/11/28 14:12:25 by bgoulard #+# #+# */
|
/* Created: 2024/11/28 14:12:25 by bgoulard #+# #+# */
|
||||||
/* Updated: 2024/11/29 17:00:33 by bgoulard ### ########.fr */
|
/* Updated: 2024/12/01 17:27:45 by rparodi ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
|
|
@ -28,9 +28,9 @@ int key_hook(int keycode, t_info *data)
|
||||||
if (keycode == XK_s)
|
if (keycode == XK_s)
|
||||||
move_backward(data);
|
move_backward(data);
|
||||||
if (keycode == XK_a)
|
if (keycode == XK_a)
|
||||||
move_right(data);
|
|
||||||
if (keycode == XK_d)
|
|
||||||
move_left(data);
|
move_left(data);
|
||||||
|
if (keycode == XK_d)
|
||||||
|
move_right(data);
|
||||||
if (keycode == XK_Left)
|
if (keycode == XK_Left)
|
||||||
look_left(data);
|
look_left(data);
|
||||||
if (keycode == XK_Right)
|
if (keycode == XK_Right)
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
/* By: rparodi <rparodi@student.42.fr> +#+ +:+ +#+ */
|
/* By: rparodi <rparodi@student.42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/11/11 19:53:42 by rparodi #+# #+# */
|
/* Created: 2024/11/11 19:53:42 by rparodi #+# #+# */
|
||||||
/* Updated: 2024/11/29 17:06:44 by bgoulard ### ########.fr */
|
/* Updated: 2024/12/01 17:33:00 by rparodi ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
/* By: rparodi <rparodi@student.42.fr> +#+ +:+ +#+ */
|
/* By: rparodi <rparodi@student.42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/11/27 12:09:00 by rparodi #+# #+# */
|
/* Created: 2024/11/27 12:09:00 by rparodi #+# #+# */
|
||||||
/* Updated: 2024/11/27 19:36:33 by rparodi ### ########.fr */
|
/* Updated: 2024/12/01 17:25:59 by rparodi ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue