Changes to be committed:
modified: src/shknam.c modified: src/trap.c modified: src/zap.c While polymorph was clearing the name because poly_obj actually creates a brand new obj and copies field values over, water_damage does not so the name persisted on the blank spellbook. In this case, that isn't really appropriate. Clear the name. Ensure that cancellation has no effect on these ordinary books. Make the second-hand bookstore an option for holding the book tribute item too.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.5 shknam.c $NHDT-Date$ $NHDT-Branch$:$NHDT-Revision$ */
|
||||
/* NetHack 3.5 shknam.c $NHDT-Date: 1428207608 2015/04/05 04:20:08 $ $NHDT-Branch: nhmall-booktribute $:$NHDT-Revision: 1.32 $ */
|
||||
/* NetHack 3.5 shknam.c $Date: 2011/04/15 01:55:42 $ $Revision: 1.24 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -368,7 +368,8 @@ boolean mkspecl;
|
||||
struct permonst *ptr;
|
||||
|
||||
/* 3.6.0 tribute */
|
||||
if (mkspecl && !strcmp(shp->name, "rare books")) {
|
||||
if (mkspecl && (!strcmp(shp->name, "rare books") ||
|
||||
!strcmp(shp->name, "second-hand bookstore"))) {
|
||||
struct obj *novel=mksobj_at(SPE_NOVEL, sx, sy, FALSE, FALSE);
|
||||
if (novel) context.tribute.bookstock = TRUE;
|
||||
return;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.5 trap.c $NHDT-Date: 1427934551 2015/04/02 00:29:11 $ $NHDT-Branch: master $:$NHDT-Revision: 1.223 $ */
|
||||
/* NetHack 3.5 trap.c $NHDT-Date: 1428207616 2015/04/05 04:20:16 $ $NHDT-Branch: nhmall-booktribute $:$NHDT-Revision: 1.224 $ */
|
||||
/* NetHack 3.5 trap.c $Date: 2013/03/14 01:58:21 $ $Revision: 1.179 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -3206,6 +3206,10 @@ boolean force;
|
||||
pline("Steam rises from %s.", the(xname(obj)));
|
||||
return 0;
|
||||
}
|
||||
if (obj->otyp == SPE_NOVEL) {
|
||||
obj->novelidx = 0;
|
||||
free_oname(obj);
|
||||
}
|
||||
obj->otyp = SPE_BLANK_PAPER;
|
||||
obj->dknown = 0;
|
||||
if (carried(obj))
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.5 zap.c $NHDT-Date: 1427782839 2015/03/31 06:20:39 $ $NHDT-Branch: master $:$NHDT-Revision: 1.200 $ */
|
||||
/* NetHack 3.5 zap.c $NHDT-Date: 1428207622 2015/04/05 04:20:22 $ $NHDT-Branch: nhmall-booktribute $:$NHDT-Revision: 1.215 $ */
|
||||
/* NetHack 3.5 zap.c $Date: 2013/11/05 00:57:56 $ $Revision: 1.183 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -956,7 +956,9 @@ register struct obj *obj;
|
||||
obj->spe = 0;
|
||||
break;
|
||||
case SPBOOK_CLASS:
|
||||
if (otyp != SPE_CANCELLATION && otyp != SPE_BOOK_OF_THE_DEAD) {
|
||||
if (otyp != SPE_CANCELLATION &&
|
||||
otyp != SPE_NOVEL &&
|
||||
otyp != SPE_BOOK_OF_THE_DEAD) {
|
||||
costly_alteration(obj, COST_CANCEL);
|
||||
obj->otyp = SPE_BLANK_PAPER;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user