remove prescient travel command behavior

Addresses reports R718, R772.1, <Someone> P's extra move bug
- when there is a previously seen path or a straight path, always take it
- incorporate fix to ensure no extra "." turn at the end of traveling, but
 still avoid stepping into traps/pools, et al
- include a general "G"-command (and travel) fix to avoid stepping in
 known pools/lava while blind
- when there is no such path, "guess" at a path by finding an intermediate
 location that the hero couldsee that is closest to the actual goal, the
 intermediate goal is re-determined at each step
- when Blind, don't use couldsee for determining straight paths, just direction
- do not consider doors or most boulders obstacles for picking travel
 paths, test_move has a new mode to differentiate this case from the regular
 test case
- don't include known trap locations in the travel path, avoids unnecessary
 stops along the way, and usually doesn't affect the path length
- reformatted the code a bit so I could follow it
This commit is contained in:
cohrs
2002-04-13 16:00:13 +00:00
parent a41aec240e
commit 1b321e92bc
7 changed files with 161 additions and 61 deletions

View File

@@ -27,7 +27,7 @@
\begin{document}
%
% input file: guidebook.mn
% $Revision: 1.39 $ $Date: 2002/03/31 07:19:43 $
% $Revision: 1.40 $ $Date: 2002/04/04 03:44:18 $
%
%.ds h0 "
%.ds h1 %.ds h2 \%
@@ -638,7 +638,10 @@ Prefix: Same as `{\tt g}', but forking of corridors is not considered
interesting.
%.lp
\item[\tb{_}]
Travel to a map location via a shortest-path algorithm. Stops on most of
Travel to a map location via a shortest-path algorithm. The shortest path
is computed over map locations the hero knows about (e.g. seen or
previously traversed). If there is no known path, a guess is made instead.
Stops on most of
the same conditions as the `G' command, but without picking up
objects, similar to the `M' command. For ports with mouse
support, the command is also invoked when a mouse-click takes place on a