' scen/wall.txt - section 3: coming down on a solid block.
'
' CTRL.S falling, at the moment he passes through a floor plane:
'     :1 jsr getunderft
'        cmp #block
'        bne :2
'        jsr InsideBlock ;reset him to either side of block
'     :2 jsr cmpspace
'        bne hitflr
'        inc CharBlockY ;Fall thru floor plane
'
' A solid block is not space, so he lands on it - after InsideBlock has nudged
' him towards whichever side of it is clear.  The port has a solid block in
' its no-floor set, which is right for "nobody can stand inside one" and wrong
' for this, so he fell straight through the wall and out of the room.
'
' A wall is put in the way of a step-off on level 1 screen 1.

SCEN coming down on a wall lands on it
AT 1 1 3 0
TYPE 1 2 1 20
X 105
SEED 17
RUN ..v..........
WANT SCRN 1
WANT BY 1
WANT ALIVE 1
END

' The control: with the floor left as it was he lands on the floor, on the
' same row, exactly as before.
SCEN and an ordinary floor is unchanged
AT 1 1 3 0
X 105
SEED 17
RUN ..v..........
WANT SCRN 1
WANT BY 1
WANT BX 2
WANT ALIVE 1
END

' KNOWN DEFECT, recorded rather than fixed.  COLL.S COLLISIONS lets a
' character through a barrier only while he is hanging (action 2 or 6),
' climbing (poses 135-148) or turning (action 7), so the original bumps in the
' air as well as on the ground.  It can afford to: CHECKBARR works from the
' character's own image edges against the barrier's edge - the CD/SN nybble
' buffers and the BarL/BarR tables - and a collision is a nybble that goes
' from 0 to 1 between frames.  This port has none of that, and what stands in
' for it is "the block ahead is a barrier and he has reached its edge".  On
' the ground that is the same answer.  In the air it is not: a man falling
' PAST a wall is beside it every frame, so letting the test run in the air
' smacks him into the wall under every ledge he reaches for and the grab stops
' working altogether.  So HitBarrier still leaves the air alone.
'
' Three findings come back to this one gap, and none can be closed without it:
'   - the mid-air wall hit, below;
'   - COLL.S ENEMYCOLL, which wants an en-garde fighter in action 1 and never
'     sees one, because HitBarrier has already put him in action 5;
'   - MISC.S REFLECTION, which wants him standing IN the mirror's block.  A
'     mirror is a barrier, so he is stopped one block short of the glass and
'     his reflection is never drawn.  The original lets him in because the bar
'     is a plane part way through the block rather than the whole of it.
'
' Level 1 screen 1 has floor at columns 3 to 7 and solid block at 8 and 9.  A
' running jump from column 3 meets that wall at the top of its arc, nineteen
' frames in, and goes INTO block 8 - inside the wall - to be pushed back out
' two frames later when he comes down.  This records that.  Whoever ports
' CHECKBARR properly should find this scenario failing, and the answers it
' should then give are BUMPS 1 and BX 7.
SCEN a running jump still ends up inside the wall
AT 1 1 3 0
FACE 0
SEED 17
RUN ..>>>>>>>>JFFFFFFFF
WANT BUMPS 0
WANT BX 8
WANT ALIVE 1
END

' COLL.S sends every bump, soft or hard, through BumpSound:
'     BumpSound
'      lda #1 / sta alertguard
'      lda #SmackWall / jmp addsound
' The port walked into walls in silence and told nobody, so a guard who would
' have turned round at the noise heard nothing.  Also ":normal" begins
' "cpx #24 / beq :hard": pose 24 is the other half of the stand jump and
' belongs with 25 in the hard-bump list.  (That half cannot be shown from
' here - HitBarrier's ground gate means a pose without the on-the-ground mark
' never reaches the bump at all, so 24 is never the pose of record.  See the
' known defect above.)
'
' He jumps at the wall on the right of screen 1 from column 7.  Twelve frames
' in he is still in the air and nothing has been heard; thirteen and he has
' hit it.
SCEN a moment before the wall, nothing has been heard
AT 1 1 7 0
FACE 0
SEED 17
RUN ..JJJJJJJJJJ
WANT NOISE 0
WANT BUMPS 0
END

SCEN hitting the wall makes a noise a guard can hear
AT 1 1 7 0
FACE 0
SEED 17
RUN ..JJJJJJJJJJJ
WANT NOISE 1
WANT BUMPS 1
END
