Merge branch 'master' of github.com:lvl2/avocados
commit
a111367e53
6
game.py
6
game.py
|
@ -30,7 +30,7 @@ def main():
|
||||||
# initialize_screen() won't work for dualscreen
|
# initialize_screen() won't work for dualscreen
|
||||||
#size = initialize_screen()
|
#size = initialize_screen()
|
||||||
size = (800, 600)
|
size = (800, 600)
|
||||||
bg = BLACK
|
bg = pygame.image.load("img/background.png")
|
||||||
desired_fps = 10
|
desired_fps = 10
|
||||||
font = pygame.font.Font(None, 40)
|
font = pygame.font.Font(None, 40)
|
||||||
|
|
||||||
|
@ -60,7 +60,11 @@ def main():
|
||||||
while running:
|
while running:
|
||||||
time_passed = clock.tick(desired_fps)
|
time_passed = clock.tick(desired_fps)
|
||||||
fps = clock.get_fps()
|
fps = clock.get_fps()
|
||||||
|
if type(bg) is tuple:
|
||||||
screen.fill(bg)
|
screen.fill(bg)
|
||||||
|
else:
|
||||||
|
screen.blit(pygame.transform.scale(bg,(800,600)),(0,0))
|
||||||
|
|
||||||
|
|
||||||
# Let's add the lawyer and have him announce a color
|
# Let's add the lawyer and have him announce a color
|
||||||
fullegast.setColor(color)
|
fullegast.setColor(color)
|
||||||
|
|
Loading…
Reference in New Issue