Pārlūkot izejas kodu

modification du code

master
valdoucet pirms 3 gadiem
vecāks
revīzija
bddfb668e8
1 mainītis faili ar 10 papildinājumiem un 5 dzēšanām
  1. +10
    -5
      code.py

+ 10
- 5
code.py Parādīt failu

@@ -5,16 +5,21 @@ WIDTH = 490
HEIGHT = 490

d = 2
g = 1

def update():
global d
if oiseau.x >= 470 and d > 0:
d = -d
if oiseau.x <= 20 and d < 0:
d = -d
oiseau.x += d
if oiseau.y < 470:
oiseau.x += d
if oiseau.y < 470:
oiseau.y += d
if oiseau.y >= 470:
print("Game Over")


def on_mouse_down():
print ('')

def draw():
screen.blit("back", (0, 0))
oiseau.draw()


Notiek ielāde…
Atcelt
Saglabāt