diff options
| author | yuzu-eva <stevenhu@web.de> | 2024-09-20 18:25:40 +0200 |
|---|---|---|
| committer | yuzu-eva <stevenhu@web.de> | 2024-09-20 18:25:40 +0200 |
| commit | a00f4cf1eb4217483408dde11d9d0c7e763ab0a2 (patch) | |
| tree | d765011d7ef9ac82936493aadac40d67b351e148 /shot.py | |
| parent | 220e57f42fca7bd241041e5c808f62a3fa7cfa2a (diff) | |
added ability to shoot
Diffstat (limited to 'shot.py')
| -rw-r--r-- | shot.py | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -0,0 +1,13 @@ +from constants import * +from circleshape import * + +class Shot(CircleShape): + def __init__(self, x, y, radius): + super().__init__(x, y, radius) + + def draw(self, screen): + pygame.draw.circle(screen, "white", self.position, self.radius) + + def update(self, dt): + self.position += self.velocity * dt + |
