From: Christian Heller Date: Tue, 8 Sep 2015 11:15:49 +0000 (+0200) Subject: In hunger(), correct log messages on actually over-eating,not hungering. X-Git-Tag: tce~288 X-Git-Url: https://plomlompom.com/repos/blog?a=commitdiff_plain;h=0eb42867d40e0f2976e2ed405f7fc0be7d627af9;p=plomrogue In hunger(), correct log messages on actually over-eating,not hungering. --- diff --git a/roguelike-server b/roguelike-server index 0994039..258bae6 100755 --- a/roguelike-server +++ b/roguelike-server @@ -770,7 +770,11 @@ def hunger(t): stomach = int(32767 / world_db["ThingTypes"][t["T_TYPE"]]["TT_LIFEPOINTS"]) if int(int(testbase / stomach) / ((rand.next() % stomach) + 1)): if t == world_db["Things"][0]: - strong_write(io_db["file_out"], "LOG You suffer from hunger.\n") + if t["T_SATIATION"] < 0: + strong_write(io_db["file_out"], "LOG You suffer from hunger.\n") + else: + strong_write(io_db["file_out"], + "LOG You suffer from over-eating.\n") decrement_lifepoints(t)