aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_del_map.c
blob: 49b9db9b37c464777d5d9837452cf50d4db9012c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/* ************************************************************************** */
/*                                                                            */
/*                                                        :::      ::::::::   */
/*   ft_del_map.c                                       :+:      :+:    :+:   */
/*                                                    +:+ +:+         +:+     */
/*   By: rbousset <marvin@42.fr>                    +#+  +:+       +#+        */
/*                                                +#+#+#+#+#+   +#+           */
/*   Created: 2020/02/14 17:28:46 by rbousset          #+#    #+#             */
/*   Updated: 2020/02/14 17:28:46 by rbousset         ###   ########lyon.fr   */
/*                                                                            */
/* ************************************************************************** */

#include <libft.h>
#include <cub3d.h>
#include <stdint.h>

void
	ft_del_map(t_map *ml)
{
	ft_memdel((void*)&ml->filename);
	ft_memdel((void*)&ml->no_tex_path);
	ft_memdel((void*)&ml->so_tex_path);
	ft_memdel((void*)&ml->ea_tex_path);
	ft_memdel((void*)&ml->we_tex_path);
	ft_memdel((void*)&ml->nl_tex_path);
	ft_memdel((void*)&ml->fl_tex_path);
	ft_memdel((void*)&ml->ce_tex_path);
	ft_memdel((void*)&ml->nlevel_path);
	ft_memdel((void*)&ml->traps_path);
	ft_memdel((void*)&ml->music_path);
	ft_memdel((void*)&ml->music_cmd);
	ft_memdel((void*)&ml->mapl);
	ft_free_words(ml->map);
	ft_free_sprites_path(ml->sprite_path);
}