Checking if an item has been examined for a description

I am trying to have a check in an item’s description to see if it has been examined or not.

Right now I have:

[Examining Items]

A thing can be examined or unexamined.

A thing is usually unexamined.

Carry out examining something:
	now the noun is examined.

[Pyramid Top]

The Pyramid Top is a room. The description of the Pyramid Top is "There's a giant gem here!"

Understand "gem/crystal" as Amber when the player is in the Pyramid Top.

The Crux Amber is a thing and a scenery in the Pyramid Top. "[if the Crux Amber is unexamined]It's actually not a gem, it's a giant amber![otherwise]It's still an amber!"

It seems to be unable to understand the unexamined property while being used as an if statement in text descriptions. Am I wording it wrong or do I need to make a true/false value to see if the item has been examined? And if so, do I even need to define examining for this purpose?

You have misspelled “otherwise” as “othewise”.

I think what you want is was unexamined.

1 Like

Or better:

After examining something:
	now the noun is examined.

and leave is unexamined alone.

EDIT: The problem is you were changing the amber to examined before printing the description, so it never got the chance to print the unexamined version.

3 Likes

I think you can also do “[if we have examined the X]blarg[otherwise]different blarg[end if].”

(lLike, this is built into Inform, you don’t need to define a new examined/unexamined property).

4 Likes

to add: you want “after” because otherwise the property will change during the examining sequence

you can also drop the property altogether.

The Crux Amber is a thing and a scenery in the Pyramid Top. "[unless we have examined the crux amber]It's actually not a gem, it's a giant amber![otherwise]It's still an amber!"

note that…

ninja’d!

5 Likes

Thank you. :slightly_smiling_face:

This worked great.

Yeah it works, but I think Mike and Drew have the better solution, because it doesn’t involve creating an extra property (“examined/unexamined”).

2 Likes

Ah, I see, thank you. :slight_smile:

This makes sense, it was just worded differently than I had expected.

1 Like

I’ve felt the same way. While the documentation uses the phasing in examples, it never explains the wording or usage directly (unless I’ve missed something).

See WI §9.12 Actions as conditions and WI §9.13 The past and perfect tenses.

1 Like

ah yep, there it is!

1 Like