Commit 8a1308a7 by BellCodeEditor

save project

parent 080ee70a
Showing with 10 additions and 0 deletions
......@@ -18,6 +18,8 @@ hero = [pygame.image.load('hero1.png'),
pygame.image.load('hero3.png'),
pygame.image.load('hero4.png'),
pygame.image.load('hero5.png')]
lu_x=0
shan_x=0
index = 0
y = 400
jumpState = "runing"
......@@ -69,6 +71,14 @@ while True:
rect.x = 1000
rect.y = 500 - rect.height
rect.x -= 8
lu_x -=8
shan_x -=8
if lu_x <-1000:
lu_x=0
if shan_x <-1000:
shan_x=0
screen.blit(road,(shan_x,1000))
screen.blit(road,(lu_x,500))
screen.blit(obstacle, (rect.x, rect.y))
# 刷新画面
pygame.display.update()
......
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