Skip to content

Commit

Permalink
Initialize defender pixmap contents in hud_unit_combat
Browse files Browse the repository at this point in the history
Otherwise it was showing garbage.

Closes #1185.
  • Loading branch information
lmoureaux authored and jwrober committed Aug 8, 2022
1 parent 377a96c commit ae8d8ef
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions client/hudwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,7 @@ void hud_unit_combat::init_images(bool redraw)
setFixedSize(2 * w, w);
QPixmap defender_pixmap(tileset_unit_width(tileset),
tileset_unit_height(tileset));
defender_pixmap.fill(Qt::transparent);
if (defender != nullptr) {
if (!redraw) {
put_unit(defender, &defender_pixmap, 0, 0);
Expand Down

0 comments on commit ae8d8ef

Please sign in to comment.