Redirect look to ceiling when a room is not above the player

I think the most difficult part of Inform is coming up with the proper search terms to find what you’re looking for in the documentation. I’d almost rather have a primer on where to look for these things first than the answer to my question. :stuck_out_tongue:

What I want to do is basically this:

[code]The ceiling is a backdrop in Region. “It’s really high up. Hi, ceiling!”

[Pseudocode: If a room is not mapped above the player’s current room:]
Instead of examining up when the player is in Region:
Try examining the ceiling.[/code]

How do I do that? That is, how do I reference the player’s current room, or the current active room in scope, etc.?

The intent being that if “up” is a valid direction, we might want to actually look that way instead of stare at the ceiling.

Is this better accomplished just by overriding the backdrop in rooms where you can go up? (Instead of examining up when the player is in Staircase Room…would that take precedence?)

This seems to work:

Instead of examining up when the location is in Region and the room up from location is not a room: try examining the ceiling.

Thanks, that does work. I would not have guessed that wording. Like saying the chair next to me is not a chair. It’s very…Magritte.

I think “and the room up from location is nothing” works just as well and may be a little less confusing.

You can also try “and no room is mapped up of the location”. (It has to be “up of” and not “up from,” because usually you’re saying “west of” and like tha.)

I suspect this is slightly less efficient, because it loops over every room, but unless you have eleventy-billion rooms it probably shouldn’t be noticeable. And I’m not actually sure it’s less efficient.