diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-29 17:38:46 +0200 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-29 17:38:46 +0200 |
commit | a07392fc219afc45000201d2f495694ad9b82763 (patch) | |
tree | 0eb3f2b9003ad7ceae4692242e46de56e55053b0 /src/ft_get_traps.c | |
parent | Removed skybox shit (diff) | |
parent | Norm (diff) | |
download | 42-cub3d-a07392fc219afc45000201d2f495694ad9b82763.tar.gz 42-cub3d-a07392fc219afc45000201d2f495694ad9b82763.tar.bz2 42-cub3d-a07392fc219afc45000201d2f495694ad9b82763.tar.xz 42-cub3d-a07392fc219afc45000201d2f495694ad9b82763.tar.zst 42-cub3d-a07392fc219afc45000201d2f495694ad9b82763.zip |
Merge branch 'fix-details'
Diffstat (limited to 'src/ft_get_traps.c')
-rw-r--r-- | src/ft_get_traps.c | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/src/ft_get_traps.c b/src/ft_get_traps.c index fef3179..db0699c 100644 --- a/src/ft_get_traps.c +++ b/src/ft_get_traps.c @@ -14,35 +14,35 @@ #include <cub3d.h> #include <stdint.h> -void - ft_get_trap_spawn(t_cub *clist) -{ - size_t x; - size_t y; - uint16_t i; +/* void */ +/* ft_get_trap_spawn(t_cub *clist) */ +/* { */ +/* size_t x; */ +/* size_t y; */ +/* uint16_t i; */ - x = 1; - y = 1; - i = 0; - while (clist->mlist.map[y]) - { - while (clist->mlist.map[y][x]) - { - if (clist->mlist.map[y][x] == 'T') - { - clist->mlist.traps_nbr++; - if (clist->mlist.traps_nbr > 512) - ft_map_error(FT_ERR_TOO_MUCH_TRAPS, clist); - clist->traps[i].s_pos_x = x; - clist->traps[i].s_pos_y = y; - i++; - } - x++; - } - x = 1; - y++; - } -} +/* x = 1; */ +/* y = 1; */ +/* i = 0; */ +/* while (clist->mlist.map[y]) */ +/* { */ +/* while (clist->mlist.map[y][x]) */ +/* { */ +/* if (clist->mlist.map[y][x] == 'T') */ +/* { */ +/* clist->mlist.traps_nbr++; */ +/* if (clist->mlist.traps_nbr > 512) */ +/* ft_map_error(FT_ERR_TOO_MUCH_TRAPS, clist); */ +/* clist->traps[i].s_pos_x = x; */ +/* clist->traps[i].s_pos_y = y; */ +/* i++; */ +/* } */ +/* x++; */ +/* } */ +/* x = 1; */ +/* y++; */ +/* } */ +/* } */ int8_t ft_get_traps(char **words, t_cub *clist) |