Doing bad things [I7]

Hi all,

The Inform 7 parser has a huge list of actions you can do; run jump kick etc., and the default action for most is that nothing happens. I want to collect a subset of these actions and combine them into one rule, so I can deal with them all at once.

Specifically, all the “bad” things the player can attempt to do to an NPC - kick/punch/slap/poke/kill/stab etc. etc. so that if the player tries them against a “protected” NPC, then something bad happens to the PC, probably being hauled off to jail.

My question is, does Inform have a way of lumping these actions together built-in, or do I have to list them all individually in my new “doing bad” action?

thanks :slight_smile:

Most of those are already defined as synonyms for “attacking”. But you can “combine” actions like this:

Attacking someone is misbehavior. Kissing someone is misbehavior. Eating someone is misbehavior. Pushing someone is misbehavior.

Instead of misbehavior when the noun is the constable:
    say "That would be a very bad idea."

:sunglasses: Cool, thanks for that. Makes things a bit easier!