diff --git a/README.md b/README.md index e1f48e5..5961892 100644 --- a/README.md +++ b/README.md @@ -88,7 +88,6 @@ nuitka --mingw --standalone --onefile --show-progress --show-memory --output-dir * 修复已经死亡的僵尸会触发大嘴花、土豆雷甚至小推车的问题 * 用蓝色滤镜标识冷冻的僵尸 * 修复暂停游戏时仍在计时的bug -* 修复魅惑菇的bug ## 截屏 diff --git a/source/component/plant.py b/source/component/plant.py index 3255e38..2221b87 100755 --- a/source/component/plant.py +++ b/source/component/plant.py @@ -215,7 +215,7 @@ class Plant(pg.sprite.Sprite): if not zombie.lostHead: self.health -= damage self.hit_timer = self.current_time - if self.health == 0: + if (self.health == 0) or (self.name == c.HYPNOSHROOM and self.state != c.SLEEP): self.kill_zombie = zombie def getPosition(self): diff --git a/source/state/level.py b/source/state/level.py index eab2023..8d8d0bf 100644 --- a/source/state/level.py +++ b/source/state/level.py @@ -555,7 +555,7 @@ class Level(tool.State): zombie.setAttack(plant) for hypno_zombie in self.hypno_zombie_groups[i]: - if hypno_zombie.health <= 0: + if hypno_zombie.health < 70: continue zombie_list = pg.sprite.spritecollide(hypno_zombie, self.zombie_groups[i], False,collided_func) diff --git a/source/tool.py b/source/tool.py index a783d0b..2de067c 100755 --- a/source/tool.py +++ b/source/tool.py @@ -35,7 +35,7 @@ class Control(): self.screen = pg.display.get_surface() self.done = False self.clock = pg.time.Clock() # 创建一个对象来帮助跟踪时间 - self.fps = 60 + self.fps = 30 self.keys = pg.key.get_pressed() self.mouse_pos = None self.mouse_click = [False, False] # value:[left mouse click, right mouse click]