aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_parse_map.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ft_parse_map.c')
-rw-r--r--src/ft_parse_map.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/ft_parse_map.c b/src/ft_parse_map.c
index 29f2c43..f5e491f 100644
--- a/src/ft_parse_map.c
+++ b/src/ft_parse_map.c
@@ -16,6 +16,7 @@
#include <stdlib.h>
#include <fcntl.h>
#include <unistd.h>
+#include <stdint.h>
static void
ft_check_cub(const char *map_path, t_cub *clist)
@@ -118,6 +119,8 @@ void
ft_check_map_last_line(clist);
ft_get_player_spawn(clist->plist, clist);
ft_check_missing(clist);
+ clist->scale = ((uint16_t)clist->wlist->x_size /
+ (uint16_t)clist->map_w) - 2;
ft_print_list(clist);
close(fd);
}