aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRudy Bousset <rbousset@z3r8p1.le-101.fr>2020-02-13 18:37:31 +0100
committerRudy Bousset <rbousset@z3r8p1.le-101.fr>2020-02-13 18:37:31 +0100
commit5e40352aa28c29c7e10b11c576a743d03beeaaf1 (patch)
treea80a1ca9cefa7c61c26441df3d4d088ded83c708
parentSmooth (diff)
download42-cub3d-5e40352aa28c29c7e10b11c576a743d03beeaaf1.tar.gz
42-cub3d-5e40352aa28c29c7e10b11c576a743d03beeaaf1.tar.bz2
42-cub3d-5e40352aa28c29c7e10b11c576a743d03beeaaf1.tar.xz
42-cub3d-5e40352aa28c29c7e10b11c576a743d03beeaaf1.tar.zst
42-cub3d-5e40352aa28c29c7e10b11c576a743d03beeaaf1.zip
Changed move speed
Diffstat (limited to '')
-rw-r--r--src/ft_drawmap.c2
-rw-r--r--src/ft_init_lists.c2
-rw-r--r--src/ft_key_events.c8
3 files changed, 6 insertions, 6 deletions
diff --git a/src/ft_drawmap.c b/src/ft_drawmap.c
index 1526ae6..9f749ad 100644
--- a/src/ft_drawmap.c
+++ b/src/ft_drawmap.c
@@ -68,9 +68,9 @@ void
clist->wlist->x_size, clist->wlist->y_size);
clist->img.ptr = mlx_get_data_addr(clist->img.img, &clist->img.bpp,
&clist->img.sizeline, &clist->img.endian);
+ ft_castray(clist);
ft_draw_core_map(clist->map, clist);
ft_draw_player(clist->plist, clist);
- ft_castray(clist);
mlx_put_image_to_window(clist->wlist->wlx,
clist->wlist->winptr, clist->img.img, 0, 0);
mlx_destroy_image(clist->wlist->wlx, clist->img.img);
diff --git a/src/ft_init_lists.c b/src/ft_init_lists.c
index 1233eaa..8bb0d24 100644
--- a/src/ft_init_lists.c
+++ b/src/ft_init_lists.c
@@ -43,7 +43,7 @@ static t_player
plist->dir_x = -1;
plist->dir_y = 0;
plist->plane_x = 0;
- plist->plane_y = 0.50;
+ plist->plane_y = 0.66;
return (plist);
}
diff --git a/src/ft_key_events.c b/src/ft_key_events.c
index 5dbfde0..2112d2e 100644
--- a/src/ft_key_events.c
+++ b/src/ft_key_events.c
@@ -21,7 +21,7 @@ static int8_t
t_player *pl;
pl = clist->plist;
- pl->pos_y += 0.3 * (-1); /* pl->mult; */
+ pl->pos_y += 0.2 * (-1); /* pl->mult; */
pl->pos_x += 0;
return (0);
}
@@ -32,7 +32,7 @@ static int8_t
t_player *pl;
pl = clist->plist;
- pl->pos_x -= 0.3;
+ pl->pos_x -= 0.2;
return (0);
}
@@ -42,7 +42,7 @@ static int8_t
t_player *pl;
pl = clist->plist;
- pl->pos_y += 0.3;
+ pl->pos_y += 0.2;
return (0);
}
@@ -52,7 +52,7 @@ static int8_t
t_player *pl;
pl = clist->plist;
- pl->pos_x += 0.3;
+ pl->pos_x += 0.2;
return (0);
}