I can’t work out why my ‘supplying a missing noun rule’ isn’t working.
squishing is an action applying to one thing.
Understand “squish [something]” as squishing.
Rule for supplying a missing noun while squishing:
now noun is the grass.[/code]
Now I just made it the grass here because that’s a backdrop that’s everywhere, but I’ve tried all kinds of objects in the game which should be available to the player, and in every case when I just type ‘squish’ (and when I trace the actions/rules), the game goes through the player’s inventory one item at a time, rejecting most items because they’re all ranked as ‘unlikely’ by me, then settles on the last inventory item, whose rank is the default ‘possible’.
So in short, I have yet to supply a missing noun. The noun always ends up being one particular item in the player’s inventory.
Why is this happening?
“Supplying a missing noun” is only invoked when the understand declaration is missing a noun. That is, if you said
Squishing is an action applying to one thing.
Understand "squish" as squishing.
Understand "squish [something]" as squishing.
In this case, if the player types “squish”, that matches the first grammar and triggers this activity. Without that grammar line, it’s all handled by the “Does the player mean…” mechanism.
Thanks. It looks like I still don’t know all the vagaries of how to define commands. I just did some experiments now, variously making an action (zotting) apply to nothing and to one thing, and setting it up with grammar “zot” as zotting, “zot [something]” as zotting - one or the other or both - and mixed and matched all these combination to see how they responded. Each combination does something a bit different, so I guess there’s a use for each way.
Even the examples in the documentation have gotten this wrong (“Four Cheeses” IIRC, which left out one of the “understand” lines but worked anyway for unrelated reasons), so I think it’s officially a tricksy area.
I ran into the same problem (and posted an inquiry, which was promptly answered) about a week ago. Now I don’t feel so bad about missing the point in the documentation.