X-Git-Url: https://plomlompom.com/repos/berlin_corona.txt?a=blobdiff_plain;f=server%2Fdecrement_lifepoints.py;h=827a16ea0616da93fe25c13e2ce412a2f315812b;hb=ed80228e423745ebd3c6b510dbfe2afa916aa79f;hp=8fe5de8c9cbad60146c385df7ca8354456ec3418;hpb=9ae02cea8243472195d97b756542f9d344a67459;p=plomrogue diff --git a/server/decrement_lifepoints.py b/server/decrement_lifepoints.py index 8fe5de8..827a16e 100644 --- a/server/decrement_lifepoints.py +++ b/server/decrement_lifepoints.py @@ -14,6 +14,7 @@ def decrement_lifepoints(t): from server.io import log t["T_LIFEPOINTS"] -= 1 if 0 == t["T_LIFEPOINTS"]: + live_tid = t["T_TYPE"] for id in t["T_CARRIES"]: t["T_CARRIES"].remove(id) world_db["Things"][id]["T_POSY"] = t["T_POSY"] @@ -29,3 +30,5 @@ def decrement_lifepoints(t): t["T_MEMMAP"] = False t["T_MEMDEPTHMAP"] = False t["T_MEMTHING"] = [] + return world_db["ThingTypes"][live_tid]["TT_LIFEPOINTS"] + return 0