From fe3c54313611d48d9f5c659d992f187722022d67 Mon Sep 17 00:00:00 2001 From: general Date: Sun, 7 Apr 2024 20:40:59 -0400 Subject: [PATCH] fix and tweak runaway_timer from "code tweaks" * backport only the tweak of "code tweaks" of upstream commit 457eb1838cd1e694052298a42c84cd7b061d809d run away soon and early --- api.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api.lua b/api.lua index 3860921..2f523c2 100644 --- a/api.lua +++ b/api.lua @@ -2527,8 +2527,8 @@ function mob_class:do_states(dtime) self.runaway_timer = self.runaway_timer + 1 - -- stop after 5 seconds or when at cliff -- TODO - if self.runaway_timer > 5 + -- stop early after 3 or 2 seconds or when at cliff cos defaults start at 0 but on some states is 3 + if self.runaway_timer > 4 or self.at_cliff or self.order == "stand" then self.runaway_timer = 0