Section - Navigate by room names
[Speed tests showed that the below method was significantly faster than using Inform's built-in pathfinding, which became very significant when travelling via landmark, where both Progue and the player would be doing this calculation multiple times per move.]
To head to (destination - a room):
if the room north of location is destination begin; try going north;
else if the room northeast of location is destination; try going northeast;
else if the room east of location is destination; try going east;
else if the room southeast of location is destination; try going southeast;
else if the room south of location is destination; try going south;
else if the room southwest of location is destination; try going southwest;
else if the room west of location is destination; try going west;
else if the room northwest of location is destination; try going northwest;
else if destination is above location; try going up;
else if destination is below location; try going down;
else if the room inside location is destination; try going inside;
else if the room outside from location is destination; try going outside;
else; try going north;
end if.
Rule for clarifying the parser's choice of a room: do nothing instead.