From cec38b64f2c56bd805145c7973924ff410b9c09c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=A2=81=E8=8A=B3?= <3231711930@qq.com> Date: Fri, 18 Jun 2021 08:10:23 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AD=90=E5=BC=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bullet.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bullet.py b/bullet.py index 61ed5ff..cb10ee3 100644 --- a/bullet.py +++ b/bullet.py @@ -73,3 +73,7 @@ class BossBullet(Sprite): # 更新rect位置 self.rect.y = self.y self.rect.x = self.x + + def draw_bullet(self): + """在屏幕上绘制子弹""" + pygame.draw.rect(self.screen, self.color, ((self.x, self.y), (self.width, self.height)))