#include "mfndpos.h"
+#define DOG_HUNGRY 300
+#define DOG_WEAK 500
+#define DOG_STARVE 750
+
static boolean dog_hunger(struct monst *, struct edog *);
static int dog_invent(struct monst *, struct edog *, int);
static int dog_goal(struct monst *, struct edog *, int, int, int);
static boolean
dog_hunger(struct monst *mtmp, struct edog *edog)
{
- if (g.moves > edog->hungrytime + 500) {
+ if (g.moves > edog->hungrytime + DOG_WEAK) {
if (!carnivorous(mtmp->data) && !herbivorous(mtmp->data)) {
- edog->hungrytime = g.moves + 500;
+ edog->hungrytime = g.moves + DOG_WEAK;
/* but not too high; it might polymorph */
} else if (!edog->mhpmax_penalty) {
/* starving pets are limited in healing */
else
You_feel("worried about %s.", y_monnam(mtmp));
stop_occupation();
- } else if (g.moves > edog->hungrytime + 750
+ } else if (g.moves > edog->hungrytime + DOG_STARVE
|| DEADMONSTER(mtmp)) {
dog_died:
if (mtmp->mleashed && mtmp != u.usteed)
if (!mtmp->isminion) {
struct edog *dog = EDOG(mtmp);
- hungry = (g.moves > (dog->hungrytime + 300));
+ hungry = (g.moves > (dog->hungrytime + DOG_HUNGRY));
}
/* Identify the best target in a straight line from the pet;