From 09a1647197ec83daf33883deaa9bb8eb65711159 Mon Sep 17 00:00:00 2001 From: EKNr1 Date: Tue, 27 Feb 2024 20:38:15 +0100 Subject: [PATCH] Added some comments. --- gd_pygame.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gd_pygame.py b/gd_pygame.py index e57d3dd..36270a4 100644 --- a/gd_pygame.py +++ b/gd_pygame.py @@ -43,7 +43,7 @@ class GDPygame: self.floor_texture = pygame.image.load("assets/textures/floors/floor_01.png") # textures self.floor_texture = pygame.transform.scale(self.floor_texture, (self.floor_texture.get_width() * 4, self.floor_texture.get_height() * 4)) self.background_texture = pygame.image.load("assets/textures/backgrounds/background_01.png") - self.background_texture = pygame.transform.scale(self.background_texture, (self.background_texture.get_width() * ((self.screen.get_height() - self.floor_texture.get_height()) // self.background_texture.get_height()), self.screen.get_height() - self.floor_texture.get_height())) + self.background_texture = pygame.transform.scale(self.background_texture, (self.background_texture.get_width() * ((self.screen.get_height() - self.floor_texture.get_height()) // self.background_texture.get_height()), self.screen.get_height() - self.floor_texture.get_height())) # properly scale the background # loading finished self.window.size = self.settings.window_size @@ -72,7 +72,7 @@ class GDPygame: if not self.running: return - if self.loading_surface.get_alpha() > 0: + if self.loading_surface.get_alpha() > 0: # make the loading screen fade out self.screen.blit(self.loading_surface, (0, 0)) self.loading_surface.set_alpha(self.loading_surface.get_alpha() - 4)