missing altar drop messages
Most callers of dropx did not check for altars, but should have. Rather than add such checks, I moved the check from drop to dropx. I also found several callers of dropx that could generate out-of-order messages for some cases (not new) and fixed them. FYI - callers of dropy don't seem to want altar checks or already do them.
This commit is contained in:
@@ -329,6 +329,7 @@ non-moving monster are not affected by liquid
|
|||||||
'A' command wouldn't remove cursed item from quiver or alternate weapon slot
|
'A' command wouldn't remove cursed item from quiver or alternate weapon slot
|
||||||
'A' command behaved differently depending on menustyle when non-weapons were
|
'A' command behaved differently depending on menustyle when non-weapons were
|
||||||
present in the quiver or alternate weapon inventory slots
|
present in the quiver or alternate weapon inventory slots
|
||||||
|
most cases of the hero dropping things need to check for dropping on an altar
|
||||||
|
|
||||||
|
|
||||||
Platform- and/or Interface-Specific Fixes
|
Platform- and/or Interface-Specific Fixes
|
||||||
|
|||||||
+2
-2
@@ -1768,9 +1768,9 @@ struct obj *obj;
|
|||||||
char buf[BUFSZ];
|
char buf[BUFSZ];
|
||||||
|
|
||||||
if (Glib) {
|
if (Glib) {
|
||||||
dropx(obj);
|
|
||||||
pline("%s from your %s.", Tobjnam(obj, "slip"),
|
pline("%s from your %s.", Tobjnam(obj, "slip"),
|
||||||
makeplural(body_part(FINGER)));
|
makeplural(body_part(FINGER)));
|
||||||
|
dropx(obj);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1778,9 +1778,9 @@ struct obj *obj;
|
|||||||
if ((obj->cursed || Fumbling) && !rn2(2)) {
|
if ((obj->cursed || Fumbling) && !rn2(2)) {
|
||||||
check_unpaid(obj);
|
check_unpaid(obj);
|
||||||
obj->spe--;
|
obj->spe--;
|
||||||
dropx(obj);
|
|
||||||
pline("%s from your %s.", Tobjnam(obj, "slip"),
|
pline("%s from your %s.", Tobjnam(obj, "slip"),
|
||||||
makeplural(body_part(FINGER)));
|
makeplural(body_part(FINGER)));
|
||||||
|
dropx(obj);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
otmp = getobj(lubricables, "grease");
|
otmp = getobj(lubricables, "grease");
|
||||||
|
|||||||
@@ -492,10 +492,8 @@ register struct obj *obj;
|
|||||||
hitfloor(obj);
|
hitfloor(obj);
|
||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
if (IS_ALTAR(levl[u.ux][u.uy].typ)) {
|
if (!IS_ALTAR(levl[u.ux][u.uy].typ) && flags.verbose)
|
||||||
doaltarobj(obj); /* set bknown */
|
You("drop %s.", doname(obj));
|
||||||
} else
|
|
||||||
if(flags.verbose) You("drop %s.", doname(obj));
|
|
||||||
}
|
}
|
||||||
dropx(obj);
|
dropx(obj);
|
||||||
return(1);
|
return(1);
|
||||||
@@ -514,7 +512,11 @@ register struct obj *obj;
|
|||||||
if (obj->oclass == COIN_CLASS) flags.botl = 1;
|
if (obj->oclass == COIN_CLASS) flags.botl = 1;
|
||||||
freeinv(obj);
|
freeinv(obj);
|
||||||
#endif
|
#endif
|
||||||
if (!u.uswallow && ship_object(obj, u.ux, u.uy, FALSE)) return;
|
if (!u.uswallow) {
|
||||||
|
if (ship_object(obj, u.ux, u.uy, FALSE)) return;
|
||||||
|
if (IS_ALTAR(levl[u.ux][u.uy].typ))
|
||||||
|
doaltarobj(obj); /* set bknown */
|
||||||
|
}
|
||||||
dropy(obj);
|
dropy(obj);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -84,9 +84,9 @@ register struct obj *pen;
|
|||||||
You("need hands to be able to write!");
|
You("need hands to be able to write!");
|
||||||
return 0;
|
return 0;
|
||||||
} else if (Glib) {
|
} else if (Glib) {
|
||||||
dropx(pen);
|
|
||||||
pline("%s from your %s.",
|
pline("%s from your %s.",
|
||||||
Tobjnam(pen, "slip"), makeplural(body_part(FINGER)));
|
Tobjnam(pen, "slip"), makeplural(body_part(FINGER)));
|
||||||
|
dropx(pen);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user