Re: Inform: before routines for Exit?


18 Aug 1995 08:39:09 GMT

Julian Arnold <jools@arnod.demon.co.uk> wrote:
> before [;
> Lock, Unlock:
> give self ~open;
> rfalse;
> Enter, Exit:
> give self open;
> rfalse;
> ],

This definition doesn't work because the `Exit' verb doesn't take an
object, so the `before' routine will never be called. The thing to do
is to write a `GamePreRoutine' to deal with this case:

[ GamePreRoutine;
if (action == ##Exit or ##GetOff && player in car) give car open;
];

--
Gareth Rees