Skip to content

Commit

Permalink
Merge branch 'master' of github.com:andrewsmedina/pyweek2010
Browse files Browse the repository at this point in the history
  • Loading branch information
diofeher committed Aug 26, 2010
2 parents 9086001 + 6baae75 commit afd05f1
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions jailbreakerz/game.py
Expand Up @@ -37,7 +37,7 @@ def load_sprites(self):
self.add(self.prison)

self.kombi = Sprite('media/imgs/kombi.png')
self.kombi.position = 700,90
self.kombi.position = 790,90
self.add(self.kombi)


Expand All @@ -59,10 +59,10 @@ def fall(self):


class Catcher(Layer):

is_event_handler = True

MOVEMENT_RATE = 50 # Constant used to move sprite
MOVEMENT_RATE = 100 # Constant used to move sprite

def __init__(self, *args, **kwargs):
super(Catcher, self).__init__()
Expand All @@ -71,9 +71,9 @@ def __init__(self, *args, **kwargs):
self.add(self.catcher)

def on_key_press(self, key, modifiers):
if key == pyglet.window.key.LEFT:
if key == pyglet.window.key.LEFT and self.catcher.position[0] > 300:
self.catcher.position = self.catcher.position[0] - self.MOVEMENT_RATE, self.catcher.position[1]
elif key == pyglet.window.key.RIGHT:
elif key == pyglet.window.key.RIGHT and self.catcher.position[0] < 500:
self.catcher.position = self.catcher.position[0] + self.MOVEMENT_RATE, self.catcher.position[1]

if __name__ == '__main__':
Expand Down
2 changes: 1 addition & 1 deletion jailbreakerz/jailbreakerz.py
Expand Up @@ -58,7 +58,7 @@ def __init__(self):

self.create_menu(items)

sound.player.queue(pyglet.resource.media('media/sounds/menu.mp3'))
sound.player.queue(pyglet.resource.media('media/sounds/fundogame.mp3'))
sound.player.eos_action = 'loop'
sound.player.play()

Expand Down
Binary file removed jailbreakerz/media/sounds/fundogame.aif
Binary file not shown.
Binary file removed jailbreakerz/media/sounds/jump.aif
Binary file not shown.
Binary file removed jailbreakerz/media/sounds/menu.mp3
Binary file not shown.
Binary file removed jailbreakerz/media/sounds/yupi.wav
Binary file not shown.

0 comments on commit afd05f1

Please sign in to comment.