diff options
author | Viljami Ilola <+@hix.fi> | 2024-03-29 00:30:39 +0200 |
---|---|---|
committer | Viljami Ilola <+@hix.fi> | 2024-03-29 00:30:39 +0200 |
commit | 5c5df6e068b2957987cb51b34d6930769424f8ca (patch) | |
tree | 1f6ce6ff479ee787a3da6f51a9c337bcd24b841a /src/sliceitoff/enemies | |
parent | 27c7e16e4bd808ce1176f18b7a78c02ff4fa88ee (diff) |
stats as object
Diffstat (limited to 'src/sliceitoff/enemies')
-rw-r--r-- | src/sliceitoff/enemies/enemies.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/sliceitoff/enemies/enemies.py b/src/sliceitoff/enemies/enemies.py index 658c1aa..797fe31 100644 --- a/src/sliceitoff/enemies/enemies.py +++ b/src/sliceitoff/enemies/enemies.py @@ -3,7 +3,6 @@ from random import randrange from display import Scaling from text import Fonts -from stats import Stats class EnemySprite(pygame.sprite.Sprite): def __init__(self): @@ -49,9 +48,9 @@ class EnemyBall(EnemySprite): class Enemies(pygame.sprite.Group): - def __init__(self, field = None): + def __init__(self, field = None, count = 0): super().__init__() - for _ in range(Stats.enemies): + for _ in range(count): enemy = EnemyBall() enemy.set_position( (randrange(0,300_000), randrange(0,200_000)) ) enemy.set_movement( (randrange(0,200)-100, randrange(0,200)-100) ) |