0

sorry about my post on pygame, but i'm having more trouble. frist off im ending the simple program that opens a window with
if event.type == QUIT:
raise SystemExit
That makes a window pop up asking me if i want to quit. Is there another way to exit the window?

I also figured that be able to toggle to fullscreen would help when making a game. I'll do something like
elif event.type == KEYDOWN and event.key == K_ESCAPE:
pygame.display.toggle_fullscreen()
and nothing happens. I havent had much time to look this up.
Thanks

2
Contributors
1
Reply
3
Views
12 Years
Discussion Span
Last Post by vegaseat
0

To quit your game try something like ...

pygame.quit()

This will clean things up before quitting.
I know sys.exit() works, but you have to import sys.

On your second problem I can only guess. You may need to update your screen with a ...

pygame.display.flip()
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.