KRHS-Game-Programming-2022 / The-Oak-House

0 stars 0 forks source link

Escape Key + wall collisions #1

Open Tshep9 opened 2 years ago

Tshep9 commented 2 years ago

It would be nice if when you press the escape key, the game quits. You could handle that simply by adding

    for event in pygame.event.get():
        if event.type == pygame.QUIT:
            sys.exit()
        if event.type == pygame.KEYDOWN:
            if event.key == pygame.K_ESCAPE:
                mode = "main menu"

Also, wall collisions are not currently happening; I am unsure whether or not that has been developed yet.

Great game overall!

Pulled 9:22 AM, May 13 2022

BobRoss65 commented 2 years ago

I have just added your recommendation