InoffensiveChargePad.py 文件源码

python
阅读 30 收藏 0 点赞 0 评论 0

项目:LD39 作者: Bobsleigh 项目源码 文件源码
def __init__(self, x, y, sceneData, max_health=10):
        super().__init__()

        self.name = "ChargePad"

        self.frameAnimationSpeed = 20
        imageBase = pygame.image.load(os.path.join('img', 'charge-pad.png'))
        imageFlash = pygame.image.load(os.path.join('img', 'charge-pad-flash.png'))
        frames = [imageBase, imageFlash]
        self.animation = Animation(frames, self.frameAnimationSpeed, True)
        self.image = frames[0]

        self.imageTransparent = pygame.Surface((1, 1),pygame.SRCALPHA)

        self.rect = self.image.get_rect()  # Position centrée du player
        self.x = x
        self.y = y
        self.rect.x = x
        self.rect.y = y

        self.sceneData = sceneData
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号