0

I am trying to make my first pygame project and I import pygame and I am getting error. I instilled it before some minutes in my PC.

import pygame
from pygame import mixer

pygame.init()

WIDTH = 1920
HEIGHT = 1080

black = (0, 0, 0)
white = (255, 255, 255)
gray = (128, 128, 128)
screen = pygame.display.set_mode([WIDTH, HEIGHT])
pygame.display.set_caption('Beat Maker')
label_font = pygame.font.Font('freesansbold.ttf', 32)
fps = 60
timer = pygame.time.Clock()
run = True
while run:
    timer.tick(fps)
    screen.fill(black)

    for event in pygame.event.get():
        if event.type == pygame.QUIT:
            run = False

    pygame.display.flip()
pygame.quit()
martineau
  • 112,593
  • 23
  • 157
  • 280
KOUZ
  • 1

0 Answers0