Skip to navigation


Version analysis of PAS1

This code appears in the following versions (click to see it in the source code):

Code variations between these versions are shown below.

Name: PAS1 Type: Subroutine Category: Missions

Code variation 1 of 4A variation in the comments only

This variation is blank in the Master version.

Summary: Display a rotating ship at space coordinates (0, 112, 256) and scan the keyboard


Code variation 2 of 4A variation in the comments only

Tap on a block to expand it, and tap it again to revert.

Returns: X If a key is being pressed, X contains the internal key number, otherwise it contains 0 A Contains the same as X
Returns: X If a key is being pressed, X contains the ASCII code of the key being pressed, otherwise it contains 0 A Contains the same as X
.PAS1

Code variation 3 of 4Related to the Master version

In the Master version, the rotating Constrictor in the mission 1 briefing is slightly higher up the screen than in the other versions.

This variation is blank in the Master version.

LDA #112 \ Set y_lo = 112 STA INWK+3
 LDA #0                 \ Set x_lo = 0
 STA INWK

 STA INWK+6             \ Set z_lo = 0

 LDA #2                 \ Set z_hi = 1, so (z_hi z_lo) = 256
 STA INWK+7

 JSR LL9                \ Draw the ship on screen

 JSR MVEIT              \ Call MVEIT to move and rotate the ship in space

Code variation 4 of 4Specific to an individual platform

Tap on a block to expand it, and tap it again to revert.

JMP RDKEY \ Scan the keyboard for a key press and return the \ internal key number in X (or 0 for no key press), \ returning from the subroutine using a tail call
JMP RDKEY \ Scan the keyboard for a key press and return the \ ASCII code of the key pressed in X (or 0 for no key \ press), returning from the subroutine using a tail \ call