Skip to reading
Text & Sierra-Style Adventures

41. Add a new verb and its failure replies

Edition 0.86.3.4

Build a complete text or graphical parser adventure with typed commands, inventory puzzles and press-to-walk controls.

Download PDFView PDF page

A new verb needs more than a word in a dropdown. If you add RING, decide which objects can be rung and how the game should respond when the player tries the verb on something else.

1. Create a native Ring verb if you also want it in clickable interfaces.

2. Add ring → ring to the controller’s VERBS dictionary.

3. In act(), add the successful ring + bell branch.

4. Leave a useful fallback for RING DOOR, RING RADIO and a missing target.

5. Test it in both presentations and through any action-list call.

For longer verb phrases, normalize the phrase before splitting the command into a verb and target. The controller already does this for PICK UP: it converts PICK UP KEY into TAKE KEY. That is why it can recognize a two-word verb without treating UP as part of the object name.

Source table from 41. Add a new verb and its failure replies, page 44
Player inputHelpful response
RINGWhat do you want to ring?
RING BELLThe bell sounds; the appropriate state changes.
RING RADIOThe radio has a switch, not a bell.
RING UNKNOWN OBJECTA clear missing-target reply.

The exact wording in this extension is a design example. The shipped controller accepts the commands printed in its vocabulary and command reference; it does not already contain the bell extension.

Page 44 of 68Permalink
Go to page