From 2bf9dbbeca48cfde11566275d10ca91912257a0b Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Sat, 12 Mar 2016 01:35:22 +0100 Subject: [PATCH] TCE: Eat on every wall attack, not just on successful ones. --- plugins/server/TheCrawlingEater.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/plugins/server/TheCrawlingEater.py b/plugins/server/TheCrawlingEater.py index 52807b8..ab88cad 100644 --- a/plugins/server/TheCrawlingEater.py +++ b/plugins/server/TheCrawlingEater.py @@ -126,14 +126,10 @@ def actor_eat(t): height = world_db["MAP"][pos] - ord("0") if t["T_STOMACH"] >= 32 or height == 5: return - eaten = False - if height == 3 and 0 == int(rand.next() % 2): - t["T_STOMACH"] += height - eaten = True - elif height == 4 and 0 == int(rand.next() % 5): - t["T_STOMACH"] += height - eaten = True + t["T_STOMACH"] += 1 log("You EAT.") + eaten = (height == 3 and 0 == int(rand.next() % 2)) or \ + (height == 4 and 0 == int(rand.next() % 5)) if eaten: world_db["MAP"][pos] = ord("0") if t["T_STOMACH"] > 32: -- 2.30.2