修复缠绕水草被死亡僵尸误触的bug

This commit is contained in:
星外之神 2022-05-10 17:06:56 +08:00
parent e2546e552d
commit b5bdf1234c

View File

@ -1406,6 +1406,7 @@ class TangleKlep(Plant):
self.frames = self.idle_frames self.frames = self.idle_frames
def canAttack(self, zombie): def canAttack(self, zombie):
if zombie.state != c.DIE and (not zombie.lostHead):
if pg.sprite.collide_circle_ratio(0.7)(zombie, self): if pg.sprite.collide_circle_ratio(0.7)(zombie, self):
return True return True
return False return False