wip solving buble effect by wall height calculation
This commit is contained in:
@@ -73,18 +73,3 @@ void plr_turn_right(t_plr *plr)
|
||||
plr->cosj = cos(radj);
|
||||
plr->sinj = sin(radj);
|
||||
}
|
||||
|
||||
void plr_turn(t_plr *plr, int deg)
|
||||
{
|
||||
double radi;
|
||||
double radj;
|
||||
|
||||
plr->rot = deg;
|
||||
// calculate trigo for rotations
|
||||
radi = plr->rot * M_PI / 180;
|
||||
radj = radi + (M_PI / 2);
|
||||
plr->cosi = cos(radi);
|
||||
plr->sini = sin(radi);
|
||||
plr->cosj = cos(radj);
|
||||
plr->sinj = sin(radj);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user