Commit d0afca57 by BellCodeEditor

save project

parent e82a096c
Showing with 3 additions and 0 deletions
......@@ -61,6 +61,7 @@ while True:
if x == apple_x and y == apple_y:
apple_x = num_x*30-30
apple_y = num_y*30-30
score += 1
else:
position.pop(0)
# 将背景图画上去
......@@ -78,6 +79,8 @@ while True:
info = "Score" + str(score)
text = my_font.render(info,True,(0,0,0))
screen.blit(text,(540,10))
if x < 0 or x > 630 or y < 0 or y > 450:
exit()
# 刷新画面
pygame.display.update()
FPSCLOCK.tick(3)
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