Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 34 lines (27 sloc) 0.92 kB
a39b9f9 First Commit
Andrew Patrick Dudash authored
1 import pygame
2 from pygame.locals import *
3
4 import config
5 import content
6 import messenger
7 import camera
8
9 if __name__ == "__main__":
10 display = pygame.display.set_mode(config.DISPLAY_SIZE)
11 pygame.display.set_caption(config.GAME_TITLE)
12 pygame.init()
13 pygame.key.set_repeat(0, 1)
14 clock = pygame.time.Clock()
15
16 for key in content.IMAGE:
17 content.IMAGE[key] = content.IMAGE[key].convert()
18
19 while True:
20 clock.tick(30)
21 screen = messenger.Messenger.screen
22 camera = messenger.Messenger.camera
23 events = []
24
25 events = pygame.event.get()
26 for event in events:
27 if event.type == QUIT:
28 pygame.quit()
29 quit()
30
31 messenger.Messenger.mode.on_draw(display, screen, camera)
32 messenger.Messenger.mode.on_input(events)
33 messenger.Messenger.mode.on_update()
Something went wrong with that request. Please try again.