Commit 3a80a0e0 by BellCodeEditor

save project

parent fcd22ed3
Showing with 10 additions and 2 deletions
......@@ -3,10 +3,18 @@ from pygame import locals as l
# 初始化pygame,为使用pygame做准备
p.init()
bg=p.image.load('bg.png')
apple=p.image.load('apple.png')
tou=p.image.load('right.png')
# 创建一个窗口
s=p.display.set_mode((660,480))
while 1:
for event in p.event.get():
print(event)
if event.type == l.QUIT:
exit()
\ No newline at end of file
exit()
s.blit(bg,(0,0))
s.blit(apple,(330,240))
s.blit(tou,(220,160))
p.display.update()
\ 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