Browse Source

Challenge-1 ok

chapitre-1-challenge-1
Cleason 3 years ago
parent
commit
fc3bc487ce
1 changed files with 9 additions and 7 deletions
  1. +9
    -7
      birdie.py

+ 9
- 7
birdie.py View File

@@ -13,16 +13,18 @@ def draw():
screen.blit('background', (0, 0)) screen.blit('background', (0, 0))
titi.draw() titi.draw()


def on_mouse_up():
print('Clic souris !')
titi.y -= 50 # équivalent à titi.y = titi.y - 50
# def on_mouse_up():
# print('Clic souris !')
# titi.y -= 50 # équivalent à titi.y = titi.y - 50



def update(): def update():
titi.y += titi.speed
titi.x += titi.speed

# if titi.x > WIDTH :
# titi.x = 0


if titi.y > 400 :
titi.y = 0


titi.speed = 1
titi.speed = 3


pgzrun.go() pgzrun.go()

Loading…
Cancel
Save