1
0
Fork 0
mirror of https://github.com/ganelson/inform.git synced 2024-07-07 17:44:22 +03:00
inform7/resources/Documentation/Examples/MattressKing.txt
2023-07-24 21:57:30 +01:00

23 lines
1.1 KiB
Plaintext

Example: * Mattress King
Location: Going by, going through, going with
RecipeLocation: Going, Pushing Things in Directions
Index: PUSH something a direction with extra phrasing
Description: Adding extra phrasing to the action to PUSH something in a direction.
For: Z-Machine
By default, when the player pushes something a direction, Inform checks to make sure that the object is pushable between rooms. If not, it blocks the action; if so, it carries out a normal going action with the pushed object taken along.
Also by default, this action produces only a description of the new room that we've traveled into. But suppose we would like to print a short message describing the pushing action first:
{*}"Mattress King"
Monica's Bedroom is a room. The Living Room is south of Monica's Bedroom. Rachel's Bedroom is south of the Living Room.
After going a direction (called way-pushed) with something (called the thing-pushed):
say "You push [the thing-pushed] [way-pushed] to [the location].";
continue the action.
The race car bed is an enterable supporter in Monica's Bedroom. It is pushable between rooms.
Test me with "push bed south".