更新 '主程序/alien_invasion1.py'

This commit is contained in:
206530130 2021-06-21 18:37:13 +08:00
parent 5f0c24afc9
commit 4accd657ad
1 changed files with 12 additions and 1 deletions

View File

@ -27,4 +27,15 @@ def run_game():
aliens = Group()
gf.create_fleet(ai_settings, screen, ship, aliens)
gf.create_fleet(ai_settings, screen, ship, aliens)
while True:
gf.check_events(ai_settings, screen, stats, sb, play_button, ship, aliens, bullets)
if stats.game_active:
ship.update()
gf.update_bullets(ai_settings, screen, stats, sb, ship, aliens, bullets)
gf.update_aliens(ai_settings, screen, stats, sb, ship, aliens, bullets)
gf.update_screen(ai_settings, screen, stats, sb, ship, aliens, bullets, play_button)
run_game()