--- deliantra/server/common/living.C 2007/07/10 05:51:37 1.70 +++ deliantra/server/common/living.C 2007/07/21 14:37:25 1.71 @@ -810,6 +810,8 @@ stats.luck = arch->stats.luck; speed = arch->speed; + sint16 digestion = 0; // a local var to add digestion + /* OK - we've reset most all the objects attributes to sane values. * now go through and make adjustments for what the player has equipped. */ @@ -891,7 +893,7 @@ tmp->type == DISEASE || tmp->type == FORCE || tmp->type == SKILL) { - contr->digestion += tmp->stats.food; + digestion += tmp->stats.food; contr->gen_hp += tmp->stats.hp; contr->gen_sp += tmp->stats.sp; contr->gen_grace += tmp->stats.grace; @@ -1135,6 +1137,9 @@ } /* item is equipped */ } /* for loop of items */ + // now clamp digestion to our limits + contr->digestion = clamp (digestion, MIN_DIGESTION, MAX_DIGESTION); + /* We've gone through all the objects the player has equipped. For many things, we * have generated intermediate values which we now need to assign. */