aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_draw_ammo_back.c
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-03-23 22:06:00 +0100
committerJozanLeClerc <bousset.rudy@gmail.com>2020-03-23 22:06:00 +0100
commitc786ace26fb4a041a43b2149b61c11b1c75ba1ca (patch)
tree69f33f8a7e67a5f6214a38b15eea3541b317d7d4 /src/ft_draw_ammo_back.c
parentnow pthread (diff)
download42-cub3d-c786ace26fb4a041a43b2149b61c11b1c75ba1ca.tar.gz
42-cub3d-c786ace26fb4a041a43b2149b61c11b1c75ba1ca.tar.bz2
42-cub3d-c786ace26fb4a041a43b2149b61c11b1c75ba1ca.tar.xz
42-cub3d-c786ace26fb4a041a43b2149b61c11b1c75ba1ca.tar.zst
42-cub3d-c786ace26fb4a041a43b2149b61c11b1c75ba1ca.zip
Some threads
Diffstat (limited to 'src/ft_draw_ammo_back.c')
-rw-r--r--src/ft_draw_ammo_back.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/ft_draw_ammo_back.c b/src/ft_draw_ammo_back.c
index b9bb408..767127d 100644
--- a/src/ft_draw_ammo_back.c
+++ b/src/ft_draw_ammo_back.c
@@ -19,20 +19,20 @@ static void
const uint16_t scl = cl->mlist.scale;
cl->img.ptr[x * 4 +
- (cl->img.sizeline * (y + cl->wlist.y_size -
+ (cl->img.sizeline * (y + cl->wlist.y_size -
(2 * ((cl->mlist.map_h * scl)) + 20)))] =
- (uint8_t)cl->tlist[16].ptr[cl->tlist[16].tex_x * 4 + 4 *
- cl->tlist[16].img_w * cl->tlist[16].tex_y];
+ (uint8_t)cl->tlist[16].ptr[cl->tlist[16].tex_x_alt * 4 + 4 *
+ cl->tlist[16].img_w * cl->tlist[16].tex_y_alt];
cl->img.ptr[x * 4 +
(cl->img.sizeline * (y + cl->wlist.y_size -
(2 * ((cl->mlist.map_h * scl)) + 20))) + 1] =
- (uint8_t)cl->tlist[16].ptr[cl->tlist[16].tex_x * 4 + 4 *
- cl->tlist[16].img_w * cl->tlist[16].tex_y + 1];
+ (uint8_t)cl->tlist[16].ptr[cl->tlist[16].tex_x_alt * 4 + 4 *
+ cl->tlist[16].img_w * cl->tlist[16].tex_y_alt + 1];
cl->img.ptr[x * 4 +
(cl->img.sizeline * (y + cl->wlist.y_size -
(2 * ((cl->mlist.map_h * scl)) + 20))) + 2] =
- (uint8_t)cl->tlist[16].ptr[cl->tlist[16].tex_x * 4 + 4 *
- cl->tlist[16].img_w * cl->tlist[16].tex_y + 2];
+ (uint8_t)cl->tlist[16].ptr[cl->tlist[16].tex_x_alt * 4 + 4 *
+ cl->tlist[16].img_w * cl->tlist[16].tex_y_alt + 2];
}
static void
@@ -48,11 +48,11 @@ static void
y = 0;
while (y < cl->amm_back_h)
{
- cl->tlist[16].tex_y = ((y * y_ratio) >> 16);
+ cl->tlist[16].tex_y_alt = ((y * y_ratio) >> 16);
x = 0;
while (x < cl->amm_back_w)
{
- cl->tlist[16].tex_x = ((x * x_ratio) >> 16);
+ cl->tlist[16].tex_x_alt = ((x * x_ratio) >> 16);
ft_draw_back(y, x, cl);
x++;
}