summaryrefslogtreecommitdiff
path: root/src/sliceitoff/game/show.py
diff options
context:
space:
mode:
authorViljami Ilola <+@hix.fi>2024-03-28 13:54:00 +0200
committerViljami Ilola <+@hix.fi>2024-03-28 13:54:00 +0200
commitf502b21183d307fcab9b353aa18609d15c3547f1 (patch)
treed071b60ce9893ebc3086cee73f64e17774ad2c7b /src/sliceitoff/game/show.py
parentda2bb3d8e7dcd7f7f0a0c2d2e214b422350d1993 (diff)
hiscores: loading, saving, screen
Diffstat (limited to 'src/sliceitoff/game/show.py')
-rw-r--r--src/sliceitoff/game/show.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/sliceitoff/game/show.py b/src/sliceitoff/game/show.py
index 50ed0ba..07146c3 100644
--- a/src/sliceitoff/game/show.py
+++ b/src/sliceitoff/game/show.py
@@ -2,10 +2,11 @@
import pygame
from .anykey import anykey
-class Show:
+class Show(pygame.sprite.Group):
""" To show some sprites and quit on any key """
def __init__(self, sprites = []):
- self.sprites = sprites
+ super().__init__()
+ self.add(sprites)
self.fadeout = 1_000
self.timeout = 5_000
@@ -17,7 +18,7 @@ class Show:
if anykey():
return False
self.fadeout -= dt
- self.sprites.update(explode=dt)
+ self.update(explode=dt)
return True
if anykey():