added usage
This commit is contained in:
BIN
builds/draw.o
Normal file
BIN
builds/draw.o
Normal file
Binary file not shown.
BIN
builds/fdf.o
Normal file
BIN
builds/fdf.o
Normal file
Binary file not shown.
BIN
builds/keypress.o
Normal file
BIN
builds/keypress.o
Normal file
Binary file not shown.
BIN
builds/modifs.o
Normal file
BIN
builds/modifs.o
Normal file
Binary file not shown.
BIN
builds/parse.o
Normal file
BIN
builds/parse.o
Normal file
Binary file not shown.
2
libft
2
libft
Submodule libft updated: d622367cfd...f32d4bbc96
@@ -75,13 +75,18 @@ void init_fdf(t_fdf *fdf)
|
||||
draw_image(fdf);
|
||||
}
|
||||
|
||||
int usage() {
|
||||
write(2, "usage:\nneed one argument : ./fdf maps/<map>.fdf\n", 48);
|
||||
return (0);
|
||||
}
|
||||
|
||||
int main(int ac, char **av)
|
||||
{
|
||||
t_fdf *fdf;
|
||||
int fd;
|
||||
|
||||
if (ac != 2)
|
||||
return (0);
|
||||
return usage();
|
||||
fdf = malloc(sizeof(t_fdf));
|
||||
fd = open(av[1], O_RDONLY);
|
||||
if (!fd || !fdf)
|
||||
|
||||
Reference in New Issue
Block a user