possibility to choose angle of view

This commit is contained in:
hugogogo
2022-04-23 11:58:11 +02:00
parent fac1f78230
commit e9b0dd7ec9
9 changed files with 72 additions and 48 deletions

View File

@@ -20,8 +20,8 @@ int plr_out_limits(t_game *game, int x, int y)
xmax = game->map_img.sizel / (game->map_img.bpp / 8);
ymax = game->map_win.size_y;
cell_x = x / CELL;
cell_y = y / CELL;
cell_x = x / game->map.cell;
cell_y = y / game->map.cell;
if (is_wall(game, cell_x, cell_y))
return (1);
if (x < 0 || y < 0 || x > xmax || y > ymax)