1
<HTML><HEAD><TITLE>Answer to Exercise 84</TITLE></HEAD>
2
<BODY BGCOLOR="#FFFFFF">
3
<TABLE><TR><TD Valign="top"><IMG SRC="../icons/exercise.gif" ALT="??"><TD bgcolor="#FAA89B"><B>ANSWER TO EXERCISE 84</B><TR><TD><TD>
6
In the <TT>Initialise</TT> routine, move <TT>newplay</TT> somewhere and
7
<TT>ChangePlayer</TT> to it, where:
9
Object newplay "yourself"
10
with description "As good-looking as ever.", number 0,
14
[; Inv: if (nose has general) print "You're holding your nose. ";
15
Smell: if (nose has general)
16
"You can't smell a thing with your nose held.";
18
has concealed animate proper transparent;
21
with name "nose", article "your",
23
[; Take: if (self has general)
24
"You're already holding your nose.";
25
if (children(player) > 1) "You haven't a free hand.";
26
give self general; player.capacity=1;
27
"You hold your nose with your spare hand.";
28
Drop: if (self hasnt general) "But you weren't holding it!";
29
give self ~general; player.capacity=5;
30
print "You release your nose and inhale again. ";
31
<<Smell>>;
37
<HR>Back to <A HREF="../section28.html#ex84">the exercise in section 28</A><HR>
38
<SMALL><I>Mechanically translated to HTML from third edition as revised 16 May 1997. Copyright © Graham Nelson 1993, 1994, 1995, 1996, 1997: all rights reserved.</I></SMALL></BODY></HTML>