Total noob question about doors and containers [action name discrepancy]

Does anyone have an idea why this code doesn’t work?

after putting skull shaped stone is in skull shaped hole:
now small stone door is open;
say “You place the skull shaped stone into the whole. The door begins to shake and open, kicking up a cloud of dust.”

It says it doesn’t understand the action, but it’s an action you can do so I’m not sure what the problem would be. Is there a different way to phrase it?

Problem. You wrote ‘after putting skull shaped stone is in skull shaped hole’, which seems to introduce a rule taking effect only if the action is ‘putting skull shaped stone is in skull shaped hole’. But that did not make sense as a description of an action. I am unable to place this rule into any rulebook.

There’s an extra “is” in “after putting skull shaped stone is in skull shaped hole”.

Welcome to the boards, and don’t worry about asking simple questions - we’ve all been there, many of us quite recently!

Beyond the extraneous “is”, the issue here is that despite appearances there’s no PUT X IN Y action built into inform - when you type that in, the standard rules actually translate it to the INSERT X INTO Y action. So if you rewrite your rule heading to be “After inserting the skull shaped stone into the skull shaped door” it should work!

You can figure this kind of thing out for yourself by using the ACTIONS command in the IDE, by the way - if you type that before typing in a command, it will tell you how the game is actually processing your input.

Also, I probably wouldn’t give the stone and door such similar names since it’s easy to confuse Inform and/or yourself that way - you can make it so the name the player sees is different from the internal name Inform uses by setting the “printed name” property for objects, which can be helpful in these kinds of situations.

Oh, and if you click the little </> icon in the compose message box here, that lets you preserve spacing when pasting in code, which makes it more readable.


Thank you so much! This really helps!

One last thing - don’t forget the difference between a hole and something that is whole :wink: