diff options
author | Rudy Bousset <rbousset@z2r6p3.le-101.fr> | 2020-03-08 20:40:40 +0100 |
---|---|---|
committer | Rudy Bousset <rbousset@z2r6p3.le-101.fr> | 2020-03-08 20:40:40 +0100 |
commit | 843f11bd9a1d460ade2ef3b0cadc8e28f0a61247 (patch) | |
tree | b56662e66e9b378eb2b0acc6ba54fee39470c3ad /src/ft_floor_cast.c | |
parent | Something wrong (diff) | |
download | 42-cub3d-843f11bd9a1d460ade2ef3b0cadc8e28f0a61247.tar.gz 42-cub3d-843f11bd9a1d460ade2ef3b0cadc8e28f0a61247.tar.bz2 42-cub3d-843f11bd9a1d460ade2ef3b0cadc8e28f0a61247.tar.xz 42-cub3d-843f11bd9a1d460ade2ef3b0cadc8e28f0a61247.tar.zst 42-cub3d-843f11bd9a1d460ade2ef3b0cadc8e28f0a61247.zip |
Nice and clean
Diffstat (limited to '')
-rw-r--r-- | src/ft_floor_cast.c | 34 |
1 files changed, 4 insertions, 30 deletions
diff --git a/src/ft_floor_cast.c b/src/ft_floor_cast.c index 3343fc3..ddc7bde 100644 --- a/src/ft_floor_cast.c +++ b/src/ft_floor_cast.c @@ -13,33 +13,7 @@ #include <cub3d.h> #include <stdint.h> -#include <stdio.h> -void - ft_floor_cast(t_cub *cl) -{ - t_ray *rl; - const uint32_t map_x = (uint32_t)cl->plist.pos_x; - const uint32_t map_y = (uint32_t)cl->plist.pos_y; - - rl = &cl->rlist; - if (rl->side == 0 && rl->x_ray_dir > 0) - { - rl->floor_x_wall = map_x; - rl->floor_y_wall = map_y + rl->wall_hit_x; - } - else if (rl->side == 0 && rl->x_ray_dir < 0) - { - rl->floor_x_wall = map_x + 1.0; - rl->floor_y_wall = map_y + rl->wall_hit_x; - } - else if (rl->side == 1 && rl->y_ray_dir > 0) - { - rl->floor_x_wall = map_x + rl->wall_hit_x; - rl->floor_y_wall = map_y; - } - else - { - rl->floor_x_wall = map_x + rl->wall_hit_x; - rl->floor_y_wall = map_y + 1.0; - } -} +/* void */ +/* ft_floor_cast(t_cub *cl) */ +/* { */ +/* } */ |