change textures

This commit is contained in:
asus
2024-01-09 15:15:20 +01:00
parent 5505adf02c
commit 70e0c6abfe
16 changed files with 22653 additions and 28 deletions

View File

@@ -74,7 +74,7 @@ int check_content(t_map *map)
{
if (map->content[y][x] == ' ' && check_spaces(map, y, x))
mb_exit("Error\nInvalid space positions.\n", EXIT_FAILURE);
else if (!ft_strchr(" 01SNWE", map->content[y][x]))
else if (!ft_strchr(" .01SNWE", map->content[y][x]))
mb_exit("Error\nInvalid map characters.\n", EXIT_FAILURE);
else if (ft_strchr("SNWE", map->content[y][x]) \
&& set_player(map, y, x, map->content[y][x]))

View File

@@ -74,7 +74,10 @@ static void fill_row(char *row, char *line, int width)
i = 0;
while (line != NULL && line[i] != '\0' && line[i] != '\n')
{
row[i] = line[i];
if (line[i] == '.')
row[i] = '0';
else
row[i] = line[i];
i++;
}
while (i < width - 1)