我正在尝试做Python速成教程中的一个项目:外星人入侵第12章。我刚刚开始,由于某种原因,错误:pygame.error: video system not initialized不断弹出。我很确定我正确地遵循了说明,所以我不知道我可能做错了什么…?import sys
pygame.init() pygame
我目前正在python上编写一个游戏,我需要一种让敌人跑向玩家的方法。ratio = self.speed/math.sqrt(length) self.posy += dist.y * ratio for event in pygame.event.get():
if event.type == <e
我是一个初学者,正在用pygame制作一个类型的赛车游戏。我才刚刚开始,已经遇到问题了。import pygame
# setting up the screen size, colours and other necessitiesicon = pygame.image.load("exercise (1).png")
pygame.display.set_icon(i