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:
commands_db["pee"] = (0, False, play_pee)
commands_db["use"] = (1, False, lambda x: None)
commands_db["pickup"] = (0, False, lambda: None)
-commands_db["T_STOMACH"] = (1, False, setter("Thing", "T_BOWEL", 0, 255))
-commands_db["T_KIDNEY"] = (1, False, setter("Thing", "T_BLADDER", 0, 255))
+commands_db["T_STOMACH"] = (1, False, setter("Thing", "T_STOMACH", 0, 255))
+commands_db["T_KIDNEY"] = (1, False, setter("Thing", "T_KIDNEY", 0, 255))
commands_db["T_BOWEL"] = (1, False, setter("Thing", "T_BOWEL", 0, 255))
commands_db["T_BLADDER"] = (1, False, setter("Thing", "T_BLADDER", 0, 255))
commands_db["WETMAP"] = (2, False, wetmapset)