Skip to navigation


Version analysis of KS4

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

Code variations between these versions are shown below.

Name: KS4 Type: Subroutine Category: Universe

Code variation 1 of 3A variation in the comments only

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

Summary: Remove the space station and replace it with the sun
Summary: Remove the space station and replace with a placeholder
.KS4 JSR ZINF \ Call ZINF to reset the INWK ship workspace

Code variation 2 of 3Specific to an individual platform

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

JSR FLFLLS \ Reset the LSO block, returns with A = 0
LDA #0 \ Set A = 0 so we can zero the following flags

Code variation 3 of 3A variation in the comments only

This variation is blank in the Electron version.

STA FRIN+1 \ Set the second slot in the FRIN table to 0, which \ sets this slot to empty, so when we call NWSHP below \ the new sun that gets created will go into FRIN+1 STA SSPR \ Set the "space station present" flag to 0, as we are \ no longer in the space station's safe zone JSR SPBLB \ Call SPBLB to redraw the space station bulb, which \ will erase it from the dashboard LDA #6 \ Set the sun's y_sign to 6 STA INWK+5 LDA #129 \ Set A = 129, the ship type for the sun JMP NWSHP \ Call NWSHP to set up the sun's data block and add it \ to FRIN, where it will get put in the second slot as \ we just cleared out the second slot, and the first \ slot is already taken by the planet