Commit b01a1848 by BellCodeEditor

auto save

parent 72684a0c
Showing with 9 additions and 2 deletions
......@@ -6,7 +6,7 @@ pygame.init()
# 创建一个窗口
screen = pygame.display.set_mode((660, 480))
asdfk=pygame.time.Clock()
FPSCLOCK=pygame.time.Clock()
# 背景
background = pygame.image.load('bg.png')
right = pygame.image.load('right.png')
......@@ -29,5 +29,12 @@ while True:
# 将贪吃蛇画上去
qwer.append((x,y))
qwer.pop(0)
screen.blit(right, (x,y))
screen.blit(right,qwer[-1])
for i in range(len(qwer)-1):
screen.blit(body,qwer[i])
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