-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcoder.py
More file actions
35 lines (30 loc) · 892 Bytes
/
coder.py
File metadata and controls
35 lines (30 loc) · 892 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import os, sys
import pygame
import state_manager
import game
import menu
import about
import quit_
import consts
import bugreport
import splash
import highscore
import locations
def init():
pygame.mixer.pre_init(44100, -16, 2, 4096)
pygame.mixer.init()
pygame.init()
pygame.display.set_icon(pygame.image.load(locations.image('coder-icon.png')))
screen = pygame.display.set_mode((consts.SCREEN_W, consts.SCREEN_H))#, pygame.DOUBLEBUF)
pygame.display.set_caption('CODER a game for the #MetaGameJam 17. - 31. March 2018', 'c0d3r')
pygame.mouse.set_visible(0)
return screen
if __name__ == '__main__':
try:
sm = state_manager.StateManager(init())
sm.add_state(splash.Splash())
sm.change_state(splash.Splash)
sm.main_loop()
pygame.quit()
except:
bugreport.bugreport()