diff options
Diffstat (limited to 'src/ft_parse_map.c')
-rw-r--r-- | src/ft_parse_map.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/ft_parse_map.c b/src/ft_parse_map.c index 48201fd..9b34087 100644 --- a/src/ft_parse_map.c +++ b/src/ft_parse_map.c @@ -25,13 +25,13 @@ static void size_t j; i = 0; - ml = clist->mlist; - while (ml->map[i]) + ml = clist.mlist; + while (ml.map[i]) i++; j = 0; - while (ml->map[i - 1][j]) + while (ml.map[i - 1][j]) { - if (ml->map[i - 1][j] != '1' && ml->map[i - 1][j] != '\0') + if (ml.map[i - 1][j] != '1' && ml.map[i - 1][j] != '\0') ft_map_error(FT_ERR_MAP_L_L, clist); j++; } @@ -51,7 +51,7 @@ static int8_t char **words; int ret; - clist->mlist->line_chk += 1; + clist.mlist.line_chk += 1; if ((ret = get_next_line(fd, &line)) < 0) return (ft_map_error(FT_ERR_READ, clist)); if (ret == 0) @@ -93,14 +93,14 @@ void while (ret != 12 && ret >= 0) ret = ft_parse_it(fd, clist); (ret == -2) ? (ft_map_error(FT_ERR_ALR_SET, clist)) : 0; - (ret == -1) ? (ft_map_error(clist->errmsg, clist)) : 0; + (ret == -1) ? (ft_map_error(clist.errmsg, clist)) : 0; if (ft_get_map_core(fd, clist) < 0) - ft_map_error(clist->errmsg, clist); + ft_map_error(clist.errmsg, clist); ft_check_map_last_line(clist); - ft_get_player_spawn(clist->plist, clist); - ft_get_nlvl_pos(clist->mlist); + ft_get_player_spawn(clist.plist, clist); + ft_get_nlvl_pos(clist.mlist); ft_check_missing(clist); ft_set_minimap_scale(clist); - clist->currlvl += 1; + clist.currlvl += 1; close(fd); } |