Commit b5b5304d by BellCodeEditor

auto save

parent c6188a1e
Showing with 12 additions and 5 deletions
import pygame import pygame
from pygame import locals
# 初始化pygame,为使用pygame做准备
pygame.init() pygame.init()
# 初始化pygame,为使用pygame做准备
chuangkou=pygame.display.set_mode((800,600))
# 创建一个窗口 # 创建一个窗口
?? while True:
\ No newline at end of file #无限循环
for event in pygame.event.get():
#遍历pygame中的事件
if event.type==pygame.QUIT:
#如果pygame中的事件等于退出窗口
exit()
#接收到退出事件后退出程序
\ 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