In Inform 6M62, I’ve added these lines to allow the player to attempt to wake an inanimate object. I adapted these lines from the “Typed commands leading to this action” section of the Actions index, so I think these are equivalent to the built-in understand lines used for waking people, but with the “something” token. (I doubt anyone would ever type “awaken up,” but whatever.)
Understand “wake [something]” as waking.
Understand “awake [something]” as waking.
Understand “awaken [something]” as waking.Understand “wake [something] up” as waking.
Understand “awake [something] up” as waking.
Understand “awaken [something] up” as waking.Understand “wake up [something]” as waking.
Understand “awake up [something]” as waking.
Understand “awaken up [something]” as waking.
This mostly seems to be working, but I’m running into an issue where if the player character is in a different room from certain inanimate objects, trying to wake the thing gives the response “You can only do that to something animate,” when I was expecting the response “You can’t see any such thing.”
Here’s an example:
Understand "wake [something]" as waking.
Understand "awake [something]" as waking.
Understand "awaken [something]" as waking.
Understand "wake [something] up" as waking.
Understand "awake [something] up" as waking.
Understand "awaken [something] up" as waking.
Understand "wake up [something]" as waking.
Understand "awake up [something]" as waking.
Understand "awaken up [something]" as waking.
Room 1 is a room. "This is Room 1. To the south is Room 2."
A statue is in Room 1.
A pink paintbrush is in Room 1.
Room 2 is a room. Room 2 is south of Room 1.
A woman called Rachel is in Room 2.
A pencil is in Room 2.
An eraser is a kind of thing.
A pink eraser is an eraser in Room 2.
A white eraser is an eraser in Room 2.
Test me with "wake white eraser/wake pink eraser".
Output:
Room 1
This is Room 1. To the south is Room 2.
You can see a statue and a pink paintbrush here.
>test me
(Testing.)
>[1] wake white eraser
You can't see any such thing.
>[2] wake pink eraser
You can only do that to something animate.
If I comment out the pink paintbrush in the code, I get this output instead (which is what I would expect):
Room 1
This is Room 1. To the south is Room 2.
You can see a statue here.
>test me
(Testing.)
>[1] wake white eraser
You can't see any such thing.
>[2] wake pink eraser
You can't see any such thing.
Any suggestions?