Skip to content

Commit

Permalink
extremely porous boulders (trunk only)
Browse files Browse the repository at this point in the history
     This is another item from "#Q397: List of Bugs from #nethack" sent
in Janurary by <email deleted> and containing a list
of things collected from the IRC channel associated with nethack.alt.org's
public server.  Using F prefix and moving toward a boulder would give
"You attack thin air."  Now that'll be "You harmlessly attack a boulder."
  • Loading branch information
nethack.rankin committed Jul 17, 2007
1 parent ce01846 commit f17e97b
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 5 deletions.
1 change: 1 addition & 0 deletions doc/fixes35.0
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,7 @@ can't swap places with tame grid bug when moving diagonally
can't move diagonally through a long worm's body (can still fight that way)
require confirmation to read a scroll of mail if doing so will be the first
violation of illiteracy conduct
using F to force an attack towards a boulder gave "you attack thin air"


Platform- and/or Interface-Specific Fixes
Expand Down
21 changes: 16 additions & 5 deletions src/hack.c
Original file line number Diff line number Diff line change
Expand Up @@ -1203,17 +1203,28 @@ domove()
if (context.forcefight ||
/* remembered an 'I' && didn't use a move command */
(glyph_is_invisible(levl[x][y].glyph) && !context.nopick)) {
struct obj *boulder = sobj_at(BOULDER, x, y);
boolean explo = (Upolyd && attacktype(youmonst.data, AT_EXPL));
char buf[BUFSZ];
Sprintf(buf,"a vacant spot on the %s", surface(x,y));
You("%s %s.",
char buf[BUFSZ];

if (boulder)
Strcpy(buf, ansimpleoname(boulder));
else if (!Underwater)
Strcpy(buf, "thin air");
else if (is_pool(x, y))
Strcpy(buf, "empty water");
else /* Underwater, targetting non-water */
Sprintf(buf, "a vacant spot on the %s", surface(x,y));
You("%s%s %s.",
!boulder ? "" : !explo ? "harmlessly " : "futilely ",
explo ? "explode at" : "attack",
!Underwater ? "thin air" :
is_pool(x,y) ? "empty water" : buf);
buf);
unmap_object(x, y); /* known empty -- remove 'I' if present */
if (boulder) map_object(boulder, TRUE);
newsym(x, y);
nomul(0);
if (explo) {
wake_nearby();
u.mh = -1; /* dead in the current form */
rehumanize();
}
Expand Down

0 comments on commit f17e97b

Please sign in to comment.