crop rotation (trunk only)

More tuning to throttle pudding farming (plus endgame Rider farming).
Earlier changes made cloned black puddings less likely to leave corpses,
to cut down on sacrifice fodder a bit, and cloned anything less likely to
drop random items when killed; this one makes killing cloned or revived
monsters be worth less experience as the number killed goes up, to cut
down on final score inflation.  [With several boulders and magic missile
or a polearm, it's possible to kill any of the Riders repeatedly with
virtually no risk of even getting hit, much less of getting killed.  Now
if you kill Pestilence 240 times it will be worth 62720 points instead of
297840 (not including doubling bonus for ascension), with an additional
19 points per kill instead of 1241 after that, requiring a couple orders
more magnitude of abuse--excuse me, superhuman "patience"--to get the
score to reach the overflow threshold.]

     While testing this, I got "The Famine's corpse glows iridescently."
This fixes that too.  Also, previously unused kill count for experience()
had an off by one error; was including ``+ 1'' even though mvitals[].died
has already been incremented by the time that that code uses it.
This commit is contained in:
nethack.rankin
2007-07-08 23:51:17 +00:00
parent f847518f4a
commit a3ddcba9a7
6 changed files with 30 additions and 6 deletions

View File

@@ -315,6 +315,7 @@ introduce support for negation of role, race, align, gender values to eliminate
them from random selection and the pick list of startup choices
some intelligent pets will avoid cannibalism
keep track of which monsters were cloned from other monsters
cloned and revived monsters become worth fewer points than ordinary ones
number_pad:3 run-time option to use inverted phone keypad layout for movement
number_pad:-1 to swap function of y and z keys; z to move NW, y to zap wands
display spell retention information in the spell menu

View File

@@ -66,9 +66,6 @@ int
experience(mtmp, nk) /* return # of exp points for mtmp after nk killed */
register struct monst *mtmp;
register int nk;
#if defined(macintosh) && (defined(__SC__) || defined(__MRC__))
# pragma unused(nk)
#endif
{
register struct permonst *ptr = mtmp->data;
int i, tmp, tmp2;
@@ -119,6 +116,27 @@ experience(mtmp, nk) /* return # of exp points for mtmp after nk killed */
if(mtmp->data == &mons[PM_MAIL_DAEMON]) tmp = 1;
#endif
if (mtmp->mrevived || mtmp->mcloned) {
/*
* Reduce experience awarded for repeated killings of
* "the same monster". Kill count includes all of this
* monster's type which have been killed--including the
* current monster--regardless of how they were created.
* 1.. 20 full experience
* 21.. 40 xp / 2
* 41.. 80 xp / 4
* 81..120 xp / 8
* 121..180 xp / 16
* 181..240 xp / 32
* 241..255+ xp / 64
*/
for (i = 0, tmp2 = 20; nk > tmp2 && tmp > 1; ++i) {
tmp = (tmp + 1) / 2;
nk -= tmp2;
if (i & 1) tmp2 += 20;
}
}
return(tmp);
}

View File

@@ -1446,7 +1446,7 @@ domove()
u.uconduct.killer++;
mndx = monsndx(mtmp->data);
tmp = experience(mtmp, (int)mvitals[mndx].died + 1);
tmp = experience(mtmp, (int)mvitals[mndx].died);
more_experienced(tmp, 0);
newexplevel(); /* will decide if you go up */
}

View File

@@ -2067,7 +2067,7 @@ cleanup:
}
/* give experience points */
tmp = experience(mtmp, (int)mvitals[mndx].died + 1);
tmp = experience(mtmp, (int)mvitals[mndx].died);
more_experienced(tmp, 0);
newexplevel(); /* will decide if you go up */

View File

@@ -486,6 +486,9 @@ resurrect()
/* make a new Wizard */
verb = "kill";
mtmp = makemon(&mons[PM_WIZARD_OF_YENDOR], u.ux, u.uy, MM_NOWAIT);
/* affects experience; he's not coming back from a corpse
but is subject to repeated killing like a revived corpse */
mtmp->mrevived = 1;
} else {
/* look for a migrating Wizard */
verb = "elude";

View File

@@ -576,6 +576,7 @@ coord *cc;
mtmp2->mlstmv = mtmp->mlstmv;
mtmp2->m_ap_type = mtmp->m_ap_type;
/* set these ones explicitly */
mtmp2->mrevived = 1;
mtmp2->mavenge = 0;
mtmp2->meating = 0;
mtmp2->mleashed = 0;
@@ -755,7 +756,8 @@ boolean by_hero;
shkp = shop_keeper(*in_rooms(x, y, SHOPBASE));
if (cansee(x, y))
pline_The("%s glows iridescently.", cxname(corpse));
pline("%s glows iridescently.",
upstart(corpse_xname(corpse, (const char *)0, CXN_PFX_THE)));
else if (shkp)
/* need some prior description of the corpse since
stolen_value() will refer to the object as "it" */