cub3d/src/map/mapdata.h

56 lines
1.5 KiB
C

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* mapdata.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: kcolin <kcolin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/07/17 14:58:19 by kcolin #+# #+# */
/* Updated: 2025/07/28 15:04:47 by kcolin ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef MAPDATA_H
# define MAPDATA_H
# include <stdbool.h>
typedef enum e_caridnal_dir
{
NORTH,
SOUTH,
EAST,
WEST
} t_cardinal_dir;
typedef enum e_intercardinal_dir
{
NORTHEAST,
SOUTHEAST,
NORTHWEST,
SOUTHWEST,
} t_intercardinal_dir;
# define ERRLEN 1024
typedef struct s_mapdata
{
char *filename;
char *no_texture;
char *so_texture;
char *we_texture;
char *ea_texture;
unsigned int f_color;
unsigned int c_color;
int mapheight;
char **map;
char **mapflood;
int skipped_lines;
bool isvalid;
int startx;
int starty;
t_cardinal_dir startdirection;
char error[ERRLEN];
} t_mapdata;
#endif // MAPDATA_H