From 9e9523a1a51448f5639c91327df15fc435116d41 Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Wed, 31 Dec 2025 17:51:26 +0000 Subject: [PATCH] dont attack if dead or running away --- api.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/api.lua b/api.lua index 0f813c9..f04e6b1 100644 --- a/api.lua +++ b/api.lua @@ -18,7 +18,7 @@ end -- global table mobs = { - mod = "redo", version = "20251205", + mod = "redo", version = "20251231", spawning_mobs = {}, translate = S, node_snow = has(core.registered_aliases["mapgen_snow"]) or has("mcl_core:snow") or has("default:snow") or "air", @@ -213,7 +213,8 @@ end function mob_class:do_attack(player, force) - if self.state == "attack" and not force then return end + if (self.state == "attack" or self.state == "die" or self.state == "runaway") + and not force then return end self.attack = player ; self.state = "attack"