multiple statues and stone-to-flesh
stone-to-flesh of spot with multiple statues can animate more than one by using adjacent locations
This commit is contained in:
@@ -108,6 +108,7 @@ ensure mksobj() always attaches timer to corpse, even if called with init FALSE
|
|||||||
only charge for eating one stacked tin, not all at once
|
only charge for eating one stacked tin, not all at once
|
||||||
add flag to makemon() to allow monster to be created adjacent to the supplied
|
add flag to makemon() to allow monster to be created adjacent to the supplied
|
||||||
coordinates if there is already a monster at the target location
|
coordinates if there is already a monster at the target location
|
||||||
|
stone-to-flesh of spot with multiple statues can animate more than one
|
||||||
|
|
||||||
|
|
||||||
Platform- and/or Interface-Specific Fixes
|
Platform- and/or Interface-Specific Fixes
|
||||||
|
|||||||
+13
-5
@@ -412,6 +412,9 @@ int *fail_reason;
|
|||||||
struct obj *item;
|
struct obj *item;
|
||||||
coord cc;
|
coord cc;
|
||||||
boolean historic = (Role_if(PM_ARCHEOLOGIST) && !flags.mon_moving && (statue->spe & STATUE_HISTORIC));
|
boolean historic = (Role_if(PM_ARCHEOLOGIST) && !flags.mon_moving && (statue->spe & STATUE_HISTORIC));
|
||||||
|
char statuename[BUFSZ];
|
||||||
|
|
||||||
|
Strcpy(statuename,the(xname(statue)));
|
||||||
|
|
||||||
if (statue->oxlth && statue->oattached == OATTACHED_MONST) {
|
if (statue->oxlth && statue->oattached == OATTACHED_MONST) {
|
||||||
cc.x = x, cc.y = y;
|
cc.x = x, cc.y = y;
|
||||||
@@ -434,7 +437,8 @@ int *fail_reason;
|
|||||||
if (fail_reason) *fail_reason = AS_MON_IS_UNIQUE;
|
if (fail_reason) *fail_reason = AS_MON_IS_UNIQUE;
|
||||||
return (struct monst *)0;
|
return (struct monst *)0;
|
||||||
}
|
}
|
||||||
mon = makemon(mptr, x, y, NO_MINVENT);
|
mon = makemon(mptr, x, y, (cause == ANIMATE_SPELL) ?
|
||||||
|
(NO_MINVENT | MM_ADJACENTOK) : NO_MINVENT);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!mon) {
|
if (!mon) {
|
||||||
@@ -463,12 +467,16 @@ int *fail_reason;
|
|||||||
if ((x == u.ux && y == u.uy) || cause == ANIMATE_SPELL) {
|
if ((x == u.ux && y == u.uy) || cause == ANIMATE_SPELL) {
|
||||||
const char *comes_to_life = nonliving(mon->data) ?
|
const char *comes_to_life = nonliving(mon->data) ?
|
||||||
"moves" : "comes to life";
|
"moves" : "comes to life";
|
||||||
pline_The("statue %s!",
|
if (cause == ANIMATE_SPELL)
|
||||||
canspotmon(mon) ? comes_to_life : "disappears");
|
pline("%s %s!", upstart(statuename),
|
||||||
if (historic) {
|
canspotmon(mon) ? comes_to_life : "disappears");
|
||||||
|
else
|
||||||
|
pline_The("statue %s!",
|
||||||
|
canspotmon(mon) ? comes_to_life : "disappears");
|
||||||
|
if (historic) {
|
||||||
You_feel("guilty that the historic statue is now gone.");
|
You_feel("guilty that the historic statue is now gone.");
|
||||||
adjalign(-1);
|
adjalign(-1);
|
||||||
}
|
}
|
||||||
} else if (cause == ANIMATE_SHATTER)
|
} else if (cause == ANIMATE_SHATTER)
|
||||||
pline("Instead of shattering, the statue suddenly %s!",
|
pline("Instead of shattering, the statue suddenly %s!",
|
||||||
canspotmon(mon) ? "comes to life" : "disappears");
|
canspotmon(mon) ? "comes to life" : "disappears");
|
||||||
|
|||||||
Reference in New Issue
Block a user