Inform 7 doesn't seem to recognise a new command as an action

I’m currently trying to develop a scenario where the player “hits” an NPC named Jimmy with a weapon (which has been defined as a kind of thing) that is the ice pick. Here’s how the action of hitting is currently defined.

Hitting is an action applying to two visible things.

Understand "hit [someone] with [weapon preferably held]" as hitting

Here is the line that Inform 7 doesn’t seem to understand.

Instead of hitting Jimmy with the Ice Pick:

What exactly am I doing wrong that gives me this message?

Problem. You wrote ‘Instead of hitting Jimmy with the Ice Pick’ , which seems to introduce a rule taking effect only if the action is ‘hitting Jimmy with the Ice Pick’. But that did not make sense as a description of an action. I am unable to place this rule into any rulebook.

When defining an action applying to 2 things, your action name must reflect that.
Hitting it with is an action…
Understand … as hitting it with.

When you want the Inform code to include a preposition you have to define the action with the preposition: “Hitting it with is an action applying to two visible things.”

1 Like