Commit 1fd5bd40 by BellCodeEditor

save project

parent cae59c74
Showing with 2 additions and 6 deletions
......@@ -32,7 +32,6 @@ y = 400
jumpState = "runing"
t = 30
obstacle=Block(bush,cacti,stone)
obstacle_time
while True:
for event in pygame.event.get():
......@@ -74,11 +73,8 @@ while True:
lu_x=0
screen.blit(road, (lu_x, 500)) # 路
screen.blit(wukong, (150, y)) # 悟空
obstacle_time +=1
if obstacle_time>60:
obstacle_time = 60
num = random.randint(0,50)
# 障碍物消失
if obstacle.rect.x <= 0-obstacle.rect.width: # 障碍物消失
# 创建障碍物对象
obstacle=Block(bush,cacti,stone)
obstacle.rect.x -= 8
......
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