Commit 0ff4a7c6 by BellCodeEditor

save project

parent e0039c18
Showing with 4 additions and 4 deletions
......@@ -13,7 +13,7 @@ background = pygame.image.load('bg.png')
right = pygame.image.load('right.png')
food = pygame.image.load('apple.png')
body = pygame.image.load('body.png')
fps=pygame.time.clock()
fps=pygame.time.Clock()
while True:
for event in pygame.event.get():
if event.type == locals.QUIT:
......@@ -24,7 +24,7 @@ while True:
screen.blit(background, (0, 0))
# 将贪吃蛇画上去
screen.blit(right, (240, 120))
screen.blit(right, (x, y))
# 将贪吃蛇的身体画上去
screen.blit(body, (210, 120))
screen.blit(body, (180, 120))
......@@ -34,4 +34,4 @@ while True:
# 刷新画面
pygame.display.update()
fps.tick(3)
\ No newline at end of file
fps.tick(50)
\ 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