Commit 66680eac by BellCodeEditor

auto save

parent 6be90027
Showing with 3 additions and 5 deletions
......@@ -20,7 +20,6 @@ index = 0
y = 400
jumpstate='running'
pygame.display.set_caption('悟空酷跑')
t=30
while True:
for event in pygame.event.get():
if event.type == locals.QUIT:
......@@ -30,13 +29,12 @@ while True:
if event.key == locals.K_SPACE:
jumpstate="up"
if jumpstate=="up":
if t>0:
y+=t
t-=2
if y>150:
y-=5
else:
jumpstate="diomn"
if jumpstate=="diomn":
if t<400:
if y<400:
y+=5
else:
jumpstate="running"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment