fix #H7226 - vault guard should have whistle

Implement the suggestion that since teleporting away from the vault
while being confronted by the guard results in a shrill whistling
sound, the vault guard ought to have a tin whistle in his inventory.

I also added a check that he does have the whistle and to give an
alternate message if not, but after half a dozen tries to have a
squad of beefed up monkeys steal the whistle, they never accomplished
that.  At least three times they took everything except the whistle
but I never succeeded in verifying the alternate message.
This commit is contained in:
PatR
2018-06-15 16:24:02 -07:00
parent 3eb452ad94
commit f81818e85d
3 changed files with 20 additions and 5 deletions

View File

@@ -665,7 +665,10 @@ register struct monst *grd;
grd->mpeaceful = 0;
letknow:
if (!cansee(grd->mx, grd->my) || !mon_visible(grd))
You_hear("the shrill sound of a guard's whistle.");
You_hear("%s.",
m_carrying(grd, TIN_WHISTLE)
? "the shrill sound of a guard's whistle"
: "angry shouting");
else
You(um_dist(grd->mx, grd->my, 2)
? "see %s approaching."