From 2788d352d0118a48ad449ecf659c00335f55ed4b Mon Sep 17 00:00:00 2001 From: Berger Lena Date: Thu, 7 May 2026 22:14:52 +0200 Subject: [PATCH] feature: HUD - create new hud.py file - add zombie difficulty stats (easy, medium, hard) to settings - add coffee item stats (cost and heal value) to settings - add HUD configuration (font, colors, dimensions) to settings - reorganize HP bar colors into the new HUD settings section --- src/hud.py | 0 src/settings.py | 41 ++++++++++++++++++++++++++++++++++++----- 2 files changed, 36 insertions(+), 5 deletions(-) create mode 100644 src/hud.py diff --git a/src/hud.py b/src/hud.py new file mode 100644 index 0000000..e69de29 diff --git a/src/settings.py b/src/settings.py index 138b39e..db283ad 100644 --- a/src/settings.py +++ b/src/settings.py @@ -10,13 +10,44 @@ DOOR_BORDER_WIDTH = 3 COLOR_DOOR_BEIGE = (245, 245, 220) COLOR_DOOR_BORDER = (100, 90, 80) -COLOR_HP_BAR_GREEN = (0, 255, 0) -COLOR_HP_BAR_BG = (50, 50, 50) # --- ECTS --- -START_ECTS_VALUE = 1 # how many ECTS are generated at the beginning -ECTS_UPDATE_INTERVAL = 1000 # time in ms = 1 sec +START_ECTS_VALUE = 1 # how many ECTS are generated at the beginning +ECTS_UPDATE_INTERVAL = 1000 # time in ms = 1 sec BEER_BOTTLE_ECTS_VALUE = 2 -BEER_COST = 50 \ No newline at end of file +BEER_COST = 50 + + +# --- COFFEE --- +COFFEE_COST = 30 +COFFEE_HEAL_VALUE = 30 + + +# -- ZOMBIE --- +ZOMBIE_EASY_HP = 30 +ZOMBIE_EASY_DMG = 3 + +ZOMBIE_MEDIUM_HP = 60 +ZOMBIE_MEDIUM_DMG = 7 + +ZOMBIE_HARD_HP = 120 +ZOMBIE_HARD_DMG = 12 + + +# --- HUD --- +HUD_FONT = "Arial" +HUD_FONT_SIZE = 22 +HUD_FONT_BOLD = True + +COLOR_HUD_TEXT = (255, 255, 255) +COLOR_HUD_SHOP_TEXT = (200, 200, 200) + +COLOR_HP_BAR_GREEN = (0, 255, 0) +COLOR_HP_BAR_BG = (50, 50, 50) +COLOR_HP_BAR_RED = (200, 0, 0) +COLOR_HP_BAR_YELLOW = (255, 255, 0) + +HUD_BAR_WIDTH = 100 +HUD_BAR_HEIGHT = 15 \ No newline at end of file