aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_draw_ammo_bar.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ft_draw_ammo_bar.c')
-rw-r--r--src/ft_draw_ammo_bar.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/ft_draw_ammo_bar.c b/src/ft_draw_ammo_bar.c
index bf8dbda..febeb55 100644
--- a/src/ft_draw_ammo_bar.c
+++ b/src/ft_draw_ammo_bar.c
@@ -22,18 +22,18 @@ static void
cl->img.ptr[(x + 10) * 4 +
(cl->img.sizeline * (int)(y + ((cl->wlist.y_size - 10) -
(2 * ((cl->mlist.map_h * scl) / 1.3)) - 40)))] =
- (uint8_t)cl->tnum[id].ptr[cl->tnum[id].tex_x * 4 + 4 *
- cl->tnum[id].img_w * cl->tnum[id].tex_y];
+ (uint8_t)cl->tnum[id].ptr[cl->tnum[id].tex_x_alt * 4 + 4 *
+ cl->tnum[id].img_w * cl->tnum[id].tex_y_alt];
cl->img.ptr[(x + 10) * 4 +
(cl->img.sizeline * (int)(y + ((cl->wlist.y_size - 10) -
(2 * ((cl->mlist.map_h * scl) / 1.3)) - 40))) + 1] =
- (uint8_t)cl->tnum[id].ptr[cl->tnum[id].tex_x * 4 + 4 *
- cl->tnum[id].img_w * cl->tnum[id].tex_y + 1];
+ (uint8_t)cl->tnum[id].ptr[cl->tnum[id].tex_x_alt * 4 + 4 *
+ cl->tnum[id].img_w * cl->tnum[id].tex_y_alt + 1];
cl->img.ptr[(x + 10) * 4 +
(cl->img.sizeline * (int)(y + ((cl->wlist.y_size - 10) -
(2 * ((cl->mlist.map_h * scl) / 1.3)) - 40))) + 2] =
- (uint8_t)cl->tnum[id].ptr[cl->tnum[id].tex_x * 4 + 4 *
- cl->tnum[id].img_w * cl->tnum[id].tex_y + 2];
+ (uint8_t)cl->tnum[id].ptr[cl->tnum[id].tex_x_alt * 4 + 4 *
+ cl->tnum[id].img_w * cl->tnum[id].tex_y_alt + 2];
}
static void
@@ -49,13 +49,13 @@ static void
y = 0;
while (y < cl->ammo_num_h)
{
- cl->tnum[n - 48].tex_y = ((y * y_ratio) >> 16);
+ cl->tnum[n - 48].tex_y_alt = ((y * y_ratio) >> 16);
x = 0;
while (x < cl->ammo_num_w)
{
- cl->tnum[n - 48].tex_x = ((x * x_ratio) >> 16);
- if (cl->tnum[n - 48].ptr[cl->tnum[n - 48].tex_x * 4 + 4 *
- cl->tnum[n - 48].img_h * cl->tnum[n - 48].tex_y])
+ cl->tnum[n - 48].tex_x_alt = ((x * x_ratio) >> 16);
+ if (cl->tnum[n - 48].ptr[cl->tnum[n - 48].tex_x_alt * 4 + 4 *
+ cl->tnum[n - 48].img_h * cl->tnum[n - 48].tex_y_alt])
ft_draw_tnum(n - 48, y, x + x_offset, cl);
x++;
}