the-infocom-files/trinity

Inconsistent shadow messages (by design?)

Opened this issue · 0 comments

This could be the intended behavior, but... The shadow is divided into an inner and an outer half. The outer half is the one that touches the mushrooms. When the outer shadow moves out of the room:

>WAIT
Time passes.

The shadow moves slowly northward.

>WAIT
Time passes.

The shadow inches northward. It's almost out of sight.

>WAIT
Time passes.

The edge of the shadow disappears northward.

When the inner shadow moves out of the room:

>WAIT
Time passes.

The shadow moves slowly northward.

>WAIT
Time passes.

The shadow inches northward. It's almost out of sight.

>WAIT
Time passes.

The shadow creeps northward.

>WAIT
Time passes.

The edge of the shadow disappears northward.

For the outer shadow, the "It's almost out of sight." message happens right before it moves out of sight. For the inner shadow, there is an additional message about the shadow creeping.

ODEG is the shadow's "position" within a room. It tracks the outer part of the shadow, and varies between 0 and 12.

IDEG is the shadow's "position" within a room. It tracks the inner part of the shadow, and varies between 0 and 25.

The variables are increased at the same time, and it works out because the shadow moves through two outer rooms in the time it takes to move through one inner room.

The messages are printed by I-SHADOW. For outer rooms:

ODEG Comment
0 Shadow leaves one room and enters the next.
5 The shadow touches the mushroom, if there is one.
6 The shadow creeps across the mushroom, if there is one.
7 The shadow creeps away from the mushroom, if there is one. Otherwise, it creeps across the ground.
11 The shadow is almost out of sight.

For outer rooms:

IDEG Comment
0 Shadow leaves one room and enters the next. The shadow creeps across the ground.
5 The shadow creeps across the ground.
10 The shadow creeps across the ground.
20 The shadow creeps across the ground.
23 The shadow is almost out of sight.
25 The shadow creeps across the ground.

There is no message on 15, perhaps because that's the move where the outer shadow potentially opens a door, so the routine terminates before it gets here.

This is the code for the inner shadow's "creep" messages:

	       (<AND <IN? ,INNER-SHADOW ,HERE>
		     <ZERO? <MOD ,IDEG 5>>>
		<SETG P-IT-OBJECT ,INNER-SHADOW>
		<SHADOW-CREEPS>
		<PRINT ,PERIOD>
		<RTRUE>)

	       (<OR <AND <T? .OHERE>
			 <EQUAL? ,ODEG 11>>
		    <AND <IN? ,INNER-SHADOW ,HERE>
			 <EQUAL? ,IDEG 23>>>
		<SETG P-IT-OBJECT <COND (<ZERO? .OHERE>
					 ,INNER-SHADOW)
					(T
					 ,OUTER-SHADOW)>>
		<SHADOW-CREEPS>
		<TELL ". It's almost" ,OUTASITE>
		<RTRUE>)