-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathattack.zil
3247 lines (3085 loc) · 101 KB
/
attack.zil
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
"ATTACK for
SHOGUN
(c) Copyright 1988 Infocom, Inc. All Rights Reserved."
<FILE-FLAGS SENTENCE-ENDS?>
<BEGIN-SEGMENT NINJA>
<BEGIN-SEGMENT YOKOHAMA>
<OBJECT PISTOL
(OWNER BLACKTHORNE)
(DESC "pistol")
(SYNONYM PISTOL GUN)
(FLAGS TAKEBIT WEAPONBIT)
(ACTION PISTOL-F)>
<ROUTINE PISTOL-F ()
<COND (<FSET? ,PISTOL ,NDESCBIT>
<TELL
"You can't find your pistol anywhere! It must have been blown out of
your grasp by the force of the explosion!" CR>)
(<VERB? EXAMINE>
<TELL
"This is a">
<COND (<FSET? ,PISTOL ,RMUNGBIT> <TELL "n unloaded">)
(ELSE <TELL " loaded">)>
<TELL " pistol." CR>)
(<P? LOAD PISTOL (<> POWDER-HORN)>
<COND (<NOT <HELD? ,POWDER-HORN>>
<TELL
"You don't have any powder!" CR>)
(<FSET? ,PISTOL ,RMUNGBIT>
<COND (<QUEUED? I-LOAD-PISTOL>
<TELL
"With all the speed you can, you work on loading the pistol." CR>)
(ELSE
<QUEUE I-LOAD-PISTOL -1>
<TELL
"You begin the laborious task of loading the pistol." CR>)>)
(ELSE
<TELL "It's already loaded." CR>)>)>>
<END-SEGMENT ;"NINJA+YOKOHAMA">
<BEGIN-SEGMENT NINJA>
<OBJECT POWDER-HORN
(LOC BLACKTHORNE-QUARTERS)
(DESC "powder horn")
(SYNONYM HORN POWDER)
(ADJECTIVE POWDER)
(FLAGS TAKEBIT)
(ACTION POWDER-HORN-F)>
<ROUTINE POWDER-HORN-F ()
<COND (<VERB? EXAMINE LOOK-INSIDE>
<TELL
"There is plenty of powder in the horn." CR>)
(<P? PUT POWDER-HORN (TOP-CATCH BOTTOM-CATCH)>
<TELL
"The powder won't stay on the catch." CR>)
(<P? PUT POWDER-HORN PISTOL>
<PERFORM ,V?LOAD ,PISTOL>
<RTRUE>)
(<OR <P? SHOOT PISTOL>
<P? EXPLODE * POWDER-HORN>>
<TELL
"You would blow yourself up too!" CR>)>>
;<GLOBAL LOAD-PISTOL-CNT 0>
<ROUTINE I-LOAD-PISTOL ()
<ZLINES ,LOAD-PISTOL-CNT
(<TELL CR
"First the powder, tamping it carefully." CR>)
(<TELL CR
G"You continue loading the pistol. Next"" the paper plug to hold the charge
tight." CR>)
(<TELL CR
G"You continue loading the pistol. Next"" the lead ball and another
plug." CR>)
(<SETG LOAD-PISTOL-CNT 0>
<FCLEAR ,PISTOL ,RMUNGBIT>
<DEQUEUE I-LOAD-PISTOL>
<TELL CR
G"You continue loading the pistol. Next"", blow the dust carefully away from
the flint. Finished!" CR>)>>
<ROUTINE MARIKO-FOLLOW-ME ()
<COND (<NOT <IN? ,MARIKO ,HERE>>
<COND (<NEXT-ROOM? <LOC ,MARIKO>>
<COND (<QUEUED? I-NINJA-TAKE-MARIKO>
<TELL
"Mariko is struggling with the ninja in the next room. They are trying to
abduct her!" CR>)
(ELSE
<TELL
"Mariko is in the next room." CR>)>)
(ELSE
<TELL
"You no longer know where Mariko is." CR>)>)
(<HERE? ,SECRET-REDOUBT ,BALCONY>
<TELL
"\"No, Anjin-san, I can no longer follow.\"" CR>)
(<QUEUED? I-NINJA-TAKE-MARIKO>
<TELL
"She struggles to free herself from the ninja, but she
can't. \"Help me, Anjin-san!\" she yells." CR>)
(ELSE
<QUEUE I-MARIKO-FOLLOW -1>
<COND (<QUEUED? I-NINJA>
<COND (,CAPTURE-CNT
<TELL
"\"You can't let them take me">)
(ELSE
<TELL
"\"I'll stay close by">)>
<TELL
", Anjin-san.\" she replies." CR>)
(<QUEUED? I-NINJA-COWED>
<TELL
"\"I'm coming!\" she says, rushing to your side." CR>)
(ELSE
<TELL
"\"I will follow you,\" she replies." CR>)>
<SCORE-OBJECT ,MARIKO>)>>
<ROUTINE NINJA-TALK-TO-YABU ()
<COND (<VERB? TELL-ME-ABOUT WHAT>
<COND (<PRSO? ,PLAN>
<COND (<FSET? ,MARIKO ,RMUNGBIT>
<TELL
"Yabu is very nervous. \"I know nothing of any plan!\" he blusters." CR>)
(ELSE
<COND (<ADJ-USED? ,PLAN ,W?SECRET>
<TELL "\"No secret">)
(ELSE
<TELL "\"So sorry">)>
<TELL
", Anjin-san. You misunderstood. Say only must have plan. Very
difficult escape Osaka, neh? Understand?\" Yabu appears somewhat
nervous." CR>
<SCORE-OBJECT ,PLAN>)>)
(<PRSO? ,NINJA ,LG-NINJA>
<TELL
"\"Ninja! Filthy assassins! Who would use ninja! Filth!\" He seems very
agitated and nervous." CR>)
(<PRSO? ,MARIKO>
<COND (<FSET? ,MARIKO ,RMUNGBIT>
<TELL
"\"Mariko is dead, Anjin-san.\"" CR>)
(ELSE
<TELL
"\"She has done a very foolish thing, Anjin-san,\" he says
vehemently. He seems to be suppressing an even stronger response. He is very
nervous." CR>)>)>)
(<AND <VERB? YES HAI>
<HERE? ,OUTER-ROOM>>
<COND (<NOT <FSET? ,PLAN ,SCOREBIT>>
<TELL
"\"Very good, Anjin-san,\" Yabu replies, looking much relieved." CR>)
(<EQUAL? ,YABU-CNT 1 2>
<TELL
"\"Good, good!\" Yabu nods. \"Very worried about Lady Toda.\" He
smiles." CR>)>)
(<AND <VERB? NO IYE>
<HERE? ,OUTER-ROOM>>
<COND (<NOT <FSET? ,PLAN ,SCOREBIT>>
<TELL
"\"Don't worry, Anjin-san,\" Yabu replies, trying to look
unworried." CR>)
(<EQUAL? ,YABU-CNT 1 2>
<TELL
"\"There is no plan, Anjin-san!\" Yabu says. \"I'm only worried about
Lady Toda.\"" CR>)>)
(ELSE
<YABU-WAKARIMASEN>)>>
<ROUTINE NINJA-INTERRUPT-YABU ()
<COND (<JIGS-UP? ,J-CALL-YABU
"You're supposed to be following him, not talking to him!">
<TELL
"Yabu seems surprised to hear you call to him. He turns and says something
to you in an angry tone of voice. You hear the word \""I"kinjiru""\", which
means 'forbidden.' Then Yabu draws his killing sword, advances on you, and
removes your head.">
<JIGS-UP>
<RFATAL>)
(ELSE
<COND (<VERB? TELL>
<END-QUOTE>
<RFATAL>)
(ELSE <RTRUE>)>)>>
<ROUTINE NINJA-FOLLOW-YABU ("AUX" RM)
<SET RM <LOC ,YABU>>
<COND (<HERE? .RM>
<COND (<HERE? ,CELLARS>
<TELL
"He doesn't appear to be going anywhere." CR>)
(,FOLLOW-FLAG
<TELL
"You continue following him, keeping well behind and being as quiet
as possible." CR>)
(ELSE
<SETUP-FOLLOW-YABU>
<TELL
"You follow Yabu, doing your best to avoid being noticed." CR>)>)
(<NEXT-ROOM? .RM>
<COND (,FOLLOW-FLAG
<COND (<HERE? ,INNER-CORRIDOR>
<TELL
"You follow warily behind him, keeping out of sight." CR>)
(<HERE? ,AUDIENCE-CHAMBER>
<TELL
"You follow behind him, bowing to the guards but keeping far enough
behind Yabu that he doesn't know he's being followed." CR>)
(<HERE? ,OUTER-CORRIDOR>
<TELL
"You follow him, letting him get one turn ahead of you on the stairs." CR>)
(<HERE? ,STAIRS>
<TELL
"You slip silently into the servants' quarters, and they stare at you
but don't move. Yabu is heading towards a stairway leading down." CR>)
(<HERE? ,SERVANTS-QUARTERS>
<TELL
"You follow Yabu at a safe distance, sometimes almost losing him in
the labyrinthine cellars. He reaches a large, dimly-lit room full of
boxes and barrels." CR>)
(ELSE
<TELL
"You follow behind as silently and stealthily as you can." CR>)>)
(ELSE
<SETUP-FOLLOW-YABU>
<TELL "You begin following Yabu, ">
<COND (<HERE? ,OUTER-ROOM>
<TELL
"hoping he won't lose you." CR>)
(ELSE
<TELL
"keeping far enough behind that he doesn't realize
he's being followed." CR>)>)>
<CRLF>
<GOTO .RM>
<RTRUE>)
(ELSE
<SETG FOLLOW-FLAG <>>
<TELL "You've lost him!" CR>)>>
<ROUTINE EXAMINE-MARIKO ()
<COND (<FSET? ,MARIKO ,RMUNGBIT>
<COND (<FSET? ,MARIKO ,DEAD>
<TELL
"She seems at peace, sleeping. You move the kimono aside, then
put it back again. Her pulse is almost imperceptible. Then it
ceases.">)
(ELSE
<TELL
"Lady Mariko is broken and dying. She is still alive, but fading
rapidly.">)>
<TELL
"Her face is hardly touched but her body is terribly
mutilated. Around her neck is her rosary, the tiny golden cross
lying on her throat." CR>)
(<QUEUED? I-NINJA-TAKE-MARIKO>
<TELL
"Lady Mariko is struggling to free herself." CR>)
(<QUEUED? I-NINJA>
<TELL
"Lady Mariko looks like the samurai she is, brave and fearless, intent upon
her purpose." CR>)
(ELSE
<TELL
"Lady Mariko looks tired, but delicate and beautiful. The effects of the
afternoon are still with her, but she is content to be here with you." CR>)>>
<ROUTINE NINJA-TAKE-MARIKO ()
<COND (<FSET? ,MARIKO ,RMUNGBIT>
<COND (<FSET? ,BLACKTHORNE ,RMUNGBIT>
<TELL
"You're too far away. You'll have to get closer somehow." CR>)
(ELSE
<MOVE ,MARIKO ,WINNER>
<TELL
"You take her in your arms, her broken body so small it feels like
she can hardly be real." CR>)>)
(<IN? ,MARIKO ,SECRET-REDOUBT>
<MOVE ,MARIKO ,WINNER>
<QUEUE I-MARIKO-STRUGGLES -1>
<TELL
"You grab her, dragging her toward the balcony, but she tries to get
away. \"No, Anjin-san! I must stay here!\"" CR>)
(ELSE
<SETG WINNER ,MARIKO>
<PERFORM ,V?FOLLOW>
<SETG WINNER ,PLAYER>
<RTRUE>)>>
<ROOM PRIVATE-QUARTERS
(LOC ROOMS)
(SCENE S-NINJA)
(DESC "Mariko's Quarters")
(OWNER MARIKO)
(SYNONYM QUARTERS)
(SCORE 6)
(FDESC
"It is early in the morning of the day after Mariko's confrontation, two
or three hours before dawn. After she woke, you and Mariko had an hour
alone together. \"I still cannot believe that Ishido gave in,\" she
said. \"I knew it was my karma to bring the hostages out of Osaka. Only I could
do that for Lord Toranaga. And now it's done. But at what a cost,
neh? Madonna forgive me.\"|
|
Now you, Mariko, Kiri, Lady Etsu, and Achiko, the granddaughter of Kiyama, are
together in Mariko's quarters. You are still suspicious enough of Ishido's
intentions to be carrying your pistol.")
(AFTER ETSU-AFTER-F)
(NORTH TO SECRET-REDOUBT IF SECRET-REDOUBT-DOOR IS OPEN)
(IN TO SECRET-REDOUBT IF SECRET-REDOUBT-DOOR IS OPEN)
(SOUTH TO OUTER-ROOM IF NORTH-SHOJI IS OPEN)
(OUT TO OUTER-ROOM IF NORTH-SHOJI IS OPEN)
(WEST TO PRIVATE-QUARTERS-2)
(EAST TO BLACKTHORNE-QUARTERS)
(GLOBAL NORTH-SHOJI SECRET-REDOUBT-DOOR LG-NINJA LG-WOMEN)
(FLAGS ONBIT NOTHEBIT NOABIT)
(ACTION PRIVATE-QUARTERS-F)>
<ROUTINE PRIVATE-QUARTERS-F (RARG)
<COND (<RARG? SCENE-SETUP>
<DRESS-BLACKTHORNE>
<PUTP ,OUTER-CORRIDOR ,P?FDESC <>>
<FCLEAR ,OUTER-CORRIDOR ,TOUCHBIT>
<FCLEAR ,AUDIENCE-CHAMBER ,TOUCHBIT>
<MOVE ,SWORDS ,BLACKTHORNE-QUARTERS>
<MOVE ,PISTOL ,BLACKTHORNE>
<MOVE ,MARIKO ,HERE>
<FSET ,MARIKO ,SCOREBIT>
<MOVE ,KIRITSUBO ,HERE>
<MOVE ,GUARDS ,AUDIENCE-CHAMBER>
<MOVE ,GRAY-CAPTAIN ,AUDIENCE-CHAMBER>
<MOVE ,YABU ,OUTER-ROOM>
<QUEUE I-CHIMMOKO 1>)
(<RARG? LOOK>
<TELL
"These are Lady Mariko's private quarters. Shojis screen a private room to
the west, your room to the east, and an outer room which leads to a
corridor on the south.">
<COND (<NOT <FSET? ,SECRET-REDOUBT-DOOR ,INVISIBLE>>
<TELL
"On the north wall is the iron-bound door to Lord Toranaga's secret
room.">)>
<CRLF>)
(<RARG? BEG>
<COND (<AND <VERB? WALK>
<IN? ,NINJA ,HERE>
,KNOCKOUT-CNT>
<TELL
G"You can't break through the encircling ninja!" CR>)
(<AND <P? WALK (P?SOUTH P?OUT)>
<IN? ,NINJA ,HERE>>
<TELL
G"You would have to walk right through the ninja!" CR>)
(<VERB? LEAVE>
<DO-WALK <COND (<FSET? ,SECRET-REDOUBT-DOOR ,OPENBIT>
,P?NORTH)
(ELSE ,P?WEST)>>)>)
(<RARG? END>
<COND (<AND <NOT ,MARIKO-PLAN?>
<FSET? ,OUTER-ROOM ,TOUCHBIT>
<FSET? ,YABU ,TOUCHBIT>
<IN? ,MARIKO ,HERE>
<IN? ,KIRITSUBO ,HERE>
<FSET? ,LG-NINJA ,INVISIBLE>>
<THIS-IS-IT ,YABU>
<SETG QCONTEXT ,MARIKO>
<SETG MARIKO-PLAN? T>
<TELL CR
"Kiri asks you a question which you don't understand. Mariko translates for
her. \"Did you ask Yabu about the 'plan'?\"" CR>)
(<AND ,NINJA-ATTACKING-CUL-DE-SAC?
<FSET? ,SECRET-REDOUBT-DOOR ,INVISIBLE>
<IN? ,BLACKTHORNE ,PRIVATE-QUARTERS>
<IN? ,KIRITSUBO ,PRIVATE-QUARTERS>>
<FCLEAR ,SECRET-REDOUBT-DOOR ,INVISIBLE>
<TELL CR
"Kiri pulls a section of shoji on the north wall aside, revealing a hidden
iron-fortified door set into the stone wall beyond. The hinges are
well oiled. \"This is my Master's secret haven,\" she pants." CR>)>)>>
<GLOBAL MARIKO-PLAN? <>>
<OBJECT PLAN
(LOC GENERIC-OBJECTS)
(DESC "plan")
(SYNONYM PLAN)
(ADJECTIVE SECRET)
(FLAGS SCOREBIT)>
<OBJECT CHIMMOKO
(LOC OUTER-ROOM)
(OWNER MARIKO)
(DESC "Chimmoko")
(SYNONYM CHIMMOKO MAID)
(FLAGS PERSON JAPANESEBIT FEMALE NOABIT NOTHEBIT)
(ACTION CHIMMOKO-F)>
<ROUTINE CHIMMOKO-F ("OPT" (RARG <>))
<COND (<RARG? WINNER>
<COND (<P? FIND ;WHERE (YABU LG-YABU)>
<COND (<IN? ,YABU ,OUTER-ROOM>
<TELL
"\"He is in the outer chamber, Anjin-san.\"" CR>)
(ELSE
<TELL
"\"I don't know, Anjin-san. He was very angry.\"" CR>)>)
(ELSE
<WAKARIMASEN>)>)
(<P? ASK-ABOUT CHIMMOKO>
<COND (<SCENE? ,S-SEPPUKU>
<TELL
"\"Please go to my mistress, Anjin-san. This is no time for questions.\"" CR>)
(ELSE
<TELL
"She has nothing to say about " THE ,PRSI "." CR>)>)
(<VERB? WHO>
<TELL "Chimmoko is one of Mariko's maids." CR>)>>
<ROUTINE I-CHIMMOKO ()
<COND (<IN? ,YABU ,OUTER-ROOM>
<COND (<HERE? ,PRIVATE-QUARTERS ,PRIVATE-QUARTERS-2
,BLACKTHORNE-QUARTERS>
<SETG YABU-CNT 0>
<QUEUE I-YABU -1>
<QUEUE I-YABU-LEAVES 4>
<MOVE ,CHIMMOKO ,HERE>
<TELL CR
"Chimmoko, Mariko's servant, enters and bows. \"Lord Yabu wishes to
speak with the Anjin-san,\" she says.">
<COND (<NOT <HERE? <LOC ,YABU>>>
<TELL "\"He is waiting in the outer room.\"">)>
<CRLF>)
(ELSE
<QUEUE I-CHIMMOKO 1>)>)>>
<OBJECT ETSU
(LOC PRIVATE-QUARTERS-2)
(DESC "Lady Etsu")
(SYNONYM LADY ETSU)
(ADJECTIVE LADY OLD)
(FLAGS PERSON JAPANESEBIT FEMALE NOABIT NOTHEBIT)
(ACTION ETSU-F)>
<ROUTINE ETSU-F ("OPT" (RARG <>))
<COND (<RARG? SUBJ>
<RFALSE>)
(<RARG? WINNER>
<COND (<VERB? STOP>
<SETG WINNER ,PLAYER>
<PERFORM ,V?HELP ,ETSU>
<RTRUE>)
(ELSE
<WAKARIMASEN>)>)
(<VERB? WHO>
<TELL "Lady Maeda Etsu is Lord Maeda's mother, an elderly
samurai of very high lineage." CR>)
(<VERB? EXAMINE>
<TELL
"She is an elderly samurai and customarily leans painfully on her cane;
\"It's my joints, they get worse every day.\" Her hair is white but her
back is straight." CR>)>>
<OBJECT ACHIKO
(LOC PRIVATE-QUARTERS)
(DESC "Achiko")
(SYNONYM ACHIKO GIRL)
(ADJECTIVE LADY YOUNG KIYAMA)
(FLAGS PERSON JAPANESEBIT FEMALE NOABIT NOTHEBIT)
(ACTION ACHIKO-F)>
<ROUTINE ACHIKO-F ("OPT" (RARG <>))
<COND (<RARG? WINNER>
<WAKARIMASEN>)
(<RARG? SUBJ>
<RFALSE>)
(<VERB? WHO>
<TELL
"Kiyama Achiko is the granddaughter-in-law of Lord Kiyama." CR>)
(<VERB? EXAMINE>
<COND (<FSET? ,PRSO ,DEAD>
<TELL
"Achiko's lifeless body is spawled on the floor." CR>)
(ELSE
<TELL
"She appears to be holding up well." CR>)>)>>
<ROUTINE I-WOMEN ("AUX" (NINJA? <NOT <IN? ,NINJA ,SECRET-ROOM>>))
<COND (<IN? ,ETSU ,BLACKTHORNE-QUARTERS>
<CHOREOGRAPH ,PRIVATE-QUARTERS T>)
(<IN? ,ETSU ,PRIVATE-QUARTERS-2>
<CHOREOGRAPH ,PRIVATE-QUARTERS T>)
(<IN? ,ETSU ,SECRET-REDOUBT>
<COND (<AND .NINJA? <FSET? ,BALCONY-DOOR ,OPENBIT>>
<CHOREOGRAPH ,BALCONY>)>)
(<IN? ,ETSU ,PRIVATE-QUARTERS>
<COND (.NINJA?
<COND (<FSET? ,SECRET-REDOUBT-DOOR ,OPENBIT>
<CHOREOGRAPH ,SECRET-REDOUBT>)
(ELSE <RFALSE>)>)
(ELSE
<FSET ,NORTH-SHOJI ,OPENBIT>
<CHOREOGRAPH ,OUTER-ROOM T>)>)
(<IN? ,ETSU ,OUTER-ROOM>
<COND (.NINJA?
<FSET ,NORTH-SHOJI ,OPENBIT>
<CHOREOGRAPH ,PRIVATE-QUARTERS>)
(ELSE
<FSET ,SOUTH-SHOJI ,OPENBIT>
<CHOREOGRAPH ,INNER-CORRIDOR T>)>)
(<IN? ,ETSU ,INNER-CORRIDOR>
<COND (.NINJA?
<FSET ,SOUTH-SHOJI ,OPENBIT>
<CHOREOGRAPH ,OUTER-ROOM>)
(<FSET? ,INNER-DOOR ,OPENBIT>
<CHOREOGRAPH ,AUDIENCE-CHAMBER T>)
(<HERE? ,INNER-CORRIDOR>
<TELL CR
"The women stop inside the door, listening intently." CR>)>)
(<IN? ,ETSU ,AUDIENCE-CHAMBER>
<COND (.NINJA?
<COND (<FSET? ,INNER-DOOR ,OPENBIT>
<COND (<QUEUED? I-NINJA-COWED>
<CHOREOGRAPH ,INNER-CORRIDOR>)>)
(<QUEUED? I-NINJA-TAKE-MARIKO>
<TELL CR
"The women huddle in fear against the closed door." CR>)
(ELSE
<TELL CR
"Mariko pounds on the closed door as the rest of the women huddle
around her in fear. \"Anjin-san! Open the door!\"" CR>)>)>)>>
<ROUTINE CHOREOGRAPH (RM "OPT" (MARIKO? <>)
"AUX" (NINJA? <>) (ORM <LOC ,ETSU>))
<COND (<NOT <IN? ,NINJA ,SECRET-ROOM>>
<SET NINJA? T>)>
<COND (<OR <QUEUED? I-NINJA-TAKE-MARIKO>
<QUEUED? I-MARIKO-FOLLOW>>
<SET MARIKO? <>>)>
<MOVE ,CHIMMOKO .RM>
<MOVE ,ACHIKO .RM>
<MOVE ,ETSU .RM>
<MOVE ,KIRITSUBO .RM>
<COND (.MARIKO? <MOVE ,MARIKO .RM>)>
<COND (<EQUAL? .ORM ,HERE>
<CRLF>
<COND (.MARIKO? <TELL
"Mariko and the other">)
(ELSE <TELL
"The">)>
<TELL " women">
<COND (.NINJA?
<COND (<IN? ,MARIKO ,HERE>
<TELL ", save Mariko,">)>
<TELL " flee">)
(ELSE
<TELL
", treading a narrow path between fear and curiosity, leave">)>
<TELL " the room and crowd into " THE .RM "." CR>)
(<EQUAL? .RM ,HERE>
<CRLF>
<COND (.NINJA?
<COND (.MARIKO?
<TELL
"Mariko and the rest of the">)
(ELSE
<TELL
"The">)>
<TELL
" women pour out of " THE .ORM ", fleeing the ninja." CR>)
(ELSE
<COND (.MARIKO?
<TELL "Mariko ">
<COND (,STATIONARY? <TELL "comes from ">)
(ELSE <TELL "follows you into ">)>
<TELL
THE .ORM " into the room. The rest of the women follow her,">)
(ELSE
<TELL "The women ">
<COND (,STATIONARY? <TELL "come">)
(ELSE <TELL "follow you">)>
<TELL " into the room,">)>
<TELL
" curious about the commotion, but huddled together in some fear." CR>)>)
(<NEXT-ROOM? .RM T>
<TELL CR
"The women">
<COND (.NINJA?
<TELL ", fleeing the ninja, pour">)
(ELSE
<TELL " come">)>
<TELL " into " THE .RM "." CR>)>>
<ROUTINE I-MARIKO-FOLLOW ()
<COND (<NOT <IN? ,MARIKO ,HERE>>
<COND (,CAPTURE-CNT
<COND (<NEXT-ROOM? <LOC ,MARIKO>>
<TELL CR
"In the next room, you can hear Mariko struggling vainly to break free
of the encircling ninja. \"Anjin-san!\" she calls." CR>)
(ELSE
<TELL CR
"You can dimly hear Mariko calling for help." CR>)>)
(ELSE
<MOVE ,MARIKO ,HERE>
<COND (<HERE? ,SECRET-REDOUBT>
<DEQUEUE I-MARIKO-FOLLOW>)>
<TELL CR
"Mariko follows ">
<COND (<OR <SCENE? ,S-NINJA ,S-ESCAPE>
<PROB 50>>
<TELL
"quickly after you." CR>)
(ELSE
<TELL
"a pace behind, as is the custom." CR>)>)>)>>
<ROOM PRIVATE-QUARTERS-2
(LOC ROOMS)
(SCENE S-NINJA)
(DESC "Private Quarters")
(ADJECTIVE PRIVATE)
(SYNONYM QUARTERS)
(LDESC
"This is a smaller room, part of Mariko's quarters. The Lady Etsu has
been staying here.")
(EAST TO PRIVATE-QUARTERS)
(FLAGS ONBIT)
(GLOBAL LG-NINJA LG-WOMEN)>
<ROOM BLACKTHORNE-QUARTERS
(LOC ROOMS)
(SCENE S-NINJA)
(DESC "Your Quarters")
(OWNER BLACKTHORNE)
(SYNONYM QUARTERS ROOM)
(ADJECTIVE SMALL)
(LDESC
"This is a small room in which you are quartered.")
(WEST TO PRIVATE-QUARTERS)
(OUT TO PRIVATE-QUARTERS)
(FLAGS ONBIT)
(GLOBAL LG-NINJA LG-WOMEN)>
<ROOM SECRET-REDOUBT
(LOC ROOMS)
(SCENE S-NINJA)
(DESC "Secret Redoubt")
(SYNONYM REDOUBT BOLTHOLE HOLE HAVEN)
(ADJECTIVE SECRET BOLT)
(SOUTH TO PRIVATE-QUARTERS IF SECRET-REDOUBT-DOOR IS OPEN)
(NORTH TO BALCONY IF BALCONY-DOOR IS OPEN)
(OUT TO BALCONY IF BALCONY-DOOR IS OPEN)
(GLOBAL SECRET-REDOUBT-DOOR BALCONY-DOOR LG-NINJA LG-WOMEN)
(FLAGS ONBIT)
(ACTION SECRET-REDOUBT-F)>
<ROUTINE SECRET-REDOUBT-F (RARG "AUX" (CNT <GETP ,BOLTS ,P?COUNT>))
<COND (<RARG? LOOK>
<TELL
"This is Lord Toranaga's secret bolt hole. ">
<COND (<IN? ,SECRET-REDOUBT-DOOR ,LOCAL-GLOBALS>
<TELL "An iron-bound
door, well-oiled and well-maintained, is on the south wall. There
are three iron bolts on the door, ">
<BOLT-STATE .CNT>
<TELL ". ">)
(ELSE
<TELL
"There is an explosion-scarred hole on the south wall. ">)>
<TELL "On the
north wall is the door to the balcony, its bolts rusty and not so
well-maintained." CR>)
(<RARG? BEG>
<COND (<AND <VERB? WALK>
<IN? ,NINJA ,HERE>
,KNOCKOUT-CNT>
<TELL
G"You can't break through the encircling ninja!" CR>)
(<AND <P? WALK P?SOUTH>
<IN? ,NINJA ,HERE>>
<TELL
G"You would have to walk right through the ninja!" CR>)>)>>
<ROUTINE BOLT-STATE (CNT)
<COND (<ZERO? .CNT>
<TELL "and they are all shut">)
(<EQUAL? .CNT 1 2 4>
<TELL "but one of them is open">)
(<EQUAL? .CNT 3 5 6>
<TELL "but two are currently open">)
(ELSE
<TELL "but none of them are latched now">)>>
<ROUTINE BOLTS-REMAINING (CNT)
<TELL "">
<COND (<EQUAL? .CNT 7>
<TELL "All the bolts are now open." CR>)
(<EQUAL? .CNT 3 5 6>
<TELL "Two bolts are open." CR>)
(<EQUAL? .CNT 1 2 4>
<TELL "One bolt is open." CR>)
(<ZERO? .CNT>
<TELL "All the bolts are now closed." CR>)>>
<OBJECT BOLTS
(LOC SECRET-REDOUBT)
(DESC "bolt")
(SYNONYM BOLT BOLTS)
(ADJECTIVE IRON FIRST SECOND THIRD)
(FLAGS NDESCBIT OPENBIT OPENABLE)
(COUNT 7) ;"bit on means bolt open"
(ACTION BOLTS-F)>
<ROUTINE BOLTS-F ("AUX" (CNT <GETP ,BOLTS ,P?COUNT>))
<COND (<VERB? EXAMINE>
<TELL
"There are three iron bolts to hold the door securely closed, ">
<BOLT-STATE .CNT>
<TELL "." CR>)
(<VERB? OPEN UNLOCK>
<COND (<ADJ-USED? ,PRSO ,W?FIRST>
<COND (<ZERO? <BAND .CNT 1>>
<SET CNT <BOR .CNT 1>>
<TELL G"You open the first bolt.">)
(ELSE
<TELL "The first bolt is already open.">)>)
(<ADJ-USED? ,PRSO ,W?SECOND>
<COND (<ZERO? <BAND .CNT 2>>
<SET CNT <BOR .CNT 2>>
<TELL G"You open the second bolt.">)
(ELSE
<TELL "The second bolt is already open.">)>)
(<ADJ-USED? ,PRSO ,W?THIRD>
<COND (<ZERO? <BAND .CNT 4>>
<SET CNT <BOR .CNT 4>>
<TELL G"You open the third bolt.">)
(ELSE
<TELL "The third bolt is already open.">)>)
(ELSE
<COND (<ZERO? <BAND .CNT 1>>
<SET CNT <BOR .CNT 1>>
<TELL G"You open the first bolt.">)
(<ZERO? <BAND .CNT 2>>
<SET CNT <BOR .CNT 2>>
<TELL G"You open the second bolt.">)
(<ZERO? <BAND .CNT 4>>
<SET CNT <BOR .CNT 4>>
<TELL G"You open the third bolt.">)
(ELSE
<TELL "All the bolts are open already." CR>
<RTRUE>)>)>
<COND (<NOT <ZERO? .CNT>>
<FCLEAR ,SECRET-REDOUBT-DOOR ,LOCKED>)>
<PUTP ,BOLTS ,P?COUNT .CNT>
<BOLTS-REMAINING .CNT>
<RTRUE>)
(<VERB? CLOSE LOCK>
<COND (<FSET? ,SECRET-REDOUBT-DOOR ,OPENBIT>
<TELL
"The door isn't closed, so there's no point in locking the bolts!" CR>)
(<ADJ-USED? ,PRSO ,W?FIRST>
<COND (<NOT <ZERO? <BAND .CNT 1>>>
<SET CNT <BAND .CNT 6>>
<TELL G"You close the first bolt.">)
(ELSE
<TELL "The first bolt is already closed.">)>)
(<ADJ-USED? ,PRSO ,W?SECOND>
<COND (<NOT <ZERO? <BAND .CNT 2>>>
<SET CNT <BAND .CNT 5>>
<TELL G"You close the second bolt.">)
(ELSE
<TELL "The second bolt is already closed.">)>)
(<ADJ-USED? ,PRSO ,W?THIRD>
<COND (<NOT <ZERO? <BAND .CNT 4>>>
<SET CNT <BAND .CNT 3>>
<TELL G"You close the third bolt.">)
(ELSE
<TELL "The third bolt is already closed.">)>)
(ELSE
<COND (<NOT <ZERO? <BAND .CNT 1>>>
<SET CNT <BAND .CNT 6>>
<TELL G"You close the first bolt.">)
(<NOT <ZERO? <BAND .CNT 2>>>
<SET CNT <BAND .CNT 5>>
<TELL G"You close the second bolt.">)
(<NOT <ZERO? <BAND .CNT 4>>>
<SET CNT <BAND .CNT 3>>
<TELL G"You close the third bolt.">)
(ELSE
<TELL "All the bolts are closed already." CR>
<RTRUE>)>)>
<COND (<ZERO? .CNT>
<FSET ,SECRET-REDOUBT-DOOR ,LOCKED>)>
<PUTP ,BOLTS ,P?COUNT .CNT>
<BOLTS-REMAINING .CNT>
<RTRUE>)>>
<OBJECT SECRET-REDOUBT-DOOR
(LOC LOCAL-GLOBALS)
(DESC "secret door")
(LDESC "The iron-bound door lies shattered in a corner.")
(SYNONYM DOOR)
(ADJECTIVE SECRET HIDDEN IRON-FORTIFIED IRON)
(FLAGS INVISIBLE DOORBIT LOCKABLE)
(ACTION SECRET-REDOUBT-DOOR-F)>
<ROUTINE SECRET-REDOUBT-DOOR-F ("AUX" (CNT <GETP ,BOLTS ,P?COUNT>))
<COND (<VERB? EXAMINE>
<TELL
"This is a heavy, iron-bound door. It looks very strong.">
<COND (<FSET? ,PRSO ,OPENBIT>
<TELL
"The door is open now.">)>
<COND (<HERE? ,SECRET-REDOUBT>
<TELL
"There are three iron bolts to secure the door, ">
<BOLT-STATE .CNT>
<TELL "." CR>)>
<CRLF>)
(<VERB? OPEN>
<COND (<EQUAL? .CNT 7> <RFALSE>)
(ELSE <TELL "The door is still bolted." CR>)>)
(<VERB? LOCK>
<COND (<HERE? PRIVATE-QUARTERS>
<TELL "The door doesn't lock from this side." CR>)
(ELSE
<PERFORM ,V?CLOSE ,BOLTS>
<RTRUE>)>)
(<VERB? UNLOCK>
<COND (<HERE? PRIVATE-QUARTERS>
<TELL "The door doesn't unlock from this side." CR>)
(ELSE
<PERFORM ,V?OPEN ,BOLTS>
<RTRUE>)>)>>
<OBJECT BALCONY-DOOR
(LOC LOCAL-GLOBALS)
(DESC "balcony door")
(SYNONYM DOOR)
(ADJECTIVE BALCONY)
(FLAGS DOORBIT LOCKABLE TRYTAKEBIT)
(ACTION BALCONY-DOOR-F)>
<ROUTINE BALCONY-DOOR-F ()
<COND (<VERB? EXAMINE>
<TELL
"This strong, iron-bound door has rarely been used. The catches
are rusty and the door itself is covered with cobwebs. Unfortunately,
it appears to be the only other exit from the room." CR>)
(<VERB? OPEN>
<COND (<OR <NOT <FSET? ,TOP-CATCH ,OPENBIT>>
<NOT <FSET? ,BOTTOM-CATCH ,OPENBIT>>>
<TELL
"The door won't open. The rusty ">
<COND (<FSET? ,TOP-CATCH ,OPENBIT>
<TELL
"bottom catch holds">)
(<FSET? ,BOTTOM-CATCH ,OPENBIT>
<TELL
"top catch holds">)
(ELSE
<TELL
"top and bottom catches hold">)>
<TELL " it securely closed." CR>)
(<AND <HERE? ,SECRET-REDOUBT>
<OR <QUEUED? I-NINJA-VS-SECRET-DOOR>
<QUEUED? I-NINJA-TAKE-MARIKO>>>
<FSET ,PRSO ,OPENBIT>
<TELL
"You throw the door open. Sweet night air rushes in">
<COND (<IN? ,ETSU ,SECRET-REDOUBT>
<MOVE ,ETSU ,BALCONY>
<MOVE ,ACHIKO ,BALCONY>
<MOVE ,CHIMMOKO ,BALCONY>
<MOVE ,KIRITSUBO ,BALCONY>
<TELL
", and the women
pour onto the veranda. Old Lady Etsu stumbles and you help her
through, then turn to help Mariko." CR>)
(ELSE <TELL "." CR>)>)>)
(<VERB? LOCK UNLOCK>
<TELL "There's no lock, only a top and bottom catch." CR>)
(<HOSTILE-VERB?>
<COND (<NOT <FSET? ,TOP-CATCH ,OPENBIT>>
<REDIRECT ,BALCONY-DOOR ,TOP-CATCH>)
(<NOT <FSET? ,TOP-CATCH ,OPENBIT>>
<REDIRECT ,BALCONY-DOOR ,BOTTOM-CATCH>)
(ELSE
<PERFORM ,V?OPEN ,BALCONY-DOOR>)>
<RTRUE>)>>
<NEW-ADD-WORD "CATCHES" NOUN <VOC "CATCH"> ,PLURAL-FLAG>
<OBJECT TOP-CATCH
(LOC SECRET-REDOUBT)
(DESC "top catch")
(SYNONYM CATCH ;CATCHES)
(ADJECTIVE UPPER TOP RUSTY IRON)
(FLAGS NDESCBIT OPENABLE LOCKED)
(ACTION CATCH-F)>
<OBJECT BOTTOM-CATCH
(LOC SECRET-REDOUBT)
(DESC "bottom catch")
(SYNONYM CATCH ;CATCHES)
(ADJECTIVE LOWER BOTTOM RUSTY IRON)
(FLAGS NDESCBIT OPENABLE LOCKED)
(ACTION CATCH-F)>
<ROUTINE CATCH-F ()
<COND (<VERB? EXAMINE>
<COND (<FSET? ,PRSO ,OPENBIT>
<TELL CTHE ,PRSO " is open." CR>)
(<NOT <FSET? ,PRSO ,LOCKED>>
<TELL CTHE ,PRSO " is closed." CR>)
(<FSET? ,PRSO ,RMUNGBIT>
<TELL "It looks a little looser than before." CR>)
(ELSE
<TELL
"This rusty iron catch hasn't been used in years, but it still looks
strong." CR>)>)
(<VERB? OPEN>
<COND (<FSET? ,PRSO ,LOCKED>
<TELL
"The catches are very rusty and won't open." CR>)>)
(<AND <VERB? SHOOT>
<NOT <FSET? ,PISTOL ,RMUNGBIT>>>
<FSET ,PISTOL ,RMUNGBIT>
<TELL
"The pistol goes off, but it doesn't appear to have
done anything to " THE ,PRSI "." CR>)
(<AND <HOSTILE-VERB?>
<NOT <FSET? ,PRSO ,OPENBIT>>>
<COND (<NOT <FSET? ,PRSO ,RMUNGBIT>>
<FSET ,PRSO ,RMUNGBIT>
<TELL
"You pound on " THE ,PRSO " with all your might, small flakes of rust
falling like snow, but it only gives a little." CR>)
(ELSE
<FSET ,PRSO ,OPENBIT>
<FCLEAR ,PRSO ,LOCKED>
<TELL
"You smash again and again, and finally " THE ,PRSO " clatters open." CR>)>)
(<AND <VERB? CLOSE>
<FSET? ,PRSO ,OPENBIT>>
<FCLEAR ,PRSO ,OPENBIT>
<TELL
"The catch slides closed with a rusty squeal">
<COND (<FSET? ,BALCONY-DOOR ,OPENBIT>
<TELL
", but " THE ,BALCONY-DOOR " is still open">)>
<TELL "." CR>)>>
<ROOM BALCONY
(LOC ROOMS)
(DESC "Balcony")
(SYNONYM BALCONY)
(LDESC
"This is a small balcony surrounded by a low battlement. The night air
is cool and sweet here after the smoke and confusion inside. The only
exit is back into the redoubt. This is as far as you can retreat.")
(IN TO SECRET-REDOUBT IF BALCONY-DOOR IS OPEN)
(SOUTH TO SECRET-REDOUBT IF BALCONY-DOOR IS OPEN)
(FLAGS ONBIT OUTSIDE)
(GLOBAL BALCONY-DOOR LG-NINJA LG-WOMEN)
(ACTION BALCONY-F)>
<ROUTINE BALCONY-F ("OPT" (RARG <>))
<COND (<RARG? BEG>
<COND (<AND <VERB? WALK>
<IN? ,NINJA ,HERE>
,KNOCKOUT-CNT>
<TELL
G"You can't break through the encircling ninja!" CR>)
(<AND <P? WALK (P?SOUTH P?IN)>
<IN? ,NINJA ,HERE>>
<TELL
G"You would have to walk right through the ninja!" CR>)
(<P? (LEAP DIVE) (BALCONY GLOBAL-HERE)>
<COND (<JIGS-UP? ,J-PLUNGE>
<JIGS-UP "You plunge to your death.">)
(ELSE <RTRUE>)>)>)>>
<OBJECT NORTH-SHOJI
(LOC LOCAL-GLOBALS)
(DESC "inner shoji")
(SYNONYM SHOJI DOOR)
(ADJECTIVE INNER)
(FLAGS DOORBIT)>
<OBJECT SOUTH-SHOJI
(LOC LOCAL-GLOBALS)