version 9/140814 by Leonardo Boselli
Section - Exits
[This routine is lifted straight from the example in the Inform 7 docs.]
Understand "exits" as listing exits. Listing exits is an action out of world applying to nothing.
Definition: a direction (called thataway) is viable if the room thataway from the location is a room.
Carry out listing exits (this is the Hyperlink Interface carry out listing exits rule):
let count of exits be the number of viable directions;
if the count of exits is 0, say "[It] [seem] there [are] nowhere to go." (A);
otherwise say "From here, [if the number of viable directions is 1]the only way out [are] to[otherwise][we] [can go] to[end if] [a list of viable directions]." (B).