Sep-29-2017, 02:47 PM
Hey Programmers...
I Try to load an image in pygame... This is my script:
load slowly.... the image is not so big, but my game (or simple test) are craching...
Can anyone help me ?...
Thanks for help, Jamie...
I Try to load an image in pygame... This is my script:
import pygame import sys screen = pygame.display.set_mode((800,600)) done = False while not done: for event in pygame.event.get(): if event.type == pygame.QUIT: done = True elif event.type == pygame.KEYDOWN: if event.key == pygame.K_ESCAPE: done = True pygame.image.load(os.path.join('C:/Users/Gebruiker/Desktop/Renders', 'Render.png')) screen.fill((255,255,255)) pygame.display.update() pygame.quit() sys.exit() for event in pygame.event.get(): if event.type == pygame.KEYDOWN: if event.key == pygame.K_SPACE: screen.fill((255,000,000)) pygame.display.update()If i run this script... the display screen of my game (simple test) is black and the image
load slowly.... the image is not so big, but my game (or simple test) are craching...
Can anyone help me ?...
Thanks for help, Jamie...