don't draw the shotgun icon in hud mode if it won't fit and crop the lg

icon
This commit is contained in:
Bill Currie 2003-05-10 04:20:21 +00:00
parent 23e47863c4
commit 9b9c435e47
2 changed files with 5 additions and 5 deletions

View file

@ -520,7 +520,7 @@ draw_weapons_hud (view_t *view)
{
int flashon, i;
for (i = 0; i < 7; i++) {
for (i = vid.conheight < 204; i < 7; i++) {
if (cl.stats[STAT_ITEMS] & (IT_SHOTGUN << i)) {
flashon = calc_flashon (cl.item_gettime[i], IT_SHOTGUN << i);
draw_subpic (view, 0, i * 16, sb_weapons[flashon][i], 0, 0, 24, 16);
@ -746,7 +746,7 @@ draw_rogue_weapons_hud (view_t *view)
int flashon, i, j;
qpic_t *pic;
for (i = 0; i < 7; i++) {
for (i = vid.conheight < 204; i < 7; i++) {
if (cl.stats[STAT_ITEMS] & (IT_SHOTGUN << i)) {
flashon = calc_flashon (cl.item_gettime[i], IT_SHOTGUN << i);
if (i >= 2) {
@ -968,7 +968,7 @@ draw_hipnotic_weapons_hud (view_t *view)
}
if (pic)
draw_pic (view, 0, y[i], pic);
draw_subpic (view, 0, y[i], pic, 0, 0, 24, 16);
if (flashon > 1)
sb_updates = 0; // force update to remove flash

View file

@ -650,10 +650,10 @@ draw_weapons_hud (view_t *view)
if (view->parent->gravity == grav_southeast)
x = view->xlen - 24;
for (i = 0; i < 7; i++) {
for (i = vid.conheight < 204; i < 7; i++) {
if (cl.stats[STAT_ITEMS] & (IT_SHOTGUN << i)) {
flashon = calc_flashon (i);
draw_pic (view, x, i * 16, sb_weapons[flashon][i]);
draw_subpic (view, x, i * 16, sb_weapons[flashon][i], 0, 0, 24, 16);
if (flashon > 1)
sb_updates = 0; // force update to remove flash
}