A camera may contain a picture-painting demon
Original patch by Leon Arnott
This commit is contained in:
@@ -898,6 +898,7 @@ cloned creatures (of any type) don't deathdrop items
|
||||
pudding corpses behave somewhat differently than before
|
||||
mithril armor should have silver color
|
||||
lichen corpse is an acid indicator
|
||||
camera may contain a picture-painting demon
|
||||
|
||||
|
||||
Platform- and/or Interface-Specific Fixes
|
||||
|
||||
@@ -497,6 +497,7 @@ E int FDECL(omon_adj, (struct monst *,struct obj *,BOOLEAN_P));
|
||||
E int FDECL(thitmonst, (struct monst *,struct obj *));
|
||||
E int FDECL(hero_breaks, (struct obj *,XCHAR_P,XCHAR_P,BOOLEAN_P));
|
||||
E int FDECL(breaks, (struct obj *,XCHAR_P,XCHAR_P));
|
||||
E void FDECL(release_camera_demon, (struct obj *, XCHAR_P,XCHAR_P));
|
||||
E void FDECL(breakobj, (struct obj *,XCHAR_P,XCHAR_P,BOOLEAN_P,BOOLEAN_P));
|
||||
E boolean FDECL(breaktest, (struct obj *));
|
||||
E boolean FDECL(walk_path, (coord *, coord *, boolean (*)(genericptr_t,int,int), genericptr_t));
|
||||
|
||||
@@ -1665,6 +1665,21 @@ xchar x, y; /* object location (ox, oy may not be right) */
|
||||
return 1;
|
||||
}
|
||||
|
||||
void
|
||||
release_camera_demon(obj, x,y)
|
||||
struct obj *obj;
|
||||
xchar x,y;
|
||||
{
|
||||
struct monst *mtmp;
|
||||
if (!rn2(3) && (mtmp = makemon(&mons[rn2(3) ? PM_HOMUNCULUS : PM_IMP],x,y, NO_MM_FLAGS)) != 0) {
|
||||
if (canspotmon(mtmp))
|
||||
pline("%s is released!", Hallucination ?
|
||||
An(rndmonnam(NULL)) : "The picture-painting demon");
|
||||
mtmp->mpeaceful = !obj->cursed;
|
||||
set_malign(mtmp);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Unconditionally break an object. Assumes all resistance checks
|
||||
* and break messages have been delivered prior to getting here.
|
||||
@@ -1707,6 +1722,9 @@ boolean from_invent;
|
||||
}
|
||||
/* monster breathing isn't handled... [yet?] */
|
||||
break;
|
||||
case EXPENSIVE_CAMERA:
|
||||
release_camera_demon(obj, x,y);
|
||||
break;
|
||||
case EGG:
|
||||
/* breaking your own eggs is bad luck */
|
||||
if (hero_caused && obj->spe && obj->corpsenm >= LOW_PM)
|
||||
|
||||
@@ -741,6 +741,7 @@ int thrown; /* HMON_xxx (0 => hand-to-hand, other => ranged) */
|
||||
case EXPENSIVE_CAMERA:
|
||||
You("succeed in destroying %s. Congratulations!",
|
||||
ysimple_name(obj));
|
||||
release_camera_demon(obj, u.ux, u.uy);
|
||||
useup(obj);
|
||||
return(TRUE);
|
||||
/*NOTREACHED*/
|
||||
|
||||
Reference in New Issue
Block a user