"""
中途岛海战飞行阵列测试程序,
本程序演示三种飞行阵列依次显示,
这三种阵列依次是一字,椭圆,8字阵列。
"""
import pygame
from pygame.locals import *
from enemy0 import Enemy0
from enemy2 import Enemy2
from enemy8 import Enemy8
def main():
"""主要函数"""
bg = 'images/海洋.png'
image = "images/Raven_128x128_red.png"
width,height = size = 960,720
screen = pygame.display.set_mode(size)
pygame.display.set_caption("中途岛海战飞行阵列测试程序by李兴球")
bg = pygame.image.load(bg)
# 下面准备把图像缩小
image = pygame.image.load(image)
w,h = image.get_size()
image = pygame.transform.scale(image,(w//3,h//3))
group = pygame.sprite.Group()
clock = pygame.time.Clock()
running = True
Enemys = [Enemy0,Enemy2,Enemy8]
p0 = image,(0,height//2),screen
p2 = image,350,200,(width//2,height//2)
p8 = image,(width//2,100)
ps = [p0,p2,p8]
intervals = [400,200,200]
需要浏览更多吗?
成为会员后,登陆才能继续浏览!联系微信scratch8即可办理会员。
(会员专属:能浏览所有文章,下载所有带链接的Python资源。)
-
- 2025 年 10 月
- 2025 年 9 月
- 2025 年 6 月
- 2025 年 5 月
- 2025 年 3 月
- 2025 年 2 月
- 2025 年 1 月
- 2024 年 12 月
- 2024 年 8 月
- 2024 年 6 月
- 2024 年 5 月
- 2024 年 4 月
- 2024 年 3 月
- 2024 年 2 月
- 2023 年 11 月
- 2023 年 9 月
- 2023 年 6 月
- 2023 年 5 月
- 2023 年 4 月
- 2023 年 3 月
- 2023 年 2 月
- 2023 年 1 月
- 2022 年 12 月
- 2022 年 11 月
- 2022 年 10 月
- 2022 年 9 月
- 2022 年 8 月
- 2022 年 7 月
- 2022 年 6 月
- 2022 年 5 月
- 2022 年 4 月
- 2022 年 3 月
- 2022 年 2 月
- 2022 年 1 月
- 2021 年 12 月
- 2021 年 11 月
- 2021 年 10 月
- 2021 年 9 月
- 2021 年 8 月
- 2021 年 7 月
- 2021 年 6 月
- 2021 年 5 月
- 2021 年 4 月
- 2021 年 3 月
- 2021 年 2 月
- 2021 年 1 月
- 2020 年 12 月
- 2020 年 11 月
- 2020 年 10 月
- 2020 年 9 月
- 2020 年 8 月
- 2020 年 7 月
- 2020 年 6 月
- 2020 年 5 月
- 2020 年 4 月
- 2020 年 3 月
- 2020 年 2 月
- 2020 年 1 月
- 2019 年 12 月
- 2019 年 11 月
- 2019 年 10 月
- 2019 年 9 月
- 2019 年 8 月
- 2019 年 7 月
- 2019 年 6 月
- 2019 年 5 月
- 2019 年 4 月
- 2019 年 3 月
- 2019 年 2 月
- 2018 年 3 月
- 2018 年 1 月
- 2017 年 9 月
- 2017 年 5 月
- 2017 年 1 月
