When I go to close the program window, the program freezes and then I am forced to exit the program. Why the program does not close when you press the X / Close button. I also use python 2.7 if that matters.
import pygame
import os, sys
from itertools import *
from oryxsprites import *
from oryxbackground import *
running = True
while running:
backgroundmain()
pygame.display.set_caption('OryxGame')
for event in pygame.event.get():
if event.type == pygame.QUIT:
running = False
source
share