Re: PyGame, window is not closing, tut not helping

2008-05-12 Thread JL
If the game runs normally without IDLE, then, to run it from IDLE, add pygame.quit() at the end of the script: if __name__ == "__main__": MainWindow = PyManMain() MainWindow.MainLoop() pygame.quit() ... and just before the sys.exit(): def MainLoop(self): """This is the Ma

Re: PyGame, window is not closing, tut not helping

2008-05-01 Thread Mike Driscoll
On May 1, 10:55 am, globalrev <[EMAIL PROTECTED]> wrote: > im doing this > :http://www.learningpython.com/2006/03/12/creating-a-game-in-python-us... > > and when closing the program the window stays up and doesnt respond. i > tried adding this:http://www.pygame.org/wiki/FrequentlyAskedQuestions >

Re: PyGame, window is not closing, tut not helping

2008-05-01 Thread globalrev
another program that has the same problem: import sys, pygame pygame.init() size = width, height = 320, 240 speed = [2, 2] black = 0, 0, 0 screen = pygame.display.set_mode(size) ball = pygame.image.load("snake.png") ballrect = ball.get_rect() while 1: for event in pygame.event.get():

PyGame, window is not closing, tut not helping

2008-05-01 Thread globalrev
im doing this : http://www.learningpython.com/2006/03/12/creating-a-game-in-python-using-pygame-part-one/ and when closing the program the window stays up and doesnt respond. i tried adding this: http://www.pygame.org/wiki/FrequentlyAskedQuestions bu it doesnt work, or maybe im doing it wrong. h