42_cube3D/map/parsing_private.h
Camille Chauvet b95f3ee1af clean: norm
2023-05-16 19:12:54 +02:00

31 lines
1.6 KiB
C

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* parsing_private.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: cchauvet <cchauvet@student.42angouleme.fr +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/05/16 16:27:57 by cchauvet #+# #+# */
/* Updated: 2023/05/16 18:46:21 by cchauvet ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef PARSING_PRIVATE_H
# define PARSING_PRIVATE_H
# include <sys/types.h>
# include "../libftx/libftx.h"
# include "./parsing.h"
int parsing_meta(const char *path);
int get_token(const char *str);
char ***get_header(const char **file_content, size_t *header_size);
int header_is_valid(char ***header, t_map *map);
char **get_body(const char **file_content, size_t header_size);
int body_is_valid(t_map *map);
int get_spawn_position(const char **body, double *x, double *y);
int map_is_in_one_part(const char **body);
int set_texture(t_map *map, int token, const char *key, const char *value);
int set_color(long long *color, const char *key, const char *value);
int check_header_is_complete(t_map *map);
#endif