fix #H7155 - polearm can reveal hidden monster

The code to choose a likely target when applying a polearm was
basing its decision on visible spots which contained monsters,
so could expose the location of a hidden monster if there was
only one such spot within polearm range.  Not mentioned in the
report:  it also wouldn't pick remembered, unseen monster unless
there was a monster still at that spot.

I've changed it to choose candidate location based on the glyphs
shown rather than on the presence of monsters.
This commit is contained in:
PatR
2018-05-19 15:46:09 -07:00
parent 98099863ff
commit b17c6d0b54
2 changed files with 38 additions and 17 deletions

View File

@@ -17,6 +17,7 @@ numeric hilite_status values didn't allow negative numbers (needed for AC);
permanent inventory window was updated too soon when a scroll of charging
was used to [re]charge an item, not reflecting the item's change(s)
for starting inventory, don't give an orc hero lembas wafers or cram rations
targetting with a polearm could give away location of hidden monster
Fixes to Post-3.6.1 Problems that Were Exposed Via git Repository