Added pygame to requiremens.txt
commit
1b07b502bb
|
@ -15,6 +15,7 @@ class Avocado:
|
||||||
self.has_been_pinned = False
|
self.has_been_pinned = False
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
print('New avocado is ' + ','.join(str(color)))
|
||||||
self.screen = screen
|
self.screen = screen
|
||||||
self.color = color
|
self.color = color
|
||||||
self.select = select
|
self.select = select
|
||||||
|
@ -81,8 +82,16 @@ class Avocado:
|
||||||
def hasLanded(self):
|
def hasLanded(self):
|
||||||
if self.rect.bottom > self.screen_height or self.rect.top < 0:
|
if self.rect.bottom > self.screen_height or self.rect.top < 0:
|
||||||
self.is_falling = False
|
self.is_falling = False
|
||||||
|
print('platch')
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
||||||
|
def mute(self,mute=False):
|
||||||
|
if mute:
|
||||||
|
pygame.mixer.music.set_volume(0.0)
|
||||||
|
else:
|
||||||
|
pygame.mixer.music.set_volume(0.5)
|
||||||
|
|
||||||
|
|
||||||
def destroy(self):
|
def destroy(self):
|
||||||
del(self)
|
del(self)
|
||||||
|
|
3
game.py
3
game.py
|
@ -10,6 +10,7 @@ from pygame.locals import *
|
||||||
from support.colors import *
|
from support.colors import *
|
||||||
from interface import hud
|
from interface import hud
|
||||||
|
|
||||||
|
|
||||||
def initialize_screen():
|
def initialize_screen():
|
||||||
displayInfo = pygame.display.Info()
|
displayInfo = pygame.display.Info()
|
||||||
zoom = 1.3
|
zoom = 1.3
|
||||||
|
@ -21,6 +22,8 @@ def initialize_screen():
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
pygame.init()
|
pygame.init()
|
||||||
|
pygame.mixer.init()
|
||||||
|
pygame.mixer.music.set_volume(0.5)
|
||||||
pygame.display.set_caption('Pin Avo, the Cado!')
|
pygame.display.set_caption('Pin Avo, the Cado!')
|
||||||
clock = pygame.time.Clock()
|
clock = pygame.time.Clock()
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
hg+https://bitbucket.org/pygame/pygame
|
Loading…
Reference in New Issue