xinxin -飞机大战1.0

# 1。导包
import pygame
# 2,初始化
pygame.init()
# 3。设置窗口大小
ping_mu = pygame.display.set_mode((400,700))
# 图片1 导入图片
beijin = pygame.image.load("beijing3.jpg")
huiji = pygame.image.load("huiji.png")
diji = pygame.image.load("diji2.png")
beijiny=0
dijiy=0
# 4。无限循环刷新
while 1>0:
   for i in pygame.event.get():
       if i.type == pygame.QUIT:
           pygame.quit()
   beijiny=beijiny+1
   if beijiny  > 0:
       beijiny = -798
   dijiy=dijiy+1


   # 图片2放窗口上
   ping_mu.blit(beijin,(0,beijiny))
   ping_mu.blit(huiji,(150,550))
   ping_mu.blit(diji,(150,dijiy))
   pygame.display.update()


















你可能感兴趣的:(学生作品,Xinxin,pygame)