From a00f4cf1eb4217483408dde11d9d0c7e763ab0a2 Mon Sep 17 00:00:00 2001 From: yuzu-eva Date: Fri, 20 Sep 2024 18:25:40 +0200 Subject: added ability to shoot --- shot.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 shot.py (limited to 'shot.py') diff --git a/shot.py b/shot.py new file mode 100644 index 0000000..198b48e --- /dev/null +++ b/shot.py @@ -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 + -- cgit v1.2.3