mirror of
https://codeberg.org/ACME-Corporation/cub3d.git
synced 2025-12-06 09:58:09 +01:00
fix(hooks): Reworked keypresses events
Keypresses (along with keyreleases) events are now using booleans, a function in the game loop will apply various changes as the key are pressed. By default every boolean are set to false
This commit is contained in:
parent
fa3cb8da4a
commit
1626b1d9da
4 changed files with 43 additions and 27 deletions
|
|
@ -6,7 +6,7 @@
|
|||
/* By: kcolin <kcolin@42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/07/17 14:14:30 by kcolin #+# #+# */
|
||||
/* Updated: 2025/07/28 17:18:38 by tchampio ### ########.fr */
|
||||
/* Updated: 2025/07/29 12:33:46 by tchampio ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
|
|
@ -162,6 +162,7 @@ int main(int argc, char **argv)
|
|||
|
||||
if (argc < 2)
|
||||
return (ft_printf("Error: Missing cub3d file\n"), 1);
|
||||
ft_bzero(&data, sizeof(data));
|
||||
data.map = ft_calloc(sizeof(t_mapdata), 1);
|
||||
if (!check_cubfile(argv[1], data.map))
|
||||
return (ft_printf("Error: Wrong map file. Reason: %s\n",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue