I'm not a beginner, but...

I’ve been using Inform 7 for a while now, and recently got 5G67. I decided to make a Kingdom hearts II IF, but am having problems making “reaction commands”. Here’s a snippet early on that’s not causing me the problem:

The player has a text called the reaction command. When play begins: change the reaction command to “None”; change the left hand status line to “(the player’s surroundings)/(the reaction command of the player)”.

Now here’s the part that causes me the trouble:

Using the reaction command is an action applying to nothing. Understand “(the reaction command of the player)” as using the reaction command. Check using the reaction command: say “Nothing happens.”

By the way, I replaced brackets like [ and ] with parentheses ( and ). And I can easily make rules that override that check rule, so nevermind that. From what I can tell, it’s the “Understand so and so as this and that” part that causing the errors. Obviously, that part is rejecting the (the reaction command of the player) part.
So, I need help! What can I do to get this to accept it, or do I need to change the scheme of the reaction commands completely? Anything would be appreciated!

Two things:

  • not sure about this, but I think you want ‘indexed text’ rather than text – see section 19.7.

  • when you write ‘change the reaction command to foo’, Inform isn’t sure whose reaction command you mean, because it doesn’t know whose property you’re referring to. I’m surprised you didn’t get a run-time error with just the first expression you quoted. What you want then is:


"Reaction"

The Apartment is a room. 

The player has an indexed text called the reaction command.

When play begins: change the reaction command of the player to "none"; change the left hand status line to "[the player's surroundings]/[the reaction command of the player]".

Using the reaction command is an action applying to one topic. Understand "[text]" as using the reaction command. 

Check using the reaction command: if the topic understood matches the text the reaction command of the player begin; say "Nothing happens."; otherwise; say "Try again."; end if.

test me with "foo / none"

Because I couldn’t get at the reaction command property via direct substitution, that’s what I came up with.

Note that I had to change the property to lowercase ‘none’ to work simply with the test, but I’m pretty sure you can get around that for your own tests.

I made a mistake in my post. I DID do “change the reaction command of the player to so and so” instead of “change the reaction command to so and so”. But, that last bit you posted… that helps. THANK YOU!