added title screen loading at launch
This commit is contained in:
@@ -2,11 +2,15 @@ import pygame
|
||||
|
||||
|
||||
class Surface(pygame.Surface):
|
||||
def __init__(self, window_size):
|
||||
def __init__(self, window_size, resources_dir):
|
||||
super().__init__(window_size, pygame.SRCALPHA)
|
||||
self.running = True
|
||||
self.next_surface = None
|
||||
|
||||
def update(self):
|
||||
self.fill((0, 0, 0))
|
||||
self.bg = pygame.image.load(resources_dir + '/images/bg.png').convert_alpha()
|
||||
self.title = pygame.image.load(resources_dir + '/images/title.png').convert_alpha()
|
||||
|
||||
def update(self):
|
||||
self.blit(self.bg, (0, 0))
|
||||
self.blit(self.title, (0, 0))
|
||||
|
||||
|
Reference in New Issue
Block a user