1984 · Novagen Software

Encounter

This minisite was contributed by air. It’s currently claimed by air who is editing it to reach a Gold tier standard.

What Encounter keeps from the player: a level picker that the manual says is locked and the code leaves open, a check that halts the game on an American machine, and a pause key that cannot unpause.

01 · The level keys

Secret: in this copy, any level can be picked from the title screen

On the title screen the number keys 1 to 8 pick a level. The manual says only levels already reached can be picked, and Novagen's cassette keeps to it: the code at $9CE3 compares the key's level with the highest level reached, and the branch after it ignores a key for a level further on. In the copy these pages describe, that branch has been replaced by two NOPs, so any level is available at once. Pressing 5 on a fresh boot starts level 5. On the cassette it does nothing until level 5 has been reached.

The highest level reached is kept at $68CB, in one of the title screen's rows painted in the background colour (How it works).

02 · PAL only

Secret: the game stops dead on an NTSC machine

$9DEC reads the raster line through the odd address $CFF9,X with X = 25, which lands on $D012, and spins until the line reads 0. It then looks at the previous non-zero value. On PAL that is $37 (line 311 wrapping to 0) and the game continues. On NTSC it is $06, and the code jumps through a pointer that by then holds $DBE8, an address in colour memory. On an NTSC machine the title screen is drawn and the processor parks at $DBE8 for good.

A PAL machine can stop there too. The loop keeps the previous value in $FF and stores only what it reads, so when its very first read already finds line 0 (or 256, which also reads as 0) the code judges whatever $FF held before. After a game over that is 0, left by the countdown that holds the game-over screen, and 0 is an NTSC answer: the title comes back and the processor parks at $DBE8. It needs the first read to land on one of two lines in the frame's 312, so it is rare.

03 · More from the code

Things a pilot would not know

The pause key cannot unpause

SPACE enters a loop that watches F1 and the joystick. It never looks at SPACE again; any stick direction resumes play.

The shield count is a screen cell

No variable holds the shields. The routines that add and subtract them edit the character code of the digit on the status line.

RESET restarts the game

$8000 holds the vector $9C3E twice and $8004 the text CBM80, the signature the KERNAL looks for in a cartridge. A hardware reset or RESTORE therefore lands in the game's own init instead of BASIC.

Seven bytes that should not be executed

Between the game-start setup and the level start, $9FF9 holds A9 4B 53 54 41 3A 2A. A checkpoint counted one pass through them on every F7. The processor reads them as LDA #$4B, then the undocumented SRE ($54),Y, EOR ($3A,X) and ROL A, none of which matters to what follows. As text they read KSTA:*. On Novagen's cassette the same bytes are A9 02 A2 00 20 70 AA: LDA #$02, LDX #$00, JSR $AA70, a call that colours the console's top row of lamps red as each game starts. In this copy the text has been written over the call.

Calls into the title screen

Six routines, including the main loop's wait for the raster, call addresses inside row 13 of the title screen, where seven JMP $6A1D lead to an RTS. Something once lived there. Novagen's cassette has the same jumps, so they are not this copy's doing. What lived there, whether a loader hook or a protection check, is unknown.