From 60635efe557798d2392c85e93dea62e2b8c8214d Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Thu, 25 Feb 2016 01:04:34 +0100 Subject: [PATCH] Plugin: Simplify decrement_lifepoints. --- plugins/server/PleaseTheIslandGod.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/plugins/server/PleaseTheIslandGod.py b/plugins/server/PleaseTheIslandGod.py index f513300..4005f28 100644 --- a/plugins/server/PleaseTheIslandGod.py +++ b/plugins/server/PleaseTheIslandGod.py @@ -321,7 +321,6 @@ def decrement_lifepoints(t): t["T_LIFEPOINTS"] -= 1 _id = [_id for _id in world_db["Things"] if world_db["Things"][_id] == t][0] if 0 == t["T_LIFEPOINTS"]: - sadness = world_db["ThingTypes"][t["T_TYPE"]]["TT_LIFEPOINTS"] for id in t["T_CARRIES"]: t["T_CARRIES"].remove(id) world_db["Things"][id]["T_POSY"] = t["T_POSY"] @@ -337,7 +336,7 @@ def decrement_lifepoints(t): t["T_MEMMAP"] = False t["T_MEMDEPTHMAP"] = False t["T_MEMTHING"] = [] - return sadness + return world_db["ThingTypes"][t["T_TYPE"]]["TT_LIFEPOINTS"] return 0 def actor_move(t): -- 2.30.2