From 8866ef5699150d0549096efa94fc311ff7a48dc7 Mon Sep 17 00:00:00 2001 From: JozanLeClerc Date: Tue, 3 Mar 2020 14:47:33 +0100 Subject: Changing stuff --- src/ft_check_missing.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'src/ft_check_missing.c') diff --git a/src/ft_check_missing.c b/src/ft_check_missing.c index 4828250..caaca9e 100644 --- a/src/ft_check_missing.c +++ b/src/ft_check_missing.c @@ -26,29 +26,29 @@ int int ft_check_missing(t_cub *clist) { - if (!clist->mlist->no_tex_path[0]) + if (!clist.mlist.no_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_NORTH, clist)); - else if (!clist->mlist->so_tex_path[0]) + else if (!clist.mlist.so_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_SOUTH, clist)); - else if (!clist->mlist->ea_tex_path[0]) + else if (!clist.mlist.ea_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_EAST, clist)); - else if (!clist->mlist->we_tex_path[0]) + else if (!clist.mlist.we_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_WEST, clist)); - else if (!clist->mlist->sprite_path[0]) + else if (!clist.mlist.sprite_path[0]) return (ft_missing_error(FT_ERR_MISS_SPRITE, clist)); - else if (clist->wlist->x_size == 0 || clist->wlist->y_size == 0) + else if (clist.wlist.x_size == 0 || clist.wlist.y_size == 0) return (ft_missing_error(FT_ERR_MISS_RESOLUTION, clist)); - else if (clist->f_rgb.r == -1 || clist->f_rgb.g == -1 - || clist->f_rgb.b == -1) + else if (clist.f_rgb.r == -1 || clist.f_rgb.g == -1 + || clist.f_rgb.b == -1) return (ft_missing_error(FT_ERR_MISS_FLOOR_C, clist)); - else if (clist->c_rgb.r == -1 || clist->c_rgb.g == -1 - || clist->c_rgb.b == -1) + else if (clist.c_rgb.r == -1 || clist.c_rgb.g == -1 + || clist.c_rgb.b == -1) return (ft_missing_error(FT_ERR_MISS_CEIL_C, clist)); - else if (clist->plist->pos_x == 0 || clist->plist->pos_y == 0) + else if (clist.plist.pos_x == 0 || clist.plist.pos_y == 0) return (ft_missing_error(FT_ERR_MISS_PLAYER_SPAWN, clist)); - else if (clist->mlist->isnlvl && !clist->mlist->nl_tex_path[0]) + else if (clist.mlist.isnlvl && !clist.mlist.nl_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_NLVL, clist)); - else if (clist->mlist->isnlvl && !clist->mlist->nlevel_path[0]) + else if (clist.mlist.isnlvl && !clist.mlist.nlevel_path[0]) return (ft_missing_error(FT_ERR_MISS_NLVL_PATH, clist)); return (0); } -- cgit v1.2.3 From ce43b1cd1caa539af687425f58a6999a20807878 Mon Sep 17 00:00:00 2001 From: JozanLeClerc Date: Tue, 3 Mar 2020 16:14:26 +0100 Subject: Going full stack is bav --- src/ft_check_missing.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'src/ft_check_missing.c') diff --git a/src/ft_check_missing.c b/src/ft_check_missing.c index caaca9e..02893bf 100644 --- a/src/ft_check_missing.c +++ b/src/ft_check_missing.c @@ -26,29 +26,29 @@ int int ft_check_missing(t_cub *clist) { - if (!clist.mlist.no_tex_path[0]) + if (!clist->mlist.no_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_NORTH, clist)); - else if (!clist.mlist.so_tex_path[0]) + else if (!clist->mlist.so_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_SOUTH, clist)); - else if (!clist.mlist.ea_tex_path[0]) + else if (!clist->mlist.ea_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_EAST, clist)); - else if (!clist.mlist.we_tex_path[0]) + else if (!clist->mlist.we_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_WEST, clist)); - else if (!clist.mlist.sprite_path[0]) + else if (!clist->mlist.sprite_path[0]) return (ft_missing_error(FT_ERR_MISS_SPRITE, clist)); - else if (clist.wlist.x_size == 0 || clist.wlist.y_size == 0) + else if (clist->wlist.x_size == 0 || clist->wlist.y_size == 0) return (ft_missing_error(FT_ERR_MISS_RESOLUTION, clist)); - else if (clist.f_rgb.r == -1 || clist.f_rgb.g == -1 - || clist.f_rgb.b == -1) + else if (clist->f_rgb.r == -1 || clist->f_rgb.g == -1 + || clist->f_rgb.b == -1) return (ft_missing_error(FT_ERR_MISS_FLOOR_C, clist)); - else if (clist.c_rgb.r == -1 || clist.c_rgb.g == -1 - || clist.c_rgb.b == -1) + else if (clist->c_rgb.r == -1 || clist->c_rgb.g == -1 + || clist->c_rgb.b == -1) return (ft_missing_error(FT_ERR_MISS_CEIL_C, clist)); - else if (clist.plist.pos_x == 0 || clist.plist.pos_y == 0) + else if (clist->plist.pos_x == 0 || clist->plist.pos_y == 0) return (ft_missing_error(FT_ERR_MISS_PLAYER_SPAWN, clist)); - else if (clist.mlist.isnlvl && !clist.mlist.nl_tex_path[0]) + else if (clist->mlist.isnlvl && !clist->mlist.nl_tex_path[0]) return (ft_missing_error(FT_ERR_MISS_NLVL, clist)); - else if (clist.mlist.isnlvl && !clist.mlist.nlevel_path[0]) + else if (clist->mlist.isnlvl && !clist->mlist.nlevel_path[0]) return (ft_missing_error(FT_ERR_MISS_NLVL_PATH, clist)); return (0); } -- cgit v1.2.3