the-infocom-files / zork3

Zork III: The Dungeon Master
5 stars 3 forks source link

CHEST-LIFTED isn't set if you tie the rope to the chest after the man asks you to #56

Open eriktorbjorn opened 5 years ago

eriktorbjorn commented 5 years ago
>WAIT
Time passes...
At the edge of the cliff above you, a man appears. He looks down at you and
speaks. "Hello, down there! You seem to have a problem. Maybe I can help you."
He chuckles in an unsettling sort of way. "Perhaps if you tied that chest to the
end of the rope I might be able to drag it up for you. Then, I'll be more than
happy to help you up!" He laughs again.

>MAN, HELLO
He yells back, "What's that you say? I can't hear you very well. Just tie the
rope to the chest and we can chat afterwards!" He smiles broadly.

>TIE ROPE TO CHEST
The chest is now tied to the rope.
The man above you looks pleased. "Now there's a good friend! Thank you very
much, indeed!" He pulls on the rope and the chest is lifted to the top of the
cliff and out of sight. With a short laugh, he disappears. "I'll be back in a
short while!" are his last words.

>WAIT
Time passes...

>WAIT
Time passes...

>WAIT
Time passes...
A familiar voice calls down to you. "Are you still there?" he bellows with a
coarse laugh. "Well, then, grab onto the rope and we'll see what we can do." The
rope drops to within your reach.

>MAN, HELLO
He yells back, "What's that you say? I can't hear you very well. Just tie the
rope to the chest and we can chat afterwards!" He smiles broadly.

Interestingly, if you already tied the rope to the chest when he first appears, it works as intended:

>TIE ROPE TO CHEST
The chest is now tied to the rope.

>WAIT
All at once, the chest is lifted from you. Looking up, you see a man at the top
of the cliff, pulling intently at the rope. "That is uncommonly good of you, I
do say!" He chuckles unpleasantly. "Oh, you are stuck, aren't you. Well, I'll be
right back to get you!" He leaves your sight.

>WAIT
Time passes...

>WAIT
Time passes...

>WAIT
Time passes...

>WAIT
Time passes...
A familiar voice calls down to you. "Are you still there?" he bellows with a
coarse laugh. "Well, then, grab onto the rope and we'll see what we can do." The
rope drops to within your reach.

>MAN, HELLO
He yells back, "What's that you say? I can't hear you very well."

That's because GLOBAL-MAN-F checks the CHEST-LIFTED flag:

           (<HELLO? ,GLOBAL-MAN>
        <TELL
"He yells back, \"What's that you say? I can't hear you very well.">
        <COND (<NOT ,CHEST-LIFTED>
               <TELL
" Just tie the rope to the chest and we can chat afterwards!\" He smiles
broadly.">)
              (T <TELL "\"">)>
        <CRLF>)

It's set in I-MAN-APPERSwhen you've already tied the rope to the chest:

           (,CHEST-TIED
        <SETG MAN-SEEN T>
        <TELL
"All at once, the chest is lifted from you. Looking up, you see a
man at the top of the cliff, pulling intently at the rope. \"That is
uncommonly good of you, I do say!\" He chuckles unpleasantly. \"Oh,
you are stuck, aren't you. Well, I'll be right back to get you!\"
He leaves your sight." CR>
        <SETG CHEST-LIFTED T>
        <MOVE ,CHEST ,MAN>
        <FSET ,CHEST ,TOUCHBIT>
        <SETG ROPE-FLAG <>>
        <SETG CHEST-TIED <>>
        <ENABLE <QUEUE I-MAN-RETURNS 10>>
        <RTRUE>)

It's not set in GLOBAL-ROPE-F when you tie the rope to the chest afterwards:

           (<VERB? TIE>
        <COND (<EQUAL? ,CHEST ,PRSO ,PRSI>
               <TELL
"The chest is now tied to the rope." CR>
               <SETG CHEST-TIED T>
               <COND (<AND ,MAN-FLAG <NOT ,MAN-GONE>>
                  <TELL
"The man above you looks pleased. \"Now there's a good friend! Thank
you very much, indeed!\" He pulls on the rope and the chest is lifted
to the top of the cliff and out of sight. With a short laugh, he
disappears. \"I'll be back in a short while!\" are his last words." CR>
                  <MOVE ,CHEST ,MAN>
                  <FSET ,CHEST ,TOUCHBIT>
                  <SETG CHEST-TIED <>>
                  <SETG ROPE-FLAG <>>
                  <ENABLE <QUEUE I-MAN-RETURNS 10>>
                  <SETG MAN-FLAG <>>
                  <RTRUE>)>
               <RTRUE>)

So it should be enough to add <SETG CHEST-LIFTED T> here.