Skip to content

Commit

Permalink
fix a problem blitting shield icon
Browse files Browse the repository at this point in the history
  • Loading branch information
bydariogamer committed Dec 22, 2022
1 parent 97d609e commit 8719d02
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -351,8 +351,8 @@ async def level_loop():
global clock, display, display_rect, game, FONTS, SONGS, state, player

heart = pygame.image.load(config.HEART_ICON)
shield = pygame.image.load(config.SHIELD_ICON)
shield.set_colorkey((255, 255, 255))
shield_icon = pygame.image.load(config.SHIELD_ICON)
shield_icon.set_colorkey((255, 255, 255))
damage = pygame.Surface((config.DISP_WID, config.DISP_HEI))
damage.fill((20, 0, 0, 30))
time_started = None
Expand Down Expand Up @@ -397,7 +397,7 @@ async def level_loop():
game.blit(lifes, lifes_rect.topleft)
game.blit(heart, (lifes_rect.right, lifes_rect.center[1] - 14))
game.blit(shield, (lifes_rect.left, lifes_rect.top + 30))
game.blit(shield, (lifes_rect.right, lifes_rect.center[1] + 16))
game.blit(shield_icon, (lifes_rect.right, lifes_rect.center[1] + 16))
score = FONTS["small"].render(
str(int(player.score)), False, colors.neon["orange"]
)
Expand Down

0 comments on commit 8719d02

Please sign in to comment.