0

This is the code:

import pygame, sys
from pygame.locals import *

pygame.init()
DISPLAYSURF = pygame.display.setmode((400, 300))
pygame.display.set_caption('Hello World!')
while True: # Main game loop
    for event in pygame.event_get():
        if event.type == QUIT:
            pygame.quit()
            sys.exit()
            pygame.display.update()

I am getting this error:

TypeError: function missing required argument 'dest' (pos 2) error

While running the code.

NickS1
  • 496
  • 1
  • 6
  • 19

1 Answers1

0

You are missing a parameter called dest from your function call which presumably stands for destination. In order to solve the issue you will need to find the line where the problem occurred, look at the problematic function call and pass correctly the second parameter. If you need further information, then add actual code into your question along with the line where the issue occurred.

Lajos Arpad
  • 64,414
  • 37
  • 100
  • 175