Inform 7: Hiding Object Descriptions in Main Room Descriptions

My goal is this: I want to have objects in a room have a description, but I don’t want that description to be displayed in the main room description. For example:

Your Bedroom is a room. The printed name of Your Bedroom is "[player's forename]'s Bedroom.". "Your Bedroom. It is messy, with clothes strewn about the floor." 

The music poster is in Your Bedroom. "A poster of one of your favorite bands, (insert band here), a metal band."

I don’t want to just classify an object like the poster as scenery, because I want it to be movable, and I feel like there’s a solution to this I’m missing. Anyone know how I can solve my problem?

From your code the intended behavior is a little unclear – specifically, I think you want the “A poster of one of your favorite bands…” text to be the poster’s description, not the initial appearance, since the rest of your message seems to indicate you don’t want the player to necessarily see that in the main bedroom description, right? But you do want to indicate that there is a poster there?

If that’s the case, you can do this:

Your Bedroom is a room. The printed name of Your Bedroom is "Your Bedroom.". "Your Bedroom. It is messy, with clothes strewn about the floor[if the music poster is in your bedroom and the music poster has not been handled].  There's a [music poster] on the wall[end if]." 

The music poster is in Your Bedroom.  The description is "A poster of one of your favorite bands, (insert band here), a metal band."

If you want it not to be mentioned at all, you can do that too:

Your Bedroom is a room. The printed name of Your Bedroom is "Your Bedroom.". "Your Bedroom. It is messy, with clothes strewn about the floor." 

The music poster is in Your Bedroom.  The description is "A poster of one of your favorite bands, (insert band here), a metal band."

Before listing nondescript items:
	If the music poster is marked for listing and the music poster has not been handled:
		Now the music poster is not marked for listing.

(In both cases I put in the “music poster has not been handled” condition since I assume if the player takes the poster, it’s no longer on the wall and it makes sense to treat it as an ordinary inventory object).

2 Likes

Ah, thank you! The bit with “Before listing nondescript items:” did perfectly for what I needed. Thank you so much for the help!

1 Like