import sys
import pygame

class AlienInvasion:
    """Overall class for the game"""
    def __init__(self):
        """Initialize game and create resources"""
        pygame.init()
        self.screen = pygame.display.set_mode((1920, 1080))
        pygame.display.set_caption("Alien Invasion")
    def run_game(self):
        """Start main game loop"""
        while True:
            #Listen for events
            for event in pygame.event.get():
                if event.type == pygame.QUIT:
                    sys.exit()
            # refresh display
            pygame.display.flip()

if __name__ == '__main__':
    # Create game instance and run game
    ai = AlienInvasion()
    ai.run_game()