aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_raycasting.c
diff options
context:
space:
mode:
authorRudy Bousset <rbousset@z2r5p6.le-101.fr>2020-02-14 18:47:19 +0100
committerRudy Bousset <rbousset@z2r5p6.le-101.fr>2020-02-14 18:47:19 +0100
commit8e6080e73661cc8747b21b1153e4336796575cf7 (patch)
tree2eaec487a73f9df1a69627cff23c42746f1b296e /src/ft_raycasting.c
parentAdded turn around keys (diff)
download42-cub3d-8e6080e73661cc8747b21b1153e4336796575cf7.tar.gz
42-cub3d-8e6080e73661cc8747b21b1153e4336796575cf7.tar.bz2
42-cub3d-8e6080e73661cc8747b21b1153e4336796575cf7.tar.xz
42-cub3d-8e6080e73661cc8747b21b1153e4336796575cf7.tar.zst
42-cub3d-8e6080e73661cc8747b21b1153e4336796575cf7.zip
Norme is bav
Diffstat (limited to '')
-rw-r--r--src/ft_raycasting.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/ft_raycasting.c b/src/ft_raycasting.c
index c0b55c4..fadb9db 100644
--- a/src/ft_raycasting.c
+++ b/src/ft_raycasting.c
@@ -1,8 +1,20 @@
+/* ************************************************************************** */
+/* */
+/* ::: :::::::: */
+/* ft_raycasting.c :+: :+: :+: */
+/* +:+ +:+ +:+ */
+/* By: rbousset <marvin@42.fr> +#+ +:+ +#+ */
+/* +#+#+#+#+#+ +#+ */
+/* Created: 2020/02/14 17:22:57 by rbousset #+# #+# */
+/* Updated: 2020/02/14 17:23:42 by rbousset ### ########lyon.fr */
+/* */
+/* ************************************************************************** */
+
#include <cub3d.h>
#include <stdint.h>
static void
-ft_initray(t_cub *cl, uint16_t i)
+ ft_initray(t_cub *cl, uint16_t i)
{
t_win *wl;
t_player *pl;
@@ -28,7 +40,7 @@ ft_initray(t_cub *cl, uint16_t i)
}
void
-ft_castray(t_cub *cl)
+ ft_castray(t_cub *cl)
{
uint16_t i;
t_win *wl;
@@ -45,7 +57,7 @@ ft_castray(t_cub *cl)
cl->rlist.wall_b = cl->rlist.line_h / 2 + wl->y_size / 2;
if (cl->rlist.wall_b >= wl->y_size)\
cl->rlist.wall_b = wl->y_size - 1;
- ft_draw_verline(cl, i, cl->rlist.wall_t - 1, cl->rlist.wall_b, 0x0000ffaa);
+ ft_draw_verline(cl, i, cl->rlist.wall_t - 1, cl->rlist.wall_b);
i++;
}
}