From 29aea5bec4e4a49499e6508cf0ff5c4d8016f03b Mon Sep 17 00:00:00 2001 From: GeorgeTom17 <51702013+GeorgeTom17@users.noreply.github.com> Date: Tue, 7 Jun 2022 21:36:31 +0200 Subject: [PATCH 1/2] credits screen --- ui/screens/credits.py | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/ui/screens/credits.py b/ui/screens/credits.py index 158cafd..097e1e4 100644 --- a/ui/screens/credits.py +++ b/ui/screens/credits.py @@ -1,6 +1,31 @@ +import pygame + from ui.screens.screen import Screen +from common.colors import WHITE +from common.helpers import draw_text class Credits(Screen): + def __init__(self, screen, clock): super().__init__('credits', screen, clock) + + def display_screen(self): + running = True + while running: + self.screen.fill((0, 0, 0)) + draw_text('Angelika Iskra', WHITE, self.screen, 20, 50) + draw_text('Dawid Korzępa', WHITE, self.screen, 20, 100) + draw_text('Juliusz Sadowski', WHITE, self.screen, 20, 150) + draw_text('Aleksandra Muczyńska', WHITE, self.screen, 20, 200) + draw_text('Jerzy Tomaszewski', WHITE, self.screen, 20, 250) + draw_text('Mateusz Konofał', WHITE, self.screen, 20, 300) + for event in pygame.event.get(): + if event.type == pygame.QUIT: + running = False + if event.type == pygame.KEYDOWN: + if event.key == pygame.K_ESCAPE: + running = False + pygame.display.update() + self.clock.tick(60) + -- 2.20.1 From 1482730bee603f435be200877c896d28e4796d4b Mon Sep 17 00:00:00 2001 From: GeorgeTom17 <51702013+GeorgeTom17@users.noreply.github.com> Date: Tue, 7 Jun 2022 22:36:13 +0200 Subject: [PATCH 2/2] visual changes --- ui/screens/credits.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/ui/screens/credits.py b/ui/screens/credits.py index 097e1e4..ffb1129 100644 --- a/ui/screens/credits.py +++ b/ui/screens/credits.py @@ -1,10 +1,9 @@ import pygame from ui.screens.screen import Screen -from common.colors import WHITE +from common.colors import BLACK from common.helpers import draw_text - class Credits(Screen): def __init__(self, screen, clock): @@ -13,13 +12,14 @@ class Credits(Screen): def display_screen(self): running = True while running: - self.screen.fill((0, 0, 0)) - draw_text('Angelika Iskra', WHITE, self.screen, 20, 50) - draw_text('Dawid Korzępa', WHITE, self.screen, 20, 100) - draw_text('Juliusz Sadowski', WHITE, self.screen, 20, 150) - draw_text('Aleksandra Muczyńska', WHITE, self.screen, 20, 200) - draw_text('Jerzy Tomaszewski', WHITE, self.screen, 20, 250) - draw_text('Mateusz Konofał', WHITE, self.screen, 20, 300) + self.screen.fill((252, 164, 12)) + draw_text('Twórcy :', BLACK, self.screen, 520, 150) + draw_text('Angelika Iskra', BLACK, self.screen, 520, 250) + draw_text('Dawid Korzępa', BLACK, self.screen, 520, 300) + draw_text('Juliusz Sadowski', BLACK, self.screen, 520, 350) + draw_text('Aleksandra Muczyńska', BLACK, self.screen, 520, 400) + draw_text('Jerzy Tomaszewski', BLACK, self.screen, 520, 450) + draw_text('Mateusz Konofał', BLACK, self.screen, 520, 500) for event in pygame.event.get(): if event.type == pygame.QUIT: running = False -- 2.20.1