the-infocom-files / amfv

A Mind Forever Voyaging
5 stars 2 forks source link

"ENTER RECTORY" doesn't work (and "EXIT RECTORY" enters it) #22

Open eriktorbjorn opened 4 years ago

eriktorbjorn commented 4 years ago
>LOOK
Church Entrance
You are on Church Street, just east of a large, opulent church displaying the
architecture of the twentieth century. The street continues north and south.
Another church building, probably a rectory, lies to the northwest, and an
ordinary high-rise apartment is southwest of here. The main entrance to Midland
Cemetery is east of here.

>ENTER RECTORY
You hit your head against the rectory as you attempt this feat.

>EXIT RECTORY
Rectory
This is part of the St. Michael's complex. You can leave to either the northeast
or southeast.

The game has several objects that represent buildings, so that you can enter or exit them. They tend to look like this:

<ROUTINE COURTHOUSE-OBJECT-F ()
     <COND (<VERB? THROUGH WALK-TO>
        <COND (<EQUAL? ,HERE ,COURTHOUSE>
               <TELL ,LOOK-AROUND CR>)
              (<GLOBAL-IN? ,PRSO ,HERE>
               <DO-WALK ,P?NW>)>)
           (<VERB? LEAVE DISEMBARK>
        <COND (<EQUAL? ,HERE ,COURTHOUSE>
               <DO-WALK ,P?SE>)
              (T
               <TELL ,LOOK-AROUND CR>)>)
           (<AND <VERB? EXAMINE>
             <EQUAL? ,HERE ,COURTHOUSE>>
        <V-LOOK>)>>

So one case checks THROUGH or WALK-TO, while the other checks LEAVE or DISEMBARK. However, in RECTORY-OBJECT-F the first case mistakenly checks DISEMBARK instead of THROUGH:

<ROUTINE RECTORY-OBJECT-F ()
     <COND (<AND <EQUAL? ,SYEAR 2041 2071>
             <NOT <MOBY-VERB?>>>
        <CANT-SEE ,RECTORY-OBJECT>)
           (<VERB? WALK-TO DISEMBARK>
        <COND (<EQUAL? ,HERE ,CONSTRUCTION-SITE-5>
               <TELL ,LOOK-AROUND CR>)
              (<EQUAL? ,HERE ,CHURCH-ENTRANCE>
               <DO-WALK ,P?NW>)
              (<GLOBAL-IN? ,PRSO ,HERE>
               <DO-WALK ,P?SW>)>)
           (<VERB? LEAVE DISEMBARK>
        <COND (<EQUAL? ,HERE ,CONSTRUCTION-SITE-5>
               <V-WALK-AROUND>)
              (T
               <TELL ,LOOK-AROUND CR>)>)
           (<AND <VERB? EXAMINE>
             <EQUAL? ,HERE ,CONSTRUCTION-SITE-5>>
        <V-LOOK>)>>
eriktorbjorn commented 4 years ago

On a tangent, PARKVIEW-APARTMENTS-OBJECT-F also checks EXIT. That may or may not be a bug, but I can't find any harm in it.

eriktorbjorn commented 4 years ago

And SKYBUS-TERMINAL-OBJECT-F, CITY-HALL-OBJECT-F, MALL-OBJECT-F, CAMPUS-F and VACANT-LOT-F have no cases for examining them, though that's more of an inconsistency than a bug.

eriktorbjorn commented 4 years ago

GUN-SHOP-OBJECT-F has a mysterious MOBY-VERB? check that I can't see how it can ever not be true. But that's only relevant if we ever run out of space, which seems unlikely:

<ROUTINE GUN-SHOP-OBJECT-F ()
     <COND (<VERB? WALK-TO THROUGH>
        <COND (<EQUAL? ,HERE ,FACTORY-ENTRANCE>
               <DO-WALK ,P?NORTH>)
              (<NOT <MOBY-VERB?>>
               <TELL ,LOOK-AROUND CR>)>)