The usual way to put one object inside another is to make the outer one
a container, and put the inner one physically inside it. However, that
won't work in your situation. You need to get the file `changes.txt'
from the Inform Library directory (/if-archive/infocom/compilers/inform/
library), and read item 14, which describes the new `add_to_scope'
property, which can be made to do what you want.
> Consider a bomb in a room, which will explode in say 5 moves, but
> which, when put in say, a dumb waiter, will fall elsewhere.
Presumably you have implemented the bomb using a timer. All you need to
do is to check in the `time_out' routine where the bomb is, and modify
the result accordingly. For example:
Object bomb "bomb"
with ...
time_out [;
if (self in dumb_waiter) {
remove self;
if (player in dining_room)
"^You hear a loud explosion from below.";
if (player in cellars)
"^You hear a loud explosion to the north.";
"^You hear an explosion somewhere in the distance.";
}
if (parent(self) == player or location)
deadflag = 1;
"^The bomb explodes, killing you!";
}
... and so on (other locations for the bomb) ...
];
-- Gareth Rees