"GOAL for DEADLINE Copyright 1982 Infocom, Inc. All rights reserved. " "This code is the local T system. There are four transit lines: TOP-OF-THE-LINE, BOTTOM-LINE, FOOD-LINE, and OUTSIDE-LINE, corresponding to upstairs, downstairs, kitchen area, and outside. There are routes for each of these lines and transfer points. Much of this is done for the general case, except transfers. Sigh." > > > > > "Rapid Transit Line Identifiers" >> > > >)>> ) "AUX" (HERE ) HL GL GT) #DECL ((PERSON GOAL HERE) OBJECT (HL GL) FIX (PRIORITY) ) >> )> > >> >) (<==? .HL ,TOP-OF-THE-LINE-C> ) (<==? .HL ,OUTSIDE-LINE-C> ) (<==? .HL ,FOOD-LINE-C> ) (<==? .GL ,TOP-OF-THE-LINE-C> ) (<==? .GL ,FOOD-LINE-C> ) (T )> ;CHOMP> > ) LINE LN RM GT GOAL FLG (GOAL-FLAG <>) (IGOAL <>) LOC (CNT 1) DIR) #DECL ((PERSON HERE LOC RM) OBJECT (LN CNT) FIX (GOAL-FLAG IGOAL) ) >> > > > ) (> )> ;CHOMP> .HERE>> >)> > ) (T >)> ) (<==? .HERE ,STAIRS> >>) (<==? .HERE .GOAL> >>) (>> >> > ) (T >)> ) (T > >)>)> > ,TOP-OF-THE-LINE) (<==? .LN ,BOTTOM-LINE-C> ,BOTTOM-LINE) (<==? .LN ,FOOD-LINE-C> ,FOOD-LINE) (T ,OUTSIDE-LINE)>> > .HERE> >>) (T >>)> >) (<==? .RM .GOAL> )> >>> > ,GOAL-FUNCTION> ,G-REACHED>> ) EX) #DECL ((PERSON WHERE) OBJECT) >>> > > >> ,DEXIT> > ,OPENBIT>> ) (T >)>) (T >)> ) ( ) ( ) ( )> ) (T )> )>) (<==? .WHERE ,HERE> >> ) (<==? ,OUTSIDE-LINE-C> ) (T )>) (> > 0>>> ) (> > )> ,OUTSIDE-LINE-C> ) (<==? .WHERE ,SHED-ROOM> ) (T )> > ) (<0? >> > > ) (<==? .PCOR ,P?DOWN> ) (T )> ) (T > > )>) (> 0>>> > ,OUTSIDE-LINE-C> <==? .WHERE ,STAIRS>> ) (T )> > )>)> > ) (T > .PERSON> T) ( .FLG> .OL>> .NC ,PRESENT-TIME>)> >)>> .FLG> >> ) ( T) (> > > <==? .THERE>> )>)>>> >>> > .HERE> ) (<==? .RM .THERE> )> >> > ,COR-1) (<==? .NUM 2> ,COR-2) (<==? .NUM 4> ,COR-4) (<==? .NUM 8> ,COR-8) (<==? .NUM 16> ,COR-16) (<==? .NUM 32> ,COR-32) (<==? .NUM 64> ,COR-64) (<==? .NUM 128> ,COR-128) (<==? .NUM 256> ,COR-256) (<==? .NUM 512> ,COR-512) (<==? .NUM 1024> ,COR-1024) (T ,COR-2048)>> )) #DECL ((PERSON IGOAL FGOAL) OBJECT) > )> .FLG>) (<==? .IGOAL ,STAIR-BOTTOM> > )> .FLG>) (T 0> ) (T )>) (<==? .IGOAL ,FRONT-PATH> ) (<==? .IGOAL ,FOYER> ) (<==? .IGOAL ,NFOYER> ) (T )>> .V)>> .DIR> > )> >> )> >>> "Here is the code for goal motivation for the various characters. Each character has a tendency to move from one place to another at certain times. They all converge on the living room at about noon." "Constants used as table offsets for each character, including the player." > "Goal tables for the 8 characters (including PLAYER), offset by the preceding constants, which, for a given character, is the P?CHARACTER property of the object." <> <> <> 1 <> <> I-FOLLOW 4 4> <> <> <> 1 <> <> I-GARDENER 3 3>
<> <> <> 1 <> <> I-BAXTER 4 4>
<> <> <> 1 <> <> I-DUNBAR 3 3>
<> <> <> 1 <> <> I-GEORGE 2 2>
<> <> <> 1 <> <> I-MRS-ROBNER 4 4>
<> <> <> 1 <> <> I-ROURKE 6 6>
<> <> <> 1 <> <> I-COATES 2 2>>> > "Offsets into GOAL-TABLEs" "Goal-function constants, similar to M-xxx in MAIN" "Here's how the movement goals are done: For each player is a table which consists of triplets, a number of minutes until the next movement (an clock interrupt number), a number of minutes allowed variation (for a bit of randomness), and a room toward which to start. All movement is controlled by the GOAL-ENABLE flag in the GOAL-TABLE for a character." "Time starts at 8AM. Characters are at that point in their starting positions, as reflected in DUNGEON." > > ;"GARDENER"
;"BAXTER"
;"DUNBAR"
;"GEORGE"
;"MRS-ROBNER"
;"ROURKE"
>> > > > > > > > >> > )>> ) "AUX" (GL )) ) (<==? .GARG ,G-REACHED> >>> ) (<==? .GL ,ORCHARD> > > > ) ( ) (<==? ,HERE ,ORCHARD> )> )>) (<==? .GL ,IN-ROSES> ) (T > )>)>)>> ) "AUX" (BL )) ) ( <==? .BL ,LIVING-ROOM>> )>) ( <==? .BL ,DUNBAR-ROOM> <==? ,HERE ,DUNBAR-ROOM>> >) ( <==? .BL ,SHED-ROOM>> )>) ( <==? .BL ,SOUTH-LAWN>> ) ( )> )>> ) "AUX" (DL )) ) ( <==? .DL ,SHED-ROOM>> )>)>> ) "AUX" (GL )) <==? .GL ,EAST-LAWN>> ) ( <==? .GL ,GEORGE-ROOM>> > > )>) ( <==? .GL ,NORTH-LAWN>> )>) ( )>> )) > ) ( )>> ) "AUX" (ML )) <==? .ML ,MASTER-BEDROOM>> >
>> )) > > )>) ( )> > )>)>>