tmp push merge resolution not finished
This commit is contained in:
parent
2568aa69a6
commit
00dc0e9e67
16 changed files with 454 additions and 59 deletions
29
raycast/get_cl.c
Normal file
29
raycast/get_cl.c
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* ::: :::::::: */
|
||||
/* get_cl.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: bgoulard <bgoulard@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2024/11/28 14:15:04 by bgoulard #+# #+# */
|
||||
/* Updated: 2024/11/28 14:57:25 by bgoulard ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
#include "cub3d_struct.h"
|
||||
|
||||
int get_cl(int side, t_ipoint step)
|
||||
{
|
||||
int color;
|
||||
|
||||
if (side == 0 && step.x > 0)
|
||||
color = 0x00FF0000;
|
||||
else if (side == 0 && step.x < 0)
|
||||
color = 0x0000FF00;
|
||||
else if (side == 1 && step.y > 0)
|
||||
color = 0x000000FF;
|
||||
else
|
||||
color = 0x00FFFF00;
|
||||
return (color);
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue