-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.c
36 lines (33 loc) · 1.38 KB
/
main.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* main.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: fatkeski <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/05/03 21:10:54 by fatkeski #+# #+# */
/* Updated: 2024/05/04 18:11:16 by fatkeski ### ########.fr */
/* */
/* ************************************************************************** */
#include "includes/so_long.h"
int main(int ac, char **av)
{
static t_game game;
static t_map map;
game.map = ↦
if (ac == 2)
{
ber_file_check(av[1], &game);
(game.map)->path = av[1];
create_map(&game);
map_format_check(&game);
if ((game.map)->height > 20 || (game.map)->width > 40)
print_error_message("Error: window size extends from screen\n",
&game);
create_game_interface(&game);
free_map((game.map)->vector);
}
else
ft_printf("Error: 2 arguments must be entered!\n");
return (0);
}