the-infocom-files / enchanter

Enchanter
8 stars 3 forks source link

JEWELLED-BOX-A never prints any messages #47

Open eriktorbjorn opened 5 years ago

eriktorbjorn commented 5 years ago

The adventurer is supposed to try - and fail - to pick up the jewelled box. It works in that he never picks it up, even though it is a treasure. But it never prints any messages like it's supposed to and that's because of one small bug:

<ROUTINE JEWELLED-BOX-A ()
     <COND (<AND <IN? ,HERE ,JEWELLED-BOX>
             <G? ,BOX-POINT 0>>
        <COND (,ROPE-MAGIC?
               <TELL
"The adventurer notes the box and tries to untie the rope from around it.
His frustration is evident by the words he uses to describe the rope." CR>)
              (T
               <PUTP ,JEWELLED-BOX ,P?LDESC
"A jewelled box, wrapped in a partly untied tangle of rope, is
on the ground.">
               <TELL
"The adventurer walks up to the box and becomes quickly entangled in the
partly untied rope that is knotted around it. He looks like a cat who has
been playing with a ball of yarn." CR>)>)>
     <RTRUE>>

It checks if HERE is inside the box, instead of the other way around. I.e. it's supposed to check <IN? ,JEWELLED-BOX ,HERE> instead.

Also, you probably won't see the new LDESC unless you've picked up the box and dropped it again (which you probably won't, because it's quite heavy), since it has an FDESC. Maybe casting KULCAD on the rope should set the box's TAKEBIT?

eriktorbjorn commented 5 years ago

The box's LDESC is also updated if you KULCAD the rope and try to untie it. Again, you won't see it until the box has TAKEBIT. See MAGIC-ROPE-F.