diff --git a/effects/bouncingspot.py b/effects/bouncingspot.py index 622245a..6bbd479 100644 --- a/effects/bouncingspot.py +++ b/effects/bouncingspot.py @@ -1,6 +1,6 @@ from typing import Any import pygame as pg -from effects.effect import Effect +from effects.effect import Effect, Colors import random import math from typing import Union, Generator @@ -30,7 +30,9 @@ class BouncingSpot(Effect): size = (math.sin(self.ticks) / 2 + 0.5) * ( self.max_size - self.min_size ) + self.min_size - image = pg.Surface((self.max_size, self.max_size), flags=pg.SRCALPHA, depth=32) + image = pg.Surface((self.max_size, self.max_size)) + image.fill(Colors.Black) + image.set_colorkey(Colors.Black) super().__init__( image=image, rect=pg.Rect( @@ -60,7 +62,7 @@ class BouncingSpot(Effect): + self.bounds.centery ) - self.image.fill(pg.Color(255, 255, 0, 0)) + self.image.fill(Colors.Black) pg.draw.ellipse( self.image, self.color if isinstance(self.color, pg.Color) else next(self.color),