Commit 94aacbd7 by BellCodeEditor

auto save

parent 5b9992d9
Showing with 12 additions and 3 deletions
...@@ -4,12 +4,20 @@ import pygame ...@@ -4,12 +4,20 @@ import pygame
from pygame import locals from pygame import locals
# 初始化pygame,为使用pygame做准备 # 初始化pygame,为使用pygame做准备
pygame.init() pygame.init()
# 创建一个窗口 # 创建一个窗口
screen=pygame.display.set_mode((660,480)) screen=pygame.display.set_mode((660,480))
background=pygame.image.load('bg.png')
right=?
food=?
body=?
while True: while True:
#对pygame里的事件进行遍历 #对pygame里的事件进行遍历
#判断是否按下退出键 #判断是否按下退出键
#退出程序 #退出程序
screen.blit(background,(0,0))
#蛇头right(240,120)
#身体
#身体
#身体
#食物food(360,300)
#刷新画面
\ 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