Add extra names for the bears, fix mall exit, fix some line wrapping
[the-mall.git] / the-mall.inf
1 ! Copyright (C) 2019 Jason Self <j@jxself.org>
2 !
3 ! This file is free software: you may copy, redistribute and/or modify 
4 ! it under the terms of the GNU Affero General Public License as 
5 ! published by the Free Software Foundation, either version 3 of the 
6 ! License, or (at your option) any later version.
7 !
8 ! This file is distributed in the hope that it will be useful, but 
9 ! WITHOUT ANY WARRANTY; without even the implied warranty of 
10 ! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 
11 ! Affero General Public License for more details.
12 !
13 ! You should have received a copy of the GNU Affero General Public 
14 ! License along with this file. If not, see https://gnu.org/licenses/
15 Constant NO_SCORE;
16 Constant Story "The Mall";
17 Constant Headline 
18     "^By Jason Self^
19     ^If you get stuck try typing HELP.^
20     Send bugs and feedback by email to j@@64jxself.org.^
21     Copyright (C) 2019 Jason Self^
22     This game gives you freedom; you can change and share it under 
23     the terms of the GNU Affero General Public License as published by 
24     the Free Software Foundation, either version 3 of the License, or 
25     (at your option) any later version. See the GNU Affero General 
26     Public License for details.^
27     IFID 1AB626D5-E03F-4F03-836C-50F65B643B9B^";
28 Include "parser";
29 Include "verblib";
30 Release 0;
31 Serial "190717";
32
33 Object  bank "Bank of Zork"
34   with  description 
35             "The local branch of the Bank of Zork, the largest banking 
36             institution of the Great Underground Empire. The walls are 
37             redpainted and there is a distinct wash of pine and 
38             sandalwood that hovers in the air. Beyond the lobby of the 
39             bank, to the north, lies the vault. The air there is 
40             dark-- almost heavy-- and thick with the scents of fresh 
41             paper and silver and copper. A darkened office sits to the 
42             south. As with all branches of the Bank of Zork, a 
43             portrait of J. Pierpont Flathead hangs on the wall.",
44         n_to vaultdoor,
45         s_to securityoffice,
46         w_to mall,
47   has   light;
48
49 Object  closet "Closet"
50   with  description 
51             "In the closet of the workshop, it is mostly dark. Here 
52             lie the new supplies waiting to be taken out to customers 
53             to make new teddy bears. Their beady eyes glisten as they 
54             reflect the light from the workshop, their bodies deflated 
55             in some places, bulging unnaturally in others.",
56         e_to workshop,
57   has   light;
58
59 Object  bears "teddy bears" closet
60   with  name 'bear' 'bears' 'teddy' 'teddies' 'ted' 'eye' 'eyes' 
61               'supply' 'supplies' 'bulge' 'bulges',
62         before [;
63           Take, Pull, Push, PushDir:
64             print_ret "Shoplifting isn't the answer.";
65         ],
66   has   scenery;
67
68 Object  cookhouse "Cookhouse"
69   with  description 
70             "The glowing letters atop indicate that this restaurant is 
71             called ~The Cookhouse.~ There's a light smokiness in the 
72             air, and the tables are covered in soft-looking linen 
73             tablecloths. Although, since the mall closed, all of the 
74             patrons have left.",
75         n_to mall,
76   has   light;
77
78 Object  table2 "table" cookhouse
79   with  name 'table',
80   has   scenery supporter;
81
82 Object  tablecloth "tablecloth" table2
83   with  name 'tablecloth' 'linen' 'cloth',
84         description "It's made of soft-looking linen.",
85         before [;
86           Take, Pull, Push, PushDir:
87             print_ret "Shoplifting isn't the answer.";
88         ],
89   has   scenery;
90
91 Object  securityoffice "Security Office"
92   with  description 
93             "A small office belonging to the bank's security officer. 
94             You scan the room, seeing a table and a large bulky 
95             television.",
96         n_to bank,
97   has   light;
98
99 Object  television "television" securityoffice
100   with  name 'television' 'tv' 'screen' 'monitor',
101         description 
102             "It's big, gray, and one of those old-fashioned CRT 
103             models.",
104         watch_count 0,
105         before [;
106           Listen, Examine:
107             if (television has on) {
108                 self.watch_count = self.watch_count + 1;
109                 switch (self.watch_count) {
110                   default:
111                     print 
112                         "It's big, gray, and one of those 
113                         old-fashioned CRT models. It looks very 
114                         heavy.^The TV is currently switched on. It's 
115                         showing grainy footage at odd angles from the 
116                         vault's security cameras.^";
117                     return true;
118                 }
119             }
120             ;
121           Take, Pull, Push, PushDir:
122             print_ret "The television is firmly attached to the wall.";
123         ],
124         after [;
125           SwitchOn:
126             print 
127                 "The television comes to life, showing grainy footage 
128                 at odd angles from the vault's security cameras.^";
129             return true;
130         ],
131   has   scenery switchable;
132
133 Object  table "table" securityoffice
134   with  name 'table',
135         description 
136             "Made from metal, it looks to be a solid and hefty table.",
137   has   scenery supporter;
138
139 Object  coppercoin "copper coin" table
140   with  name 'copper' 'coin' 'zorkmid',
141         description 
142             "The coin seems to be very old, in very poor condition, 
143             and somewhat irregular in shape. The only things clearly 
144             visible are what appears to be a name on one side: Belwit 
145             The Flat and a date on the other: 699 GUE.";
146
147 Object  keycard "keycard" table
148   with  name 'keycard' 'key' 'card',
149         description "The keycard is used to open things.";
150
151 Object  mall "Mall"
152   with  description 
153             "You're in the main walkway. It's bright and clean with 
154             stores all around. Pale light glimmers off the polished 
155             tile like sunlight on water. The quietness of the closed 
156             mall floats by as if on the wind. The mall's exit is to 
157             the southwest.",
158         n_to workshop,
159         s_to cookhouse,
160         sw_to mallexit,
161         e_to bank,
162         w_to salon,
163   has   light;
164
165 Object  tile "tile" mall
166   with  name 'tile' 'tiles',
167   has   scenery;
168
169 Object  walkway "walkway" mall
170   with  name 'walkway' 'hallway',
171   has   scenery;
172
173 Object  stores "stores" mall
174   with  name 'store' 'stores' 'shop' 'shops',
175   has   scenery;
176
177 Object  mallexit "door" mall
178   with  name 'door' 'exit' 'glass',
179         description 
180             "A revolving door to the outside world, with the word 
181             ~Exit~ written above. Sunlight streams crisply in through 
182             the glass.",
183         with_key keycard,
184         after [;
185           unlock:
186             deadflag = 2;
187             return true;
188         ],
189   has   scenery door lockable openable locked;
190
191 Object  portrait "portrait" bank
192   with  name 'portrait' 'picture' 'photo',
193         description 
194             "It's a portrait of J. Pierpont Flathead. His portrait 
195             adorns every branch of the Bank of Zork.",
196         before [;
197           Take, Pull, Push, PushDir:
198             print_ret (The) self, " is firmly attached to the wall.";
199         ],
200   has   scenery;
201
202 Object  salon "Salon"
203   with  description [;
204             print "You've just sauntered into a salon.";
205             if (salon hasnt visited)
206                 print 
207                     " Suddenly you bump your head 
208                     on the ceiling, but it's not such a bad bump that 
209                     it's going to prevent you from looking at 
210                     things.";
211             if (salon has visited)
212                 print 
213                     " Remembering the low ceiling, 
214                     you take care not to bump your head.";
215             print 
216                 " Behind the reception desk is a small display made up 
217                 of backlit shampoos and conditioners in various shades 
218                 of translucent blue. Continuing to the west is another 
219                 room.";
220             new_line;
221         ],
222         e_to mall,
223         w_to salon2,
224   has   light;
225
226 Object  desk "reception desk" salon
227   with  name 'desk' 'reception',
228   has   scenery;
229
230 Object  shampoo "shampoos" salon
231   with  name 'shampoo' 'shampoos' 'display',
232         before [;
233           Take, Pull, Push, PushDir:
234             print_ret "Shoplifting isn't the answer.";
235         ],
236   has   scenery;
237
238 Object  conditioner "conditioners" salon
239   with  name 'conditioner' 'conditioners',
240         before [;
241           Take, Pull, Push, PushDir:
242             print_ret "Shoplifting isn't the answer.";
243         ],
244   has   scenery;
245
246 Object  salon2 "Salon"
247   with  description 
248             "This is a tranquil glasslit room where the stylists 
249             would work on peoples' hair. You can imagine the sounds of 
250             clipping shears and buzzing razors resounding through the 
251             air with the clarity of a ringing bell when this place is 
252             open.",
253         e_to salon,
254   has   light;
255
256 Object  vaultdoor "vault door" bank
257   with  name 'vault' 'safe',
258         description 
259             "A large, circular, and hefty door. The words 
260             ~Manufactured By The Frobozz Magic Vault Company~ are 
261             engraved around the edge.",
262   has   scenery door openable locked;
263
264 Object  workshop "Bear Workshop"
265   with  description 
266             "A workshop for making stuffed bears although by now 
267             everything is put away. The workshop retains a pleasant 
268             atmosphere. You should try going west.",
269         w_to closet,
270         s_to mall,
271   has   light;
272
273 [ Initialise;
274     Location = mall;
275     "^You fell asleep in the mall. Now it's closed, and the exit's 
276     locked. Can you get out?";
277 ];
278
279 [ XyzzySub;
280     "Nothing obvious happens.";
281 ];
282
283 [ HelpSub;
284     "If you need help try some of the commands from:
285     ^http://pr-if.org/doc/play-if-card/";
286 ];
287
288 Include "grammar";
289
290 Verb 'About'
291     * -> Version;
292
293 Verb 'Info'
294     * -> Version;
295
296 Verb 'Help'
297     * -> Help;
298
299 Verb 'xyzzy'
300     * -> Xyzzy;