several fixes for farming changes
* don't let player wish for multiple globs * use newsym() to clean up merged globs on floor * food effects should match original corpse effects * tidy up remaining crash when merging in place
This commit is contained in:
@@ -894,6 +894,8 @@ non-pet rust monsters would eat rust-proofed non-digestibles but ignore
|
||||
those non-digestibles otherwise
|
||||
kicking a grave may topple the gravestone
|
||||
allow showing legal jumping positions when asked for location to jump to
|
||||
cloned creatures (of any type) don't deathdrop items
|
||||
pudding corpses behave somewhat differently than before
|
||||
|
||||
|
||||
Platform- and/or Interface-Specific Fixes
|
||||
|
||||
2
src/do.c
2
src/do.c
@@ -217,8 +217,8 @@ const char *verb;
|
||||
while (obj && (otmp = obj_nexto_xy(obj->otyp, x, y, obj->o_id)) != (struct obj*)0) {
|
||||
pline("The %s coalesce.", makeplural(obj_typename(obj->otyp)));
|
||||
obj_meld(&obj, &otmp);
|
||||
return (obj == NULL);
|
||||
}
|
||||
return (obj == NULL);
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@@ -1612,7 +1612,7 @@ start_eating(otmp) /* called as you start to eat */
|
||||
context.victual.fullwarn = context.victual.doreset = FALSE;
|
||||
context.victual.eating = TRUE;
|
||||
|
||||
if (otmp->otyp == CORPSE) {
|
||||
if (otmp->otyp == CORPSE || otmp->globby) {
|
||||
cprefx(context.victual.piece->corpsenm);
|
||||
if (!context.victual.piece || !context.victual.eating) {
|
||||
/* rider revived, or died and lifesaved */
|
||||
@@ -2127,7 +2127,7 @@ struct obj *otmp;
|
||||
!Stone_resistance &&
|
||||
!poly_when_stoned(youmonst.data));
|
||||
|
||||
if (mnum == PM_GREEN_SLIME)
|
||||
if (mnum == PM_GREEN_SLIME || otmp->otyp == GLOB_OF_GREEN_SLIME)
|
||||
stoneorslime = (!Unchanging && !slimeproof(youmonst.data));
|
||||
|
||||
if (cadaver && !nonrotting_corpse(mnum)) {
|
||||
@@ -2397,7 +2397,7 @@ doeat() /* generic "eat" command funtion (see cmd.c) */
|
||||
* for normal vs. rotten food. The reqtime and nutrit values are
|
||||
* then adjusted in accordance with the amount of food left.
|
||||
*/
|
||||
if(otmp->otyp == CORPSE) {
|
||||
if(otmp->otyp == CORPSE || otmp->globby) {
|
||||
int tmp = eatcorpse(otmp);
|
||||
if (tmp == 2) {
|
||||
/* used up */
|
||||
|
||||
@@ -676,6 +676,7 @@ boolean artif;
|
||||
if (Is_pudding(otmp)) {
|
||||
otmp->globby = 1;
|
||||
otmp->known = otmp->bknown = otmp->rknown = otmp->dknown = 1;
|
||||
otmp->corpsenm = PM_GRAY_OOZE + (otmp->otyp - GLOB_OF_GRAY_OOZE);
|
||||
/* this ensures that they don't fail merging because of
|
||||
* BUC status or other irrelevancies */
|
||||
} else {
|
||||
@@ -2219,7 +2220,9 @@ obj_absorb(obj1, obj2)
|
||||
otmp1->oeaten += otmp1->oeaten ? extrawt : 0;
|
||||
otmp1->quan = 1;
|
||||
obj_extract_self(otmp2);
|
||||
newsym(otmp2->ox, otmp2->oy); /* in case of floor */
|
||||
dealloc_obj(otmp2);
|
||||
*obj2 = NULL;
|
||||
return otmp1;
|
||||
}
|
||||
}
|
||||
|
||||
17
src/objnam.c
17
src/objnam.c
@@ -2499,11 +2499,18 @@ struct obj *no_wish;
|
||||
}
|
||||
|
||||
/* intercept pudding globs here; they're a valid wish target,
|
||||
* but we need them to not get treated like a corpse */
|
||||
if (((p = strstri(bp, "glob of ")) != 0)
|
||||
&& (mntmp = name_to_mon(p+8)) >= PM_GRAY_OOZE
|
||||
&& mntmp <= PM_BLACK_PUDDING) {
|
||||
mntmp = NON_PM; /* lie to ourselves */
|
||||
* but we need them to not get treated like a corpse.
|
||||
*
|
||||
* also don't let player wish for multiple globs.
|
||||
*/
|
||||
if ((p = strstri(bp, "glob of ")) != 0
|
||||
|| (p = strstri(bp, "globs of ")) != 0) {
|
||||
int globoffset = (*(p+4) == 's') ? 9 : 8;
|
||||
if ((mntmp = name_to_mon(p + globoffset)) >= PM_GRAY_OOZE
|
||||
&& mntmp <= PM_BLACK_PUDDING) {
|
||||
mntmp = NON_PM; /* lie to ourselves */
|
||||
cnt = 0; /* force only one */
|
||||
}
|
||||
} else {
|
||||
/*
|
||||
* Find corpse type using "of" (figurine of an orc, tin of orc meat)
|
||||
|
||||
Reference in New Issue
Block a user