[Interne] Conversion des images
This commit is contained in:
parent
00197ad287
commit
b48dc63872
@ -25,7 +25,9 @@ class Game():
|
||||
self.running = True
|
||||
self.init_inputs()
|
||||
self.gameloop = gameloop.GameLoop() # Je crée une boucle de jeu
|
||||
self.sprite_lib = self.init_assets("gamedata/assets/",pygame.image.load) # Dico qui contient chaques images du dossier assets
|
||||
def load_image(filename):
|
||||
return pygame.image.load(filename).convert_alpha()
|
||||
self.sprite_lib = self.init_assets("gamedata/assets/",load_image) # Dico qui contient chaques images du dossier assets
|
||||
pygame.display.set_icon(self.sprite_lib["icon.png"])
|
||||
self.sound_lib = self.init_assets("gamedata/sounds/",pygame.mixer.Sound) # Pareil, mais pour les musiques / sons
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user