Un petit jeu réalisé avec pgzero
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

пре 3 година
пре 3 година
пре 3 година
пре 3 година
пре 3 година
пре 3 година
пре 3 година
пре 3 година
12345678910111213141516171819202122232425262728
  1. import pgzrun
  2. TITLE = "Paf l'oiseau"
  3. WIDTH = 400
  4. HEIGHT = 708
  5. def on_mouse_down(button):
  6. print('Clic', button)
  7. if button == mouse.RIGHT :
  8. titi.speed += 1
  9. elif button == mouse.LEFT :
  10. titi.speed -= 1
  11. def update():
  12. titi.x += titi.speed
  13. if titi.left > WIDTH :
  14. titi.right = 0
  15. if titi.right < 0 :
  16. titi.left = WIDTH
  17. def draw():
  18. screen.blit('background', (0, 0))
  19. titi.draw()
  20. titi = Actor('bird1', (75, 350))
  21. titi.speed = 1
  22. pgzrun.go()