Odd response when pushing a noun with a second noun (6M62)

This is odd, I’m not sure if it’s been flagged before though.

The broom cupboard is a room. A bucket is in the broom cupboard. A mop is in the broom cupboard.
broom cupboard
You can see a bucket and a mop here.

>get mop

>hit bucket with mop
I only understood you as far as wanting to hit the bucket.

>push bucket with mop
You can't see any such thing.

Also, rules tracing doesn’t seem to be working for me either:

Rules tracing now switched on. Type "rules off" to switch it off again, or "rules all" to include even rules which do not apply.

>hit bucket with mop
I only understood you as far as wanting to hit the bucket.

>push bucket with mop
You can't see any such thing.

Any idea what’s going on?

1 Like

These are the relevant understand lines from the Standard Rules:

Understand "push [something]" as pushing.
Understand "push [something] [direction]" or "push [something] to [direction]" as pushing it to.
Understand "attack [something]" as attacking.
Understand the commands "break", "smash", "hit", "fight", "torture", "wreck", "crack", "destroy",
    "murder", "kill", "punch" and "thump" as "attack".

Without there being an understand line something like hit [thing] with [thing] (which would have to be associated with a two-thing action) the parser knows you’re trying to hit something and thinks what you’re trying to hit is something called “bucket with mop”. When you have something that starts off looking like a coherent command – a good verb and something that could resolve to something in scope – followed by what the parser thinks is junk, you get “I only understood you as far as wanting to […]” instead of “You can’t see any such thing.”

It looks like you get “You can’t see any such thing” with push instead of “I only understood…” as a consequence of there being a two-noun grammar line for push… but I don’t know the details of why.


Oh, that sort of makes sense, thank you. I guess in the case of “push” it’s looking for a direction, and as it can’t interpret “with mop” as a direction, it gives a very unhelpful response. “PUSH [NOUN] [NOUN]” is a bit of an exception to the way commands are usually formatted in Inform.

1 Like

I try to avoid grammar lines like this “push [something] to [direction]” for precisely this reason. I instead use check rules to restrict types, unless there is some other action that can catch all the other possibilities. Such as:

A ticket is a kind of thing.
Understand "punch [ticket]" as ticket-punching.
Understand "punch [something]" as attacking.

That avoids unhelpful error messages.


That’s exactly correct. Push [something] [direction] was the closest to a matching grammar line the parser found, but having failed to match anything to [direction] you get the standard ‘nothing found in scope that I could match to this object-related-token’ response- i.e. ‘You can’t see any such thing’.

1 Like