Commit 6f898e98 by BellCodeEditor

save project

parent f298130e
Showing with 4 additions and 2 deletions
......@@ -42,9 +42,10 @@ road_x=0
screen_x=0
block_list=pygame.sprite.Group()
time=0
gamestate=True
while True:
while gamestate==True:
for event in pygame.event.get():
if event.type == locals.QUIT:
# 接收到退出事件后退出程序
......@@ -102,7 +103,7 @@ while True:
if pygame.sprite.collide_rect(wukong,sprite):
gameover=pygame.image.load('gameover.png')
screen.blit(gameover,(400,200))
print(len(block_list))
gamestate=False
# 刷新画面
pygame.display.update()
FPS.tick(60)
\ No newline at end of file
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