This index contains every subroutine, entry point, variable, workspace and macro that appears in the source code for the NES version of Elite, sorted alphabetically.
Name | Category | Description |
---|---|---|
ABORT (Bank 0) | Dashboard | Disarm missiles and update the dashboard indicators |
ABORT2 (Bank 0) | Dashboard | Set/unset the lock target for a missile and update the dashboard |
ACT (Bank 7) | Maths (Geometry) | Arctan table |
ADD (Bank 7) | Maths (Arithmetic) | Calculate (A X) = (A P) + (S R) |
ADD_CYCLES (Common) | Drawing the screen | Add a specified number to the cycle count |
ADD_CYCLES_CLC (Common) | Drawing the screen | Add a specified number to the cycle count |
addr (Common) | Workspace variable | Temporary storage, used in a number of places to hold an address |
alertColours (Bank 7) | Status | Colours for the background of the commander image to show the status condition when we are not looking at the space view |
allowInSystemJump (Common) | Workspace variable | Bits 6 and 7 record whether it is safe to perform an in-system jump |
ALP1 (Common) | Workspace variable | Magnitude of the roll angle alpha, i.e. |alpha|, which is a positive value between 0 and 31 |
ALP2 (Common) | Workspace variable | Bit 7 of ALP2 = sign of the roll angle in ALPHA |
ALPHA (Common) | Workspace variable | The current roll angle alpha, which is reduced from JSTX to a sign-magnitude value between -31 and +31 |
ALTIT (Common) | Workspace variable | Our altitude above the surface of the planet or sun |
ANGRY (Bank 0) | Tactics | Make a ship hostile |
antilog (Bank 7) | Maths (Arithmetic) | Binary antilogarithm table |
antilogODD (Bank 7) | Maths (Arithmetic) | Binary antilogarithm table |
ApplyEnvelopeNOISE (Bank 6) | Sound | Apply volume and pitch changes to the NOISE channel |
ApplyEnvelopeSQ1 (Bank 6) | Sound | Apply volume and pitch changes to the SQ1 channel |
ApplyEnvelopeSQ2 (Bank 6) | Sound | Apply volume and pitch changes to the SQ2 channel |
ApplyEnvelopeTRI (Bank 6) | Sound | Apply volume and pitch changes to the TRI channel |
applyVolumeNOISE (Common) | Workspace variable | A flag that determines whether to apply the volume envelope to the NOISE channel |
applyVolumeSQ1 (Common) | Workspace variable | A flag that determines whether to apply the volume envelope to the SQ1 channel |
applyVolumeSQ2 (Common) | Workspace variable | A flag that determines whether to apply the volume envelope to the SQ2 channel |
ARCTAN (Bank 1) | Maths (Geometry) | Calculate A = arctan(P / Q) |
asciiToPattern (Common) | Workspace variable | The number to add to an ASCII code to get the pattern number in the PPU of the corresponding character image |
ASH (Common) | Workspace variable | Aft shield status |
attrBuffer0 (Common) | Workspace variable | The buffer for attribute table 0 that gets sent to the PPU during VBlank |
attrBuffer1 (Common) | Workspace variable | The buffer for attribute table 0 that gets sent to the PPU during VBlank |
attrSprite0 (Common) | Workspace variable | Attributes for sprite 0 |
attrSprite1 (Common) | Workspace variable | Attributes for sprite 1 |
attrSprite10 (Common) | Workspace variable | Attributes for sprite 10 |
attrSprite11 (Common) | Workspace variable | Attributes for sprite 11 |
attrSprite12 (Common) | Workspace variable | Attributes for sprite 12 |
attrSprite13 (Common) | Workspace variable | Attributes for sprite 13 |
attrSprite14 (Common) | Workspace variable | Attributes for sprite 14 |
attrSprite15 (Common) | Workspace variable | Attributes for sprite 15 |
attrSprite16 (Common) | Workspace variable | Attributes for sprite 16 |
attrSprite17 (Common) | Workspace variable | Attributes for sprite 17 |
attrSprite18 (Common) | Workspace variable | Attributes for sprite 18 |
attrSprite19 (Common) | Workspace variable | Attributes for sprite 19 |
attrSprite2 (Common) | Workspace variable | Attributes for sprite 2 |
attrSprite20 (Common) | Workspace variable | Attributes for sprite 20 |
attrSprite21 (Common) | Workspace variable | Attributes for sprite 21 |
attrSprite22 (Common) | Workspace variable | Attributes for sprite 22 |
attrSprite23 (Common) | Workspace variable | Attributes for sprite 23 |
attrSprite24 (Common) | Workspace variable | Attributes for sprite 24 |
attrSprite25 (Common) | Workspace variable | Attributes for sprite 25 |
attrSprite26 (Common) | Workspace variable | Attributes for sprite 26 |
attrSprite27 (Common) | Workspace variable | Attributes for sprite 27 |
attrSprite28 (Common) | Workspace variable | Attributes for sprite 28 |
attrSprite29 (Common) | Workspace variable | Attributes for sprite 29 |
attrSprite3 (Common) | Workspace variable | Attributes for sprite 3 |
attrSprite30 (Common) | Workspace variable | Attributes for sprite 30 |
attrSprite31 (Common) | Workspace variable | Attributes for sprite 31 |
attrSprite32 (Common) | Workspace variable | Attributes for sprite 32 |
attrSprite33 (Common) | Workspace variable | Attributes for sprite 33 |
attrSprite34 (Common) | Workspace variable | Attributes for sprite 34 |
attrSprite35 (Common) | Workspace variable | Attributes for sprite 35 |
attrSprite36 (Common) | Workspace variable | Attributes for sprite 36 |
attrSprite37 (Common) | Workspace variable | Attributes for sprite 37 |
attrSprite38 (Common) | Workspace variable | Attributes for sprite 38 |
attrSprite39 (Common) | Workspace variable | Attributes for sprite 39 |
attrSprite4 (Common) | Workspace variable | Attributes for sprite 4 |
attrSprite40 (Common) | Workspace variable | Attributes for sprite 40 |
attrSprite41 (Common) | Workspace variable | Attributes for sprite 41 |
attrSprite42 (Common) | Workspace variable | Attributes for sprite 42 |
attrSprite43 (Common) | Workspace variable | Attributes for sprite 43 |
attrSprite44 (Common) | Workspace variable | Attributes for sprite 44 |
attrSprite45 (Common) | Workspace variable | Attributes for sprite 45 |
attrSprite46 (Common) | Workspace variable | Attributes for sprite 46 |
attrSprite47 (Common) | Workspace variable | Attributes for sprite 47 |
attrSprite48 (Common) | Workspace variable | Attributes for sprite 48 |
attrSprite49 (Common) | Workspace variable | Attributes for sprite 49 |
attrSprite5 (Common) | Workspace variable | Attributes for sprite 5 |
attrSprite50 (Common) | Workspace variable | Attributes for sprite 50 |
attrSprite51 (Common) | Workspace variable | Attributes for sprite 51 |
attrSprite52 (Common) | Workspace variable | Attributes for sprite 52 |
attrSprite53 (Common) | Workspace variable | Attributes for sprite 53 |
attrSprite54 (Common) | Workspace variable | Attributes for sprite 54 |
attrSprite55 (Common) | Workspace variable | Attributes for sprite 55 |
attrSprite56 (Common) | Workspace variable | Attributes for sprite 56 |
attrSprite57 (Common) | Workspace variable | Attributes for sprite 57 |
attrSprite58 (Common) | Workspace variable | Attributes for sprite 58 |
attrSprite59 (Common) | Workspace variable | Attributes for sprite 59 |
attrSprite6 (Common) | Workspace variable | Attributes for sprite 6 |
attrSprite60 (Common) | Workspace variable | Attributes for sprite 60 |
attrSprite61 (Common) | Workspace variable | Attributes for sprite 61 |
attrSprite62 (Common) | Workspace variable | Attributes for sprite 62 |
attrSprite63 (Common) | Workspace variable | Attributes for sprite 63 |
attrSprite7 (Common) | Workspace variable | Attributes for sprite 7 |
attrSprite8 (Common) | Workspace variable | Attributes for sprite 8 |
attrSprite9 (Common) | Workspace variable | Attributes for sprite 9 |
auto (Common) | Workspace variable | Docking computer activation status |
AutoPlayDemo (Bank 7) | Combat demo | Automatically play the demo using the auto-play commands from the autoplayKeys tables |
autoPlayDemo (Common) | Workspace variable | Controls whether to play the demo automatically (which happens after it is left idle for a while) |
autoPlayKey (Common) | Workspace variable | Stores the buttons to be automatically pressed during auto-play |
autoPlayKeys (Common) | Workspace variable | The address of the table containing the key presses to apply when auto-playing the demo |
autoPlayKeys1_DE (Bank 7) | Combat demo | Auto-play commands for the first part of the auto-play combat demo (combat practice) when German is the chosen language |
autoPlayKeys1_EN (Bank 7) | Combat demo | Auto-play commands for the first part of the auto-play combat demo (combat practice) when English is the chosen language |
autoPlayKeys1_FR (Bank 7) | Combat demo | Auto-play commands for the first part of the auto-play combat demo (combat practice) when French is the chosen language |
autoPlayKeys1Hi (Bank 5) | Combat demo | High byte of the address of the auto-play key table for each language |
autoPlayKeys1Lo (Bank 5) | Combat demo | Low byte of the address of the auto-play key table for each language |
autoPlayKeys2 (Bank 7) | Combat demo | Auto-play commands for the second part of the auto-play demo (demonstrating the game itself) |
autoPlayRepeat (Common) | Workspace variable | Stores the number of times a step should be repeated during auto-play |
AVL (Common) | Workspace variable | Market availability in the current system |
BAD (Bank 0) | Status | Calculate how bad we have been |
barButtons (Common) | Workspace variable | The address of the list of button numbers in the iconBarButtons table for the current icon bar |
barNames0 (Bank 3) | Icon bar | Nametable entries for icon bar 0 (Docked) |
barNames1 (Bank 3) | Icon bar | Nametable entries for icon bar 1 (Flight) |
barNames2 (Bank 3) | Icon bar | Nametable entries for icon bar 2 (Charts) |
barNames3 (Bank 3) | Icon bar | Nametable entries for icon bar 3 (Pause) |
barNames4 (Bank 3) | Icon bar | Nametable entries for icon bar 4 (Title screen copyright message) |
barPatternCounter (Common) | Workspace variable | The number of icon bar nametable and pattern entries that need to be sent to the PPU in the NMI handler |
BAY (Bank 0) | Status | Go to the docking bay (i.e. show the Status Mode screen) |
BAYSTEP (Bank 0) | Missions | Go to the docking bay (i.e. show the Status Mode screen) |
BEEP (Bank 7) | Sound | Make a short, high beep |
BEEP_b7 (Bank 7) | Sound | Call the BEEP routine in ROM bank 7 |
BEGIN (Bank 7) | Start and end | Run through the NES initialisation process, reset the variables and start the game |
BELL (Bank 2) | Sound | Make a standard system beep |
BET1 (Common) | Workspace variable | The magnitude of the pitch angle beta, i.e. |beta|, which is a positive value between 0 and 8 |
BET2 (Common) | Workspace variable | Bit 7 of BET2 = sign of the pitch angle in BETA |
BETA (Common) | Workspace variable | The current pitch angle beta, which is reduced from JSTY to a sign-magnitude value between -8 and +8 |
bigLogoImage (Bank 4) | Start and end | Packed image data for the big Elite logo shown on the Start screen |
bigLogoNames (Bank 4) | Start and end | Nametable entries for the big Elite logo on the Start screen |
bitplaneFlags (Common) | Workspace variable | Flags for bitplane 0 that control the sending of data for this bitplane to the PPU during VBlank in the NMI handler: |
BlankAllButtons (Bank 3) | Icon bar | Blank all the buttons on the icon bar |
BlankButtons6To11 (Bank 3) | Icon bar | Blank from the sixth to the eleventh button on the icon bar |
BlankButtons8To11 (Bank 3) | Icon bar | Blank from the eighth to the eleventh button on the icon bar |
BLINE (Bank 1) | Drawing circles | Draw a circle segment and add it to the ball line heap |
BOMB (Common) | Workspace variable | Energy bomb |
BOOP (Bank 7) | Sound | Make a long, low beep |
boxEdge1 (Common) | Workspace variable | The tile number for drawing the left edge of a box |
boxEdge2 (Common) | Workspace variable | The tile number for drawing the right edge of a box |
boxEdgeImages (Bank 3) | Drawing the screen | Image data for patterns 0 to 4 |
BPRNT (Bank 0) | Text | Print a 32-bit number, left-padded to a specific number of digits, with an optional decimal point |
BR1 (Bank 0) | Start and end | Reset a number of variables, ready to start a new game |
BRIEF (Bank 0) | Missions | Start mission 1 and show the mission briefing |
BRIEF2 (Bank 0) | Missions | Start mission 2 |
BRIEF3 (Bank 0) | Missions | Receive the briefing and plans for mission 2 |
BRIS (Bank 2) | Missions | Clear the screen, display "INCOMING MESSAGE" and wait for 2 seconds |
BRIS_b0 (Bank 0) | Missions | Clear the screen, display "INCOMING MESSAGE" and wait for 2 seconds |
BRP (Bank 0) | Missions | Print an extended token and show the Status Mode screen |
BRPS (Bank 0) | Missions | Print the extended token in A, show the Status Mode screen and return from the subroutine |
BST (Common) | Workspace variable | Fuel scoops (BST stands for "barrel status") |
BUF (Common) | Workspace variable | The line buffer used by DASC to print justified text |
BUMP2 (Bank 7) | Dashboard | Bump up the value of the pitch or roll dashboard indicator |
burstSpriteIndex (Common) | Workspace variable | The index into the sprite buffer of the explosion burst sprite that is set up in DrawExplosionBurst |
BuyAndSellCargo (Bank 0) | Market | Process the buying and selling of cargo on the Market Price screen |
c (Bank 0) | Equipment | Contains an RTS |
CABTMP (Common) | Workspace variable | Cabin temperature |
CalculateGridLines (Bank 6) | Combat demo | Reset the line coordinate tables and populate them with the characters for a specified scroll text |
Cartridge WRAM (Common) | Workspaces | The 8K of battery-backed RAM in the Elite cartridge, which is used for the graphics buffers and storing saved commanders |
CASH (Common) | Workspace variable | Our current cash pot |
ChangeCmdrName (Bank 6) | Save and load | Process changing the commander name |
ChangeCmdrName_b6 (Bank 7) | Save and load | Call the ChangeCmdrName routine in ROM bank 6 |
ChangeLetter (Bank 6) | Controllers | Choose a letter using the up and down buttons |
ChangeToView (Bank 0) | Drawing the screen | Clear the screen and set a new view type |
ChangeToView_b0 (Bank 7) | Drawing the screen | Call the ChangeToView routine in ROM bank 0 |
channelPriority (Common) | Workspace variable | The priority of the sound on the current channel (0 to 2) |
CHAR (Common) | Text | Macro definition for characters in the recursive token table |
characterEnd (Common) | Workspace variable | The number of the character beyond the end of the printable character set for the chosen language |
characterEndLang (Bank 6) | Text | The number of the character beyond the end of the printable character set in each language |
chargeDockingFee (Common) | Workspace variable | Records whether we have been charged a docking fee, so we don't get charged twice: |
ChargeShields (Bank 0) | Flight | Charge the shields and energy banks |
chartToShow (Common) | Workspace variable | Controls which chart is shown when choosing the chart button on the icon bar (as the Long-range and Short-range Charts share the same button) |
cheatCmdrName (Bank 6) | Save and load | The commander name that triggers cheat mode in each language |
CheckAltitude (Bank 0) | Flight | Perform an altitude check with the planet, ending the game if we hit the ground |
CheckForPause (Bank 0) | Icon bar | Pause the game if the pause button (Start) is pressed |
CheckForPause-3 (Bank 0) | Icon bar | Set A to the number of the icon bar button in iconBarChoice so we check whether the pause button is being pressed |
CheckForPause_b0 (Bank 7) | Icon bar | Call the CheckForPause routine in ROM bank 0 |
CheckJumpSafety (Bank 0) | Flight | Check whether we are far enough away from the planet and sun to be able to do an in-system (fast-forward) jump |
CheckJumpSafety+2 (Bank 0) | Flight | Check the distances against the value of 0.5 * A |
CheckPauseButton (Bank 7) | Icon bar | Check whether the pause button has been pressed or an icon bar button has been chosen, and process pause/unpause if required |
CheckSaveLoadBar (Bank 6) | Save and load | Check the icon bar buttons on the Save and Load icon bar and process any choices |
CheckSaveSlots (Bank 6) | Save and load | Load the commanders for all eight save slots, one after the other, to check their integrity and reset any that fail their checksums |
CheckSaveSlots_b6 (Bank 7) | Save and load | Call the CheckSaveSlots routine in ROM bank 6 |
CHKON (Bank 1) | Drawing circles | Check whether any part of a circle appears on the extended screen |
ChooseLanguage (Bank 6) | Start and end | Draw the Start screen and process the language choice |
ChooseLanguage_b6 (Bank 7) | Start and end | Call the ChooseLanguage routine in ROM bank 6 |
ChooseMusic (Bank 6) | Sound | Set the tune for the background music |
ChooseMusic_b6 (Bank 7) | Sound | Call the ChooseMusic routine in ROM bank 6 |
ChooseMusicS (Bank 6) | Sound | A jump table entry at the start of bank 6 for the ChooseMusic routine |
CHPR (Part 1 of 6) (Bank 2) | Text | Print a character at the text cursor by poking into screen memory |
CHPR (Part 2 of 6) (Bank 2) | Text | Jump to the right part of the routine depending on whether the font pattern we need is already loaded |
CHPR (Part 3 of 6) (Bank 2) | Text | Draw a character into the pattern buffers to show the character on-screen |
CHPR (Part 4 of 6) (Bank 2) | Text | Process the delete character |
CHPR (Part 5 of 6) (Bank 2) | Text | Print the character using a font that has already been loaded |
CHPR (Part 6 of 6) (Bank 2) | Text | Print a character in the space view when the relevant font is not loaded, merging the text with whatever is already on-screen |
CHPR_b2 (Bank 7) | Text | Call the CHPR routine in ROM bank 2 |
CIRCLE (Bank 1) | Drawing circles | Draw a circle for the planet |
CIRCLE2 (Bank 1) | Drawing circles | Draw a circle (for the planet or chart) |
CIRCLE2_b1 (Bank 7) | Drawing circles | Call the CIRCLE2 routine in ROM bank 1 |
clearAddress (Common) | Workspace variable | The address of a block of memory to clear, for example when clearing the buffers |
clearBlockSize (Common) | Workspace variable | The size of the block of memory to clear, for example when clearing the buffers |
ClearBuffers (Bank 7) | Drawing the screen | If there are enough free cycles, clear down the nametable and pattern buffers for both bitplanes |
ClearDashEdge (Bank 6) | Drawing the screen | Clear the right edge of the dashboard |
ClearDashEdge_b6 (Bank 7) | Drawing the screen | Call the ClearDashEdge routine in ROM bank 6 |
ClearDrawingPlane (Part 1 of 3) (Bank 7) | Drawing the screen | Clear the nametable and pattern buffers for the newly flipped drawing plane |
ClearDrawingPlane (Part 2 of 3) (Bank 7) | Drawing the screen | Clear the nametable buffers for the newly flipped drawing plane |
ClearDrawingPlane (Part 3 of 3) (Bank 7) | Drawing the screen | Clear the pattern buffers for the newly flipped drawing plane |
clearingNameTile (Common) | Workspace variable | The number of the first tile to clear in nametable buffer 0 when the NMI handler clears tiles, divided by 8 |
clearingPattern (Common) | Workspace variable | The number of the first pattern to clear in pattern buffer 0 when the NMI handler clears patterns |
ClearMemory (Bank 7) | Utility routines | Clear a block of memory, split across multiple calls if required |
ClearNameInMiddle (Bank 6) | Save and load | Remove the commander name from the middle column |
ClearPlaneBuffers (Part 1 of 2) (Bank 7) | Drawing the screen | Clear the nametable and pattern buffers of data that has already been sent to the PPU, starting with the nametable buffer |
ClearPlaneBuffers (Part 2 of 2) (Bank 7) | Drawing the screen | Clear the pattern buffer of data that has already been sent to the PPU for the current bitplane |
ClearScanner (Bank 7) | Dashboard | Remove all ships from the scanner and hide the scanner sprites |
ClearScreen (Bank 3) | Drawing the screen | Clear the screen by clearing patterns 66 to 255 in both pattern buffers, and clearing both nametable buffers to the background |
ClearScreen_b3 (Bank 7) | Drawing the screen | Call the ClearScreen routine in ROM bank 3 |
CLIP (Bank 1) | Drawing lines | Another name for LL145 CLIP2 Don't initialise the values in SWAP or A |
CLIP2 (Bank 1) | Drawing lines | Don't initialise the values in SWAP or A |
CLIP_b1 (Bank 7) | Drawing lines | Call the CLIP routine in ROM bank 1, drawing the clipped line if it fits on-screen |
cloudSize (Common) | Workspace variable | Used to store the explosion cloud size in PTCLS |
CLYNS (Bank 7) | Drawing the screen | Clear the bottom two text rows of the visible screen |
CLYNS+8 (Bank 7) | Drawing the screen | Don't zero DLY and de |
cmn (Bank 0) | Status | Print the commander's name |
cmn-1 (Bank 0) | Status | Contains an RTS |
CNT (Common) | Workspace variable | Temporary storage, typically used for storing the number of iterations required when looping |
CNT2 (Common) | Workspace variable | Temporary storage, used in the planet-drawing routine to store the segment number where the arc of a partial circle should start |
cntr (Bank 7) | Dashboard | Apply damping to the pitch or roll dashboard indicator |
cobraImage (Bank 3) | Equipment | Packed image data for the Cobra Mk III shown on the Equip Ship screen |
cobraNames (Bank 4) | Save and load | Nametable entries for the Cobra Mk III shown on the Equip Ship screen |
COK (Common) | Workspace variable | A flag to record whether cheat mode has been applied (by renaming the commander file to CHEATER, BETRUG or TRICHER) |
COMPAS (Bank 0) | Dashboard | Update the compass |
conditionAttrs (Bank 6) | Dashboard | Sprite attributes for the status condition indicator on the dashboard |
conditionPatts (Bank 6) | Dashboard | Pattern numbers for the status condition indicator on the dashboard |
ConsiderSendTiles (Bank 7) | PPU | If there are enough free cycles, move on to the next stage of sending patterns to the PPU |
CONT (Common) | Text | Macro definition for control codes in the recursive token table |
controller1A (Common) | Workspace variable | A shift register for recording presses of the A button on controller 1 |
controller1B (Common) | Workspace variable | A shift register for recording presses of the B button on controller 1 |
controller1Down (Common) | Workspace variable | A shift register for recording presses of the down button on controller 1 |
controller1Left (Common) | Workspace variable | A shift register for recording presses of the left button on controller 1 |
controller1Left03 (Common) | Workspace variable | Bits 0 to 3 of the left button controller variable |
controller1Right (Common) | Workspace variable | A shift register for recording presses of the right button on controller 1 |
controller1Right03 (Common) | Workspace variable | Bits 0 to 3 of the right button controller variable |
controller1Select (Common) | Workspace variable | A shift register for recording presses of the Select button on controller 1 |
controller1Start (Common) | Workspace variable | A shift register for recording presses of the Start button on controller 1 |
controller1Up (Common) | Workspace variable | A shift register for recording presses of the up button on controller 1 |
controller2A (Common) | Workspace variable | A shift register for recording presses of the A button on controller 2 |
controller2B (Common) | Workspace variable | A shift register for recording presses of the B button on controller 2 |
controller2Down (Common) | Workspace variable | A shift register for recording presses of the down button on controller 2 |
controller2Left (Common) | Workspace variable | A shift register for recording presses of the left button on controller 2 |
controller2Right (Common) | Workspace variable | A shift register for recording presses of the right button on controller 2 |
controller2Select (Common) | Workspace variable | A shift register for recording presses of the Select button on controller 2 |
controller2Start (Common) | Workspace variable | A shift register for recording presses of the Start button on controller 2 |
controller2Up (Common) | Workspace variable | A shift register for recording presses of the up button on controller 2 |
CopyCommanderToBuf (Bank 6) | Save and load | Copy a commander file in the BUF buffer, either from a save slot or from the currently active commander in-game |
CopyLargeBlock (Bank 7) | Utility routines | An unused routine that copies a large number of pages in memory |
CopyNameBuffer0To1 (Bank 7) | Drawing the screen | Copy the contents of nametable buffer 0 to nametable buffer 1 |
Copyright and version message (Bank 3) | Text | A copyright and version message buried in the code |
Copyright message (Bank 5) | Text | A copyright message buried in the code, complete with typo |
CopySmallBlock (Bank 7) | Utility routines | An unused routine that copies a small number of pages in memory |
cpl (Bank 0) | Universe | Print the selected system name |
creditsText1 (Bank 6) | Combat demo | Text for the first part of the credits scroll text |
creditsText1Hi (Bank 6) | Combat demo | Lookup table for the high byte of the address of the creditsText1 text for each language |
creditsText1Lo (Bank 6) | Combat demo | Lookup table for the low byte of the address of the creditsText1 text for each language |
creditsText2 (Bank 6) | Combat demo | Text for the second part of the credits scroll text |
creditsText2Hi (Bank 6) | Combat demo | Lookup table for the high byte of the address of the creditsText2 text for each language |
creditsText2Lo (Bank 6) | Combat demo | Lookup table for the low byte of the address of the creditsText2 text for each language |
creditsText3 (Bank 6) | Combat demo | Text for the third part of the credits scroll text |
creditsText3Hi (Bank 6) | Combat demo | Lookup table for the high byte of the address of the creditsText3 text for each language |
creditsText3Lo (Bank 6) | Combat demo | Lookup table for the low byte of the address of the creditsText3 text for each language |
CRGO (Common) | Workspace variable | Our ship's cargo capacity |
csh (Bank 0) | Status | Print the current amount of cash |
currentBank (Common) | Workspace variable | Contains the number of the ROM bank (0 to 6) that is currently paged into memory at $8000 |
currentSlot (Common) | Workspace variable | The save slot for the currently selected commander file |
cycleCount (Common) | Workspace variable | Counts the number of CPU cycles left in the current VBlank in the NMI handler |
DAMP (Common) | Workspace variable | Controller damping configuration setting |
DASC (Bank 2) | Text | DASC does exactly the same as TT26 and prints a character at the text cursor, with support for verified text in extended tokens |
DASC_b2 (Bank 7) | Text | Call the DASC routine in ROM bank 2 |
dashImage (Bank 3) | Dashboard | Packed image data for the dashboard |
dashNames (Bank 3) | Dashboard | Nametable entries for the dashboard |
dataForPPU (Common) | Workspace variable | An address pointing to data that we send to the PPU |
DCS1 (Bank 0) | Flight | Calculate the vector from the ideal docking position to the ship |
de (Common) | Workspace variable | Equipment destruction flag |
DEATH (Bank 0) | Start and end | Display the death screen |
DEATH2 (Bank 0) | Start and end | Reset most of the game and restart from the title screen |
DEATH2_b0 (Bank 7) | Start and end | Switch to ROM bank 0 and call the DEATH2 routine |
DEBRIEF (Bank 0) | Missions | Finish mission 1 |
DEBRIEF2 (Bank 0) | Missions | Finish mission 2 |
decimalPoint (Common) | Workspace variable | The decimal point character for the chosen language |
decimalPointLang (Bank 6) | Text | The decimal point character to use for each language |
decj2 (Bank 7) | Controllers | Return a value of X = 128, for the centre of the indicator |
DecreaseJoystick (Bank 7) | Controllers | Decrease a joystick value by a specific amount, jumping straight to the indicator centre if we decrease from the right-hand side |
DELAY (Bank 7) | Utility routines | Wait until a specified number of NMI interrupts have passed (i.e. a specified number of VBlanks) |
DELT4 (Common) | Workspace variable | Our current speed * 64 as a 16-bit value |
DELTA (Common) | Workspace variable | Our current speed, in the range 1-40 |
demoInProgress (Common) | Workspace variable | A flag to determine whether we are playing the demo: |
DENGY (Bank 0) | Flight | Drain some energy from the energy banks |
DETOK (Bank 2) | Text | Print an extended recursive token from the TKN1 token table |
DETOK2 (Bank 2) | Text | Print an extended text token (1-255) |
DETOK3 (Bank 2) | Text | Print an extended recursive token from the RUTOK token table |
DETOK_b2 (Bank 7) | Text | Call the DETOK routine in ROM bank 2 |
DIALS (Bank 6) | Dashboard | Update the dashboard |
DIALS_b6 (Bank 7) | Dashboard | Call the DIALS routine in ROM bank 6 |
DILX (Bank 6) | Dashboard | Update a bar-based indicator on the dashboard |
DILX+2 (Bank 6) | Dashboard | The range of the indicator is 0-64 (for the fuel and speed indicators) |
DisableJustifyText (Bank 0) | Text | Turn off justified text and reset the justified text buffer |
disableMusic (Common) | Workspace variable | Music on/off configuration setting |
distaway (Common) | Workspace variable | Used to store the nearest distance of the rotating ship on the title screen |
djd1 (Bank 7) | Dashboard | Auto-recentre the value in X, if keyboard auto-recentre is configured |
DKCMP (Common) | Workspace variable | Docking computer |
DLY (Common) | Workspace variable | In-flight message delay |
dn (Bank 0) | Market | Print the amount of money we have left in the cash pot |
DNOIZ (Common) | Workspace variable | Sound on/off configuration setting |
dock2 (Bank 3) | Icon bar | Process the second button on the Docked or Flight icon bars |
dockEd (Bank 0) | Flight | Print a message to say there is no hyperspacing allowed inside the station |
DOCKIT (Bank 0) | Flight | Apply docking manoeuvres to the ship in INWK |
DOENTRY (Bank 0) | Flight | Dock at the space station, show the ship hangar and work out any mission progression |
DOEXP (Bank 1) | Drawing ships | Draw an exploding ship |
DOKEY (Bank 0) | Controllers | Scan for the seven primary flight controls and apply the docking computer manoeuvring code |
DORND (Bank 7) | Maths (Arithmetic) | Generate random numbers |
DORND2 (Bank 7) | Maths (Arithmetic) | Make sure the C flag doesn't affect the outcome |
Draw2OptionTiles (Bank 3) | Icon bar | Draw a top and bottom tile over the top of an icon bar button in the Pause icon bar to change an option icon to a non-default state |
Draw4OptionTiles (Bank 3) | Icon bar | Draw four tiles over the top of an icon bar button in the Pause icon bar to change an option icon to a non-default state |
Draw6OptionTiles (Bank 3) | Icon bar | Draw six tiles over the top of an icon bar button in the Pause icon bar to change an option icon to a non-default state |
DrawBackground (Bank 3) | Drawing the screen | Draw the background of a system or commander image into the nametable buffer |
DrawBackground_b3 (Bank 7) | Drawing the screen | Call the DrawBackground routine in ROM bank 3 |
DrawBigLogo (Bank 4) | Start and end | Set the pattern and nametable buffer entries for the big Elite logo on the Start screen |
DrawBigLogo_b4 (Bank 7) | Start and end | Call the DrawBigLogo routine in ROM bank 4 |
DrawBitplaneInNMI (Bank 7) | Drawing the screen | Configure the NMI to send the drawing bitplane to the PPU after drawing the box edges and setting the next free tile number |
DrawBlankButton2x2 (Bank 3) | Icon bar | Draw a blank icon bar button as a 2x2 tile block |
DrawBlankButton3x2 (Bank 3) | Icon bar | Draw a blank icon bar button as a 3x2 tile block |
DrawBoxEdges (Bank 7) | Drawing the screen | Draw the left and right edges of the box along the sides of the screen, drawing into the nametable buffer for the drawing bitplane |
DrawBoxTop (Bank 7) | Drawing the screen | Draw the top edge of the box along the top of the screen in nametable buffer 0 |
DrawChartSystem (Bank 0) | Charts | Draw system blobs on short-range chart |
DrawCmdrImage (Bank 6) | Status | Draw the commander image as a coloured face image in front of a greyscale headshot image, with optional embellishments |
DrawCmdrImage_b6 (Bank 7) | Status | Call the DrawCmdrImage routine in ROM bank 6 |
DrawCobraMkIII (Bank 0) | Equipment | Draw the Cobra Mk III on the Equip Ship screen |
DrawCrosshairs (Bank 0) | Charts | Draw a set of moveable crosshairs as a square reticle |
DrawDash (Bank 7) | Drawing pixels | Draw a two-pixel dash |
DrawDashNames (Bank 3) | Dashboard | Draw the dashboard into both the nametable buffers |
DrawDashNames_b3 (Bank 7) | Dashboard | Call the DrawDashNames routine in ROM bank 3 |
DrawEquipment (Bank 6) | Equipment | Draw the currently fitted equipment onto the Cobra Mk III image on the Equip Ship screen |
DrawEquipment_b6 (Bank 7) | Equipment | Call the DrawEquipment routine in ROM bank 6 |
DrawExplosionBurst (Bank 1) | Drawing ships | Draw an exploding ship along with an explosion burst made up of colourful sprites |
DrawGlasses (Bank 6) | Status | Draw a pair of dark glasses on the commander image |
DrawHangarWallLine (Bank 1) | Ship hangar | Draw a vertical hangar wall line from top to bottom, stopping when it bumps into existing on-screen content |
DrawIconBar (Bank 3) | Icon bar | Draw the icon bar into the nametable buffers for both bitplanes |
DrawImageFrame (Bank 3) | Drawing the screen | Draw a frame around the system image or commander headshot |
DrawImageFrame_b3 (Bank 7) | Drawing the screen | Call the DrawImageFrame routine in ROM bank 3 |
DrawImageNames (Bank 4) | Drawing the screen | Set the nametable buffer entries for the specified image |
DrawImageNames_b4 (Bank 7) | Drawing the screen | Call the DrawImageNames routine in ROM bank 4 |
drawingBitplane (Common) | Workspace variable | Flipped manually by calling FlipDrawingPlane, controls whether we are showing nametable/palette buffer 0 or 1 |
drawingPlaneDebug (Common) | Workspace variable | This variable is set to 0 whenever the drawing bitplane changes, but it is never read, so maybe this is part of some debug code that was left behind? |
DrawInventoryIcon (Bank 7) | Icon bar | Draw the inventory icon on top of the second button in the icon bar |
DrawLaunchBox (Bank 6) | Flight | Draw a box as part of the launch tunnel animation |
DrawLaunchBox_b6 (Bank 7) | Flight | Call the DrawLaunchBox routine in ROM bank 6 |
DrawLeftEarring (Bank 6) | Status | Draw an earring in the commander's left ear (i.e. on the right side of the commander image |
DrawLightning (Bank 6) | Flight | Draw a lightning effect for the launch tunnel and E.C.M. that consists of two random lightning bolts, one above the other |
DrawLightning_b6 (Bank 7) | Flight | Call the DrawLightning routine in ROM bank 6 |
DrawMedallion (Bank 6) | Status | Draw a medallion on the commander image |
DrawMessageInNMI (Bank 7) | Drawing the screen | Configure the NMI to send the portion of the screen that contains the in-flight message to the PPU (i.e. tile rows 22 to 24) |
DrawPitchRollBars (Bank 0) | Dashboard | Update the pitch and roll bars on the dashboard |
DrawRightEarring (Bank 6) | Status | Draw an earring in the commander's right ear (i.e. on the left side of the commander image |
DrawRowOfTiles (Bank 3) | Drawing the screen | Draw a row of tiles into the nametable buffer |
DrawSaveSlotMark (Bank 6) | Save and load | Draw a slot mark (a dash) next to a saved slot |
DrawScreenInNMI (Bank 0) | Drawing the screen | Configure the NMI handler to draw the screen |
DrawScreenInNMI_b0 (Bank 7) | Drawing the screen | Call the DrawScreenInNMI routine in ROM bank 0 |
DrawScrollFrame (Bank 6) | Combat demo | Draw one frame of the scroll text |
DrawScrollFrames (Bank 6) | Combat demo | Draw a scroll text over multiple frames |
DrawScrollInNMI (Bank 6) | Combat demo | Configure the NMI handler to draw the scroll text screen |
DrawScrollText (Bank 6) | Combat demo | Display a Star Wars scroll text |
DrawShipInBitplane (Bank 7) | Drawing ships | Flip the drawing bitplane and draw the current ship in the newly flipped bitplane |
DrawSmallBox (Bank 3) | Drawing the screen | Draw a small box, typically used for popups or outlines |
DrawSmallBox_b3 (Bank 7) | Drawing the screen | Call the DrawSmallBox routine in ROM bank 3 |
DrawSmallLogo (Bank 4) | Save and load | Set the sprite buffer entries for the small Elite logo on the Save and Load screen |
DrawSmallLogo_b4 (Bank 7) | Save and load | Call the DrawSmallLogo routine in ROM bank 4 |
DrawSpaceViewInNMI (Bank 0) | Drawing the screen | Configure the NMI handler to draw the space view |
DrawSpriteImage (Bank 6) | Drawing sprites | Draw an image out of sprites using patterns in sequential tiles in the pattern buffer |
DrawSpriteImage+2 (Bank 6) | Drawing sprites | Set the attributes for the sprites in the image to A |
DrawSpriteImage_b6 (Bank 7) | Drawing sprites | Call the DrawSpriteImage routine in ROM bank 6 |
DrawSunEdge (Bank 1) | Drawing suns | Draw a sun line from (X1, Y) to (X2, Y) |
DrawSunEdgeLeft (Bank 1) | Drawing suns | Draw a sun line in the tile on the left end of a sun row |
DrawSunEdgeRight (Bank 1) | Drawing suns | Draw a sun line in the tile on the right end of a sun row |
DrawSunRowOfBlocks (Bank 7) | Drawing suns | Draw a row of character blocks that contain sunlight, silhouetting any existing content against the sun |
DrawSystemImage (Bank 3) | Universe | Draw the system image as a coloured foreground in front of a greyscale background |
DrawSystemImage_b3 (Bank 7) | Universe | Call the DrawSystemImage routine in ROM bank 3 |
DrawTitleScreen (Bank 7) | Start and end | Draw a sequence of rotating ships on-screen while checking for button presses on the controllers |
DrawVerticalLine (Part 1 of 3) (Bank 7) | Drawing lines | Draw a vertical line from (X1, Y1) to (X1, Y2) |
DrawVerticalLine (Part 2 of 3) (Bank 7) | Drawing lines | Draw the top end or bottom end of the line |
DrawVerticalLine (Part 3 of 3) (Bank 7) | Drawing lines | Draw the middle portion of the line from full-height blocks |
DTEN (Bank 2) | Text | Print recursive token number X from the token table pointed to by (A V), used to print tokens from the RUTOK table via calls to DETOK3 |
DTS (Bank 2) | Text | Print a single letter in the correct case |
DTS_b2 (Bank 7) | Text | Call the DTS routine in ROM bank 2 |
DTW1 (Common) | Workspace variable | A mask for applying the lower case part of Sentence Case to extended text tokens |
DTW2 (Common) | Workspace variable | A flag that indicates whether we are currently printing a word |
DTW3 (Common) | Workspace variable | A flag for switching between standard and extended text tokens |
DTW4 (Common) | Workspace variable | Flags that govern how justified extended text tokens are printed |
DTW5 (Common) | Workspace variable | The size of the justified text buffer at BUF |
DTW6 (Common) | Workspace variable | A flag to denote whether printing in lower case is enabled for extended text tokens |
DTW8 (Common) | Workspace variable | A mask for capitalising the next letter in an extended text token |
dutyLoopEnvSQ1 (Common) | Workspace variable | The high nibble to use for SQ1_VOL, when setting the following for the SQ1 channel: |
dutyLoopEnvSQ2 (Common) | Workspace variable | The high nibble to use for SQ2_VOL, when setting the following for the SQ2 channel: |
DV41 (Bank 7) | Maths (Arithmetic) | Calculate (P R) = 256 * DELTA / A |
DV42 (Bank 7) | Maths (Arithmetic) | Calculate (P R) = 256 * DELTA / z_hi |
DVID3B2 (Bank 7) | Maths (Arithmetic) | Calculate K(3 2 1 0) = (A P+1 P) / (z_sign z_hi z_lo) |
DVID4 (Bank 7) | Maths (Arithmetic) | Calculate (P R) = 256 * A / Q |
DVIDT (Bank 1) | Maths (Arithmetic) | Calculate (P+1 A) = (A P) / Q |
E% (Bank 1) | Drawing ships | Ship blueprints default NEWB flags |
ECBLB2 (Bank 7) | Dashboard | Start up the E.C.M. (start the countdown and make the E.C.M. sound) |
ECHR (Common) | Text | Macro definition for characters in the extended token table |
ECM (Common) | Workspace variable | E.C.M. system |
ECMA (Common) | Workspace variable | The E.C.M. countdown timer, which determines whether an E.C.M. system is currently operating: |
ECMOF (Bank 0) | Dashboard | Switch off the E.C.M. and turn off the dashboard bulb |
ECMP (Common) | Workspace variable | Our E.C.M. status |
EDGE (Common) | Drawing ships | Macro definition for adding edges to ship blueprints |
EDGES (Bank 1) | Drawing lines | Draw a horizontal line given a centre and a half-width |
EDGES-2 (Bank 1) | Drawing lines | Return the C flag set if argument A is 0 |
EE51 (Bank 1) | Drawing ships | Remove the current ship from the screen, called from SHPPT before drawing the ship as a point |
effectOnNOISE (Common) | Workspace variable | Records whether a sound effect is being made on the NOISE channel |
effectOnSQ1 (Common) | Workspace variable | Records whether a sound effect is being made on the SQ1 channel |
effectOnSQ2 (Common) | Workspace variable | Records whether a sound effect is being made on the SQ2 channel |
EJMP (Common) | Text | Macro definition for jump tokens in the extended token table |
enableBitplanes (Common) | Workspace variable | A flag to control whether two different bitplanes are implemented when drawing the screen, so smooth vector graphics can be shown |
EnableSound (Bank 6) | Sound | Enable sounds (music and sound effects) |
enableSound (Common) | Workspace variable | Controls sound effects and music in David Whittaker's sound module |
EnableSoundS (Bank 6) | Sound | A jump table entry at the start of bank 6 for the EnableSound routine |
ENERGY (Common) | Workspace variable | Energy bank status |
ENGY (Common) | Workspace variable | Energy unit |
eq (Bank 0) | Equipment | Subtract the price of equipment from the cash pot |
EQSHP (Bank 0) | Equipment | Show the Equip Ship screen |
equi1 (Bank 0) | Equipment | A re-entry point into the key-pressing loop, used when processing key presses in subroutines |
equipSprites (Bank 6) | Equipment | Sprite configuration data for the sprites that show the equipment fitted to our Cobra Mk III on the Equip Ship screen |
ERND (Common) | Text | Macro definition for random tokens in the extended token table |
ESCAPE (Bank 0) | Flight | Launch our escape pod |
ESCP (Common) | Workspace variable | Escape pod |
ETOK (Common) | Text | Macro definition for recursive tokens in the extended token table |
ETWO (Common) | Text | Macro definition for two-letter tokens in the extended token table |
EV (Common) | Workspace variable | The "extra vessels" spawning counter |
ex (Bank 2) | Text | Print a recursive token |
ex_b2 (Bank 7) | Text | Call the ex routine in ROM bank 2 |
EXNO (Bank 0) | Sound | Make the sound of a laser strike on another ship |
EXNO2 (Bank 0) | Status | Process us making a kill |
EXNO3 (Bank 7) | Sound | Make an explosion sound |
explosionSounds (Bank 0) | Sound | Sound numbers for explosions at different distances from our ship |
EXS1 (Bank 1) | Drawing ships | Set (A X) = (A R) +/- random * cloud size |
extendedTokensHi (Bank 6) | Text | High byte of the extended text token table for each language |
extendedTokensLo (Bank 6) | Text | Low byte of the extended text token table for each language |
FACE (Common) | Drawing ships | Macro definition for adding faces to ship blueprints |
faceCount (Bank 4) | Status | The number of commander face images in the faceOffset table |
faceImage0 (Bank 4) | Status | Packed image data for commander face image 0 |
faceImage1 (Bank 4) | Status | Packed image data for commander face image 1 |
faceImage10 (Bank 4) | Status | Packed image data for commander face image 10 |
faceImage11 (Bank 4) | Status | Packed image data for commander face image 11 |
faceImage12 (Bank 4) | Status | Packed image data for commander face image 12 |
faceImage13 (Bank 4) | Status | Packed image data for commander face image 13 |
faceImage2 (Bank 4) | Status | Packed image data for commander face image 2 |
faceImage3 (Bank 4) | Status | Packed image data for commander face image 3 |
faceImage4 (Bank 4) | Status | Packed image data for commander face image 4 |
faceImage5 (Bank 4) | Status | Packed image data for commander face image 5 |
faceImage6 (Bank 4) | Status | Packed image data for commander face image 6 |
faceImage7 (Bank 4) | Status | Packed image data for commander face image 7 |
faceImage8 (Bank 4) | Status | Packed image data for commander face image 8 |
faceImage9 (Bank 4) | Status | Packed image data for commander face image 9 |
faceOffset (Bank 4) | Status | Offset to the data for each of the 14 commander face images |
FadeAndHideSprites (Bank 7) | Drawing sprites | Fade the screen to black and hide all sprites |
FadeColours (Bank 3) | Drawing the screen | Fade the screen colours towards black |
fadeColours (Bank 3) | Drawing the screen | Lookup table that converts a NES colour to the same colour but with a smaller brightness value |
FadeColoursTwice (Bank 3) | Drawing the screen | Fade the screen colours towards black twice |
FadeToBlack (Bank 3) | Drawing the screen | Fade the screen to black over the next four VBlanks |
FadeToBlack_b3 (Bank 7) | Drawing the screen | Call the FadeToBlack routine in ROM bank 3 |
FadeToColour (Bank 3) | Drawing the screen | Reverse-fade the screen from black to full colour over the next four VBlanks |
FadeToColour_b3 (Bank 7) | Drawing the screen | Call the FadeToColour routine in ROM bank 3 |
FAROF (Bank 0) | Maths (Geometry) | Compare x_hi, y_hi and z_hi with 224 |
FAROF2 (Bank 7) | Maths (Geometry) | Compare x_hi, y_hi and z_hi with A |
FastForwardJump (Bank 0) | Flight | Perform an in-system jump |
fbar11 (Bank 3) | Icon bar | Process the fast-forward and Market Price buttons |
fbar8 (Bank 3) | Icon bar | Process the escape pod, fast-forward and Market Price buttons |
FILEPR (Bank 2) | Save and load | Display the currently selected media (disk or tape) |
FILL_MEMORY (Common) | Drawing the screen | Fill memory with the specified number of bytes |
FillMemory (Bank 7) | Utility routines | Fill a block of memory with a specified value |
FillMemory32Bytes (Bank 7) | Utility routines | Fill a 32-byte block of memory with a specified value |
firstBox (Common) | Workspace variable | Used to detect the first iteration of the box-drawing loop when drawing the launch tunnel |
firstFreePattern (Common) | Workspace variable | Contains the number of the first free pattern in the pattern buffer that we can draw into next (or 0 if there are no free patterns) |
firstNameTile (Common) | Workspace variable | The number of the first tile for which we send nametable data to the PPU in the NMI handler (potentially for both bitplanes, if both are configured to be sent) |
firstPattern (Common) | Workspace variable | The number of the first pattern for which we send data to the PPU in the NMI handler (potentially for both bitplanes, if both are configured to be sent) |
FIST (Common) | Workspace variable | Our legal status (FIST stands for "fugitive/innocent status"): |
FixRandomNumbers (Bank 7) | Combat demo | Fix the random number seeds to a known value so the random numbers generated are always the same when we run the demo |
FLAG (Common) | Workspace variable | A flag that's used to define whether this is the first call to the ball line routine in BLINE, so it knows whether to wait for the second call before storing segment data in the ball line heap |
flagsForClearing (Bank 7) | Drawing the screen | A bitplane mask to control how bitplane buffer clearing works in the ClearPlaneBuffers routine |
FlightLoop4To16 (Bank 0) | Main loop | Display in-flight messages, call parts 4 to 12 of the main flight loop for each slot, and fall through into parts 13 to 16 |
FLIP (Bank 0) | Stardust | Reflect the stardust particles in the screen diagonal |
FlipDrawingPlane (Bank 7) | Drawing the screen | Flip the drawing bitplane |
FlushSoundChannel (Bank 7) | Sound | Flush a specific sound channel |
FlushSoundChannels (Bank 7) | Sound | Flush the SQ1, SQ2 and NOISE sound channels |
FlushSpecificSound (Bank 7) | Sound | Flush the channels used by a specific sound |
FlushSQ2AndNOISE (Bank 7) | Sound | Flush the SQ2 and NOISE sound channels |
FMLTU (Bank 7) | Maths (Arithmetic) | Calculate A = A * Q / 256 |
FMLTU2 (Bank 7) | Maths (Arithmetic) | Calculate A = K * sin(A) |
fontImage (Bank 7) | Text | Image data for the text font |
fontStyle (Common) | Workspace variable | The font style to use when printing text: |
fq1 (Bank 0) | Tactics | Used to add a cargo canister to the universe |
FR1 (Bank 0) | Tactics | Display the "missile jammed" message |
FR1-2 (Bank 0) | Tactics | Clear the C flag and return from the subroutine |
FRCE (Bank 0) | Main loop | The entry point for the main game loop if we want to jump straight to a specific screen, by pretending to "press" a key, in which case A contains the internal key number of the key we want to "press" |
FRIN (Common) | Workspace variable | Slots for the ships in the local bubble of universe |
FRMIS (Bank 0) | Tactics | Fire a missile from our ship |
FRS1 (Bank 0) | Tactics | Launch a ship straight ahead of us, below the laser sights |
FSH (Common) | Workspace variable | Forward shield status |
fwl (Bank 0) | Status | Print fuel and cash levels |
fwls (Bank 0) | Text | Print fuel and cash levels |
GalacticHyperdrive (Bank 0) | Flight | If we are in space and the countdown has ended, activate the galactic hyperdrive |
galaxySeeds (Bank 6) | Save and load | The galaxy seeds to add to a commander save file |
GC2 (Bank 0) | Maths (Arithmetic) | Calculate (Y X) = (A P) * 4 |
GCNT (Common) | Workspace variable | The number of the current galaxy (0-7) |
GetCmdrImage (Bank 4) | Status | Fetch the headshot image for the commander and store it in the pattern buffers, and send the face and glasses images to the PPU |
GetCmdrImage_b4 (Bank 7) | Status | Call the GetCmdrImage routine in ROM bank 4 |
GetDefaultNEWB (Bank 7) | Drawing ships | Fetch the default NEWB flags for a specified ship type |
GetHeadshot (Bank 4) | Status | Fetch the headshot image for the commander and store it in the pattern buffers, starting at pattern number picturePattern |
GetHeadshot_b4 (Bank 7) | Status | Call the GetHeadshot routine in ROM bank 4 |
GetHeadshotType (Bank 4) | Status | Get the correct headshot number for the current combat rank and status condition |
GetHeadshotType_b4 (Bank 7) | Status | Call the GetHeadshotType routine in ROM bank 4 |
GetLaserPattern (Bank 6) | Equipment | Get the pattern number for a specific laser's equipment sprite |
GetNameAddress (Bank 3) | Drawing the screen | Get the addresses in the nametable buffers for a given tile |
GetRowNameAddress (Bank 7) | Drawing the screen | Get the addresses in the nametable buffers for the start of a given character row |
GetSaveAddresses (Bank 6) | Save and load | Fetch the addresses of the three saved parts for a specific save slot |
GetScrollDivisions (Bank 6) | Combat demo | Set up the division calculations for the scroll text |
GetShipBlueprint (Bank 7) | Drawing ships | Fetch a specified byte from the current ship blueprint |
GetStatusCondition (Bank 7) | Status | Calculate our ship's status condition |
GetSystemBack (Bank 5) | Universe | Fetch the background image for the current system and store it in the pattern buffers |
GetSystemBack_b5 (Bank 7) | Universe | Call the GetSystemBack routine in ROM bank 5 |
GetSystemImage (Bank 5) | Universe | Fetch the background image and foreground sprite for the current system image and send them to the pattern buffers and PPU |
GetSystemImage_b5 (Bank 7) | Universe | Call the GetSystemImage routine in ROM bank 5 |
GetViewPalettes (Bank 3) | Drawing the screen | Get the palette for the view type in QQ11a and store it in a table at XX3 |
Ghy (Bank 0) | Flight | Perform a galactic hyperspace jump |
GHYP (Common) | Workspace variable | Galactic hyperdrive |
GINF (Bank 7) | Universe | Fetch the address of a ship's data block into INF |
glassesImage (Bank 4) | Status | Packed image data for the glasses, earrings and medallion that the commander can wear |
GNTMP (Common) | Workspace variable | Laser temperature (or "gun temperature") |
GOIN (Bank 0) | Main loop | We jump here from part 3 of the main flight loop if the docking computer is activated by pressing "C" |
GOPL (Bank 0) | Tactics | Make the ship head towards the planet |
gov (Common) | Workspace variable | The current system's government type (0-7) |
GRIDSET (Bank 6) | Combat demo | Populate the line coordinate tables with the pixel lines for one 21-character line of scroll text |
GRIDSET+5 (Bank 6) | Combat demo | Use the y-coordinate in YP so the scroll text starts at (0, YP) rather than (0, 6) |
GRS1 (Bank 6) | Combat demo | Populate the line coordinate tables with the lines for a single scroll text character |
GTHG (Bank 0) | Universe | Spawn a Thargoid ship and a Thargon companion |
GTHG+15 (Bank 0) | Universe | Spawn a lone Thargoid, without a Thargon companion and with slightly less aggression than normal |
GVL (Bank 0) | Universe | Calculate the availability of market items |
HAL3 (Bank 1) | Ship hangar | Draw a hangar background line from left to right, stopping when it bumps into existing on-screen content |
halfScreenHeight (Common) | Workspace variable | Half the height of the drawable part of the screen in pixels (can be 72, 77 or 104 pixels) |
HALL (Bank 1) | Ship hangar | Draw the ships in the ship hangar, then draw the hangar |
HALL_b1 (Bank 7) | Ship hangar | Call the HALL routine in ROM bank 1 |
HANGER (Bank 1) | Ship hangar | Display the ship hangar |
HANGFLAG (Common) | Workspace variable | The number of ships being displayed in the ship hangar |
HAS1 (Bank 1) | Ship hangar | Draw a ship in the ship hangar |
HAS3 (Bank 1) | Ship hangar | Draw a hangar background line from right to left |
HATB (Bank 1) | Ship hangar | Ship hangar group table |
headCount (Bank 4) | Status | The number of commander headshot images in the headOffset table |
headImage0 (Bank 4) | Status | Packed image data for commander headshot image 0 |
headImage1 (Bank 4) | Status | Packed image data for commander headshot image 1 |
headImage10 (Bank 4) | Status | Packed image data for commander headshot image 10 |
headImage11 (Bank 4) | Status | Packed image data for commander headshot image 11 |
headImage12 (Bank 4) | Status | Packed image data for commander headshot image 12 |
headImage13 (Bank 4) | Status | Packed image data for commander headshot image 13 |
headImage2 (Bank 4) | Status | Packed image data for commander headshot image 2 |
headImage3 (Bank 4) | Status | Packed image data for commander headshot image 3 |
headImage4 (Bank 4) | Status | Packed image data for commander headshot image 4 |
headImage5 (Bank 4) | Status | Packed image data for commander headshot image 5 |
headImage6 (Bank 4) | Status | Packed image data for commander headshot image 6 |
headImage7 (Bank 4) | Status | Packed image data for commander headshot image 7 |
headImage8 (Bank 4) | Status | Packed image data for commander headshot image 8 |
headImage9 (Bank 4) | Status | Packed image data for commander headshot image 9 |
headOffset (Bank 4) | Status | Offset to the data for each of the 14 commander headshot images |
headShotsByRank (Bank 4) | Status | Lookup table for headshots by rank and status condition |
HFX (Common) | Workspace variable | This flag is unused in this version of Elite. In the other versions, setting HFX to a non-zero value makes the hyperspace rings multi-coloured, but the NES has a different hyperspace effect, so this variable is not used |
HI1 (Bank 0) | Tactics | Contains an RTS |
hiddenBitplane (Common) | Workspace variable | The bitplane that is currently hidden from view in the space view |
hiddenColour (Common) | Workspace variable | Contains the colour to use for pixels that are hidden in palette 0, e.g. $0F for black |
HideCrosshairs (Bank 0) | Charts | Hide the moveable crosshairs (i.e. the square reticle) |
HideExplosionBurst (Bank 7) | Drawing ships | Hide the four sprites that make up the explosion burst that flashes up when a ship explodes |
HideFromScanner (Bank 1) | Dashboard | Hide the current ship from the scanner |
HideFromScanner_b1 (Bank 7) | Dashboard | Call the HideFromScanner routine in ROM bank 1 |
HideHiddenColour (Bank 0) | Drawing the screen | Set the hidden colour to black, so that pixels in this colour in palette 0 are invisible |
HideIconBar (Bank 3) | Icon bar | Remove the icon bar from the screen by replacing it with background tiles |
HideIconBarPointer (Bank 7) | Icon bar | Clear the icon bar choice and hide the icon bar pointer |
HideMoreSprites (Bank 7) | Drawing sprites | Hide X + 1 sprites from sprite Y / 4 onwards |
HideMostSprites (Bank 7) | Drawing sprites | Hide all sprites except for sprite 0 and the icon bar pointer |
HideShip (Bank 1) | Dashboard | Update the current ship so it is no longer shown on the scanner |
HideShip_b1 (Bank 7) | Dashboard | Update the current ship so it is no longer shown on the scanner |
HideSightSprites (Bank 3) | Flight | Hide the sprites for the laser sights in the space view |
HideSprites (Bank 7) | Drawing sprites | Hide X sprites from sprite Y / 4 onwards |
HideStardust (Bank 7) | Stardust | Hide the stardust sprites |
HighlightEquipment (Bank 0) | Equipment | Highlight an item of equipment on the Equip Ship screen |
HighlightLaserView (Bank 0) | Equipment | Highlight the laser view name in the popup menu |
HighlightSaleItem (Bank 0) | Market | Highlight the name, price and availability of a market item on the correct row for the chosen language |
HighlightSaveName (Bank 6) | Save and load | Highlight the name of a specific save slot |
hipo2 (Bank 7) | Icon bar | Clear the icon button choice and hide the icon bar pointer |
HITCH (Bank 0) | Tactics | Work out if the ship in INWK is in our crosshairs |
HLOIN (Part 1 of 5) (Bank 7) | Drawing lines | Draw a horizontal line from (X1, Y) to (X2, Y) using EOR logic |
HLOIN (Part 2 of 5) (Bank 7) | Drawing lines | Draw the left end of the line |
HLOIN (Part 3 of 5) (Bank 7) | Drawing lines | Draw the middle part of the line |
HLOIN (Part 4 of 5) (Bank 7) | Drawing lines | Draw the right end of the line |
HLOIN (Part 5 of 5) (Bank 7) | Drawing lines | Draw the line when it's all within one character block |
HME2 (Bank 0) | Charts | Search the galaxy for a system |
hy5 (Bank 0) | Universe | Contains an RTS |
hyp (Bank 0) | Flight | Start the hyperspace process |
hyp1 (Bank 0) | Universe | Process a jump to the system closest to (QQ9, QQ10) |
hyp1+3 (Bank 0) | Universe | Jump straight to the system at (QQ9, QQ10) without first calculating which system is closest. We do this if we already know that (QQ9, QQ10) points to a system |
hyperspaceColour (Bank 6) | Flight | The different colours that can be used for the hyperspace effect |
hyR (Bank 0) | Universe | Contains an RTS |
iconBarButtons (Bank 7) | Icon bar | A list of button numbers for each icon bar type |
iconBarChoice (Common) | Workspace variable | The number of the icon bar button that's just been selected |
iconBarImage0 (Bank 3) | Icon bar | Image data for icon bar 0 (Docked) |
iconBarImage1 (Bank 3) | Icon bar | Image data for icon bar 1 (Flight) |
iconBarImage2 (Bank 3) | Icon bar | Image data for icon bar 2 (Charts) |
iconBarImage3 (Bank 3) | Icon bar | Image data for icon bar 3 (Pause) |
iconBarImage4 (Bank 3) | Icon bar | Image data for icon bar 4 (Title screen copyright message) |
iconBarImageHi (Common) | Workspace variable | Contains the high byte of the address of the image data for the current icon bar, i.e. HI(iconBarImage0) through to HI(iconBarImage4) |
iconBarKeyPress (Common) | Workspace variable | The button number of an icon bar button if an icon bar button has been chosen |
iconBarRow (Common) | Workspace variable | The row on which the icon bar appears |
iconBarType (Common) | Workspace variable | The type of the current icon bar: |
imageSentToPPU (Common) | Workspace variable | Records when images have been sent to the PPU or unpacked into the buffers, so we don't repeat the process unnecessarily |
IncreaseJoystick (Bank 7) | Controllers | Increase a joystick value by a specific amount, jumping straight to the indicator centre if we increase from the left-hand side |
IncreaseTally (Bank 7) | Status | Add the kill count to the fractional and low bytes of our combat rank tally following a kill |
iNES header (iNES header) | Start and end | The iNES header for running in an emulator |
INF (Common) | Workspace variable | Temporary storage, typically used for storing the address of a ship's data block, so it can be copied to and from the internal workspace at INWK |
InputName (Bank 6) | Controllers | Get a name from the controller for searching the galaxy or changing commander name |
InputName_b6 (Bank 7) | Controllers | Call the InputName routine in ROM bank 6 |
inputNameSize (Common) | Workspace variable | The maximum size of the name to be fetched by the InputName routine |
InSystemJump (Bank 0) | Flight | Perform an in-system (fast-forward) jump |
Interrupts_b0 (Bank 0) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
Interrupts_b1 (Bank 1) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
Interrupts_b2 (Bank 2) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
Interrupts_b3 (Bank 3) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
Interrupts_b4 (Bank 4) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
Interrupts_b5 (Bank 5) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
Interrupts_b6 (Bank 6) | Start and end | The IRQ and NMI handler while the MMC1 mapper reset routine is still running |
inventoryIcon (Bank 3) | Equipment | Image data for the inventory icon shown on the icon bar in the Market Price screen |
INWK (Common) | Workspace variable | The zero-page internal workspace for the current ship data block |
IRQ (Bank 7) | Utility routines | Handle IRQ interrupts by doing nothing |
ITEM (Common) | Market | Macro definition for the market prices table |
JAMESON (Bank 6) | Save and load | Copy the default "JAMESON" commander to the buffer at currentSlot |
JAMESON_b6 (Bank 7) | Save and load | Call the JAMESON routine in ROM bank 6 |
jmp (Bank 0) | Universe | Set the current system to the selected system |
JMTB (Bank 2) | Text | The extended token table for jump tokens 1-32 (DETOK) |
joystickDelta (Common) | Workspace variable | Used to store the amount to change the pitch and roll rates when converting controller button presses into joystick values |
JSTGY (Common) | Workspace variable | Reverse controller y-axis configuration setting |
JSTX (Common) | Workspace variable | Our current roll rate |
JSTY (Common) | Workspace variable | Our current pitch rate |
JUNK (Common) | Workspace variable | The amount of junk in the local bubble |
K (Common) | Workspace variable | Temporary storage, used in a number of places |
K% (Common) | Workspaces | Ship data blocks |
K2 (Common) | Workspace variable | Temporary storage, used in a number of places |
K3 (Common) | Workspace variable | Temporary storage, used in a number of places |
K4 (Common) | Workspace variable | Temporary storage, used in a number of places |
K5 (Common) | Workspace variable | Temporary storage used to store segment coordinates across successive calls to BLINE, the ball line routine |
K6 (Common) | Workspace variable | Temporary storage, typically used for storing coordinates during vector calculations |
KILLSHP (Bank 0) | Universe | Remove a ship from our local bubble of universe |
KL (Common) | Workspace variable | The following bytes implement a key logger that gets updated according to the controller button presses |
KS1 (Bank 0) | Universe | Remove the current ship from our local bubble of universe |
KS2 (Bank 0) | Universe | Check the local bubble for missiles with target lock |
KS3 (Bank 0) | Universe | Contains an RTS |
KS4 (Bank 0) | Universe | Remove the space station and replace it with the sun |
KWH% (Bank 1) | Status | Integer number of kills awarded for destroying each type of ship |
KWL% (Bank 1) | Status | Fractional number of kills awarded for destroying each type of ship |
KY1 (Common) | Workspace variable | One pilot is configured and the down and B buttons are both being pressed on controller 1 |
KY2 (Common) | Workspace variable | One pilot is configured and the up and B buttons are both being pressed on controller 1 |
KY3 (Common) | Workspace variable | One pilot is configured and the left button is being pressed on controller 1 (and the B button is not being pressed) |
KY4 (Common) | Workspace variable | One pilot is configured and the right button is being pressed on controller 1 (and the B button is not being pressed) |
KY5 (Common) | Workspace variable | One pilot is configured and the down button is being pressed on controller 1 (and the B button is not being pressed) |
KY6 (Common) | Workspace variable | One pilot is configured and the up button is being pressed on controller 1 (and the B button is not being pressed) |
KY7 (Common) | Workspace variable | The A button is being pressed on controller 1 (fire lasers) |
languageIndex (Common) | Workspace variable | The language that was chosen on the Start screen as an index into the various lookup tables: |
languageIndexes (Bank 6) | Text | The index of the chosen language for looking up values from language-indexed tables |
languageLength (Bank 6) | Text | The length of each language name |
languageNumber (Common) | Workspace variable | The language that was chosen on the Start screen as a number: |
languageNumbers (Bank 6) | Text | The language number for each language, as a set bit within a flag byte |
LAS (Common) | Workspace variable | Contains the laser power of the laser fitted to the current space view (or 0 if there is no laser fitted to the current view) |
LAS2 (Common) | Workspace variable | Laser power for the current laser |
LASCT (Common) | Workspace variable | The laser pulse count for the current laser |
LASER (Common) | Workspace variable | The specifications of the lasers fitted to each of the four space views: |
LASLI (Bank 0) | Drawing lines | Draw the laser lines for when we fire our lasers |
LASLI-1 (Bank 0) | Drawing lines | Contains an RTS |
lastNameTile (Common) | Workspace variable | The number of the last nametable buffer entry to send to the PPU nametable table in the NMI handler for bitplane 0, divided by 8 |
lastPattern (Common) | Workspace variable | The number of the last pattern entry to send from pattern buffer 0 to bitplane 0 of the PPU pattern table in the NMI handler |
lastToSend (Common) | Workspace variable | The last tile or pattern number to send to the PPU, potentially potentially overwritten by the flags |
LASX (Common) | Workspace variable | The x-coordinate of the tip of the laser line |
LASY (Common) | Workspace variable | The y-coordinate of the tip of the laser line |
LAUN (Bank 0) | Flight | Make the launch sound and draw the launch tunnel |
LCASH (Bank 0) | Maths (Arithmetic) | Subtract an amount of cash from the cash pot |
lineImage (Bank 7) | Drawing lines | Image data for the horizontal line, vertical line and block images |
LL10-1 (Bank 1) | Drawing ships | Contains an RTS |
LL118 (Bank 1) | Drawing lines | Move a point along a line until it is on-screen |
LL118-1 (Bank 1) | Drawing lines | Contains an RTS |
LL120 (Bank 1) | Maths (Arithmetic) | Calculate (Y X) = (S x1_lo) * XX12+2 or (S x1_lo) / XX12+2 |
LL121 (Bank 1) | Maths (Arithmetic) | Calculate (Y X) = (S R) / Q and set the sign to the opposite of the top byte on the stack |
LL122 (Bank 1) | Maths (Arithmetic) | Calculate (Y X) = (S R) * Q and set the sign to the opposite of the top byte on the stack |
LL123 (Bank 1) | Maths (Arithmetic) | Calculate (Y X) = (S R) / XX12+2 or (S R) * XX12+2 |
LL128 (Bank 1) | Maths (Arithmetic) | Contains an RTS |
LL129 (Bank 1) | Maths (Arithmetic) | Calculate Q = XX12+2, A = S EOR XX12+3 and (S R) = |S R| |
LL133 (Bank 1) | Maths (Arithmetic) | Negate (Y X) and return from the subroutine LL128 Contains an RTS |
LL145 (Part 1 of 4) (Bank 1) | Drawing lines | Clip line: Work out which end-points are on-screen, if any |
LL145 (Part 2 of 4) (Bank 1) | Drawing lines | Clip line: Work out if any part of the line is on-screen |
LL145 (Part 3 of 4) (Bank 1) | Drawing lines | Clip line: Calculate the line's gradient |
LL145 (Part 4 of 4) (Bank 1) | Drawing lines | Clip line: Call the routine in LL188 to do the actual clipping |
LL164 (Bank 6) | Flight | Make the hyperspace sound and draw the hyperspace tunnel |
LL164_b6 (Bank 7) | Flight | Call the LL164 routine in ROM bank 6 |
LL28 (Bank 7) | Maths (Arithmetic) | Calculate R = 256 * A / Q |
LL28+4 (Bank 7) | Maths (Arithmetic) | Skips the A >= Q check and always returns with C flag cleared, so this can be called if we know the division will work |
LL38 (Bank 1) | Maths (Arithmetic) | Calculate (S A) = (S R) + (A Q) |
LL5 (Bank 7) | Maths (Arithmetic) | Calculate Q = SQRT(R Q) |
LL51 (Bank 1) | Maths (Geometry) | Calculate the dot product of XX15 and XX16 |
LL61 (Bank 1) | Maths (Arithmetic) | Calculate (U R) = 256 * A / Q |
LL62 (Bank 1) | Maths (Arithmetic) | Calculate 128 - (U R) |
LL66 (Bank 1) | Drawing ships | A re-entry point into the ship-drawing routine, used by the LL62 routine to store 128 - (U R) on the XX3 heap |
LL70+1 (Bank 1) | Drawing ships | Contains an RTS (as the first byte of an LDA instruction) |
LL9 (Part 1 of 12) (Bank 1) | Drawing ships | Draw ship: Check if ship is exploding, check if ship is in front |
LL9 (Part 2 of 12) (Bank 1) | Drawing ships | Draw ship: Check if ship is in field of view, close enough to draw |
LL9 (Part 3 of 12) (Bank 1) | Drawing ships | Draw ship: Set up orientation vector, ship coordinate variables |
LL9 (Part 4 of 12) (Bank 1) | Drawing ships | Draw ship: Set visibility for exploding ship (all faces visible) |
LL9 (Part 5 of 12) (Bank 1) | Drawing ships | Draw ship: Calculate the visibility of each of the ship's faces |
LL9 (Part 6 of 12) (Bank 1) | Drawing ships | Draw ship: Calculate the visibility of each of the ship's vertices |
LL9 (Part 7 of 12) (Bank 1) | Drawing ships | Draw ship: Calculate the visibility of each of the ship's vertices |
LL9 (Part 8 of 12) (Bank 1) | Drawing ships | Draw ship: Calculate the screen coordinates of visible vertices |
LL9 (Part 9 of 12) (Bank 1) | Drawing ships | Draw ship: Draw laser beams if the ship is firing its laser at us |
LL9 (Part 10 of 12) (Bank 1) | Drawing ships | Draw ship: Calculate the visibility of each of the ship's edges |
LL9 (Part 11 of 12) (Bank 1) | Drawing ships | Draw ship: Loop back for the next edge |
LL9 (Part 12 of 12) (Bank 1) | Drawing ships | Does nothing in the NES version |
LL9_b1 (Bank 7) | Drawing ships | Call the LL9 routine in ROM bank 1 |
LO2 (Bank 0) | Flight | Contains an RTS |
LoadHighFont (Bank 3) | Text | Load the highlight font into the pattern buffer from pattern 161 to 255 |
LoadHighFont_b3 (Bank 7) | Text | Call the LoadHighFont routine in ROM bank 3 |
LoadNormalFont (Bank 3) | Text | Load the normal font into the pattern buffer from pattern 66 to 160 |
LoadNormalFont_b3 (Bank 7) | Text | Call the LoadNormalFont routine in ROM bank 3 |
log (Bank 7) | Maths (Arithmetic) | Binary logarithm table (high byte) |
logL (Bank 7) | Maths (Arithmetic) | Binary logarithm table (low byte) |
logoBallImage (Bank 3) | Start and end | Packed image data for the ball at the bottom of the big Elite logo shown on the Start screen |
LOIN (Part 1 of 7) (Bank 7) | Drawing lines | Draw a line: Calculate the line gradient in the form of deltas |
LOIN (Part 2 of 7) (Bank 7) | Drawing lines | Draw a line: Line has a shallow gradient, step right along x-axis |
LOIN (Part 3 of 7) (Bank 7) | Drawing lines | Draw a shallow line going right and up or left and down |
LOIN (Part 4 of 7) (Bank 7) | Drawing lines | Draw a shallow line going right and down or left and up |
LOIN (Part 5 of 7) (Bank 7) | Drawing lines | Draw a line: Line has a steep gradient, step up along y-axis |
LOIN (Part 6 of 7) (Bank 7) | Drawing lines | Draw a steep line going up and left or down and right |
LOIN (Part 7 of 7) (Bank 7) | Drawing lines | Draw a steep line going up and right or down and left |
LOOK1 (Bank 0) | Flight | Initialise the space view |
lowerCase (Bank 2) | Text | Lookup table for converting ASCII characters to lower case characters in the game's text font |
LTDEF (Bank 6) | Combat demo | Line definitions for characters in the Star Wars scroll text |
m (Bank 0) | Maths (Geometry) | Do not include A in the calculation |
M% (Bank 0) | Main loop | The entry point for the main flight loop |
MA18 (Bank 0) | Main loop | Entry point for part 13 of the main flight loop |
MA232 (Bank 0) | Flight | Contains an RTS |
MA9 (Bank 0) | Maths (Geometry) | Contains an RTS |
MAD (Bank 7) | Maths (Arithmetic) | Calculate (A X) = Q * A + (S R) |
Main flight loop (Part 1 of 16) (Bank 0) | Main loop | Seed the random number generator |
Main flight loop (Part 2 of 16) (Bank 0) | Main loop | Calculate the alpha and beta angles from the current pitch and roll of our ship |
Main flight loop (Part 3 of 16) (Bank 0) | Main loop | Scan for flight keys and process the results |
Main flight loop (Part 4 of 16) (Bank 0) | Main loop | For each nearby ship: Copy the ship's data block from K% to the zero-page workspace at INWK |
Main flight loop (Part 5 of 16) (Bank 0) | Main loop | For each nearby ship: If an energy bomb has been set off, potentially kill this ship |
Main flight loop (Part 6 of 16) (Bank 0) | Main loop | For each nearby ship: Move the ship in space and copy the updated INWK data block back to K% |
Main flight loop (Part 7 of 16) (Bank 0) | Main loop | For each nearby ship: Check whether we are docking, scooping or colliding with it |
Main flight loop (Part 8 of 16) (Bank 0) | Main loop | For each nearby ship: Process us potentially scooping this item |
Main flight loop (Part 9 of 16) (Bank 0) | Main loop | For each nearby ship: If it is a space station, check whether we are successfully docking with it |
Main flight loop (Part 10 of 16) (Bank 0) | Main loop | For each nearby ship: Remove if scooped, or process collisions |
Main flight loop (Part 11 of 16) (Bank 0) | Main loop | For each nearby ship: Process missile lock and firing our laser |
Main flight loop (Part 12 of 16) (Bank 0) | Main loop | For each nearby ship: Draw the ship, remove if killed, loop back |
Main flight loop (Part 13 of 16) (Bank 0) | Main loop | Show energy bomb effect, charge shields and energy banks |
Main flight loop (Part 14 of 16) (Bank 0) | Main loop | Spawn a space station if we are close enough to the planet |
Main flight loop (Part 15 of 16) (Bank 0) | Main loop | Perform altitude checks with the planet and sun and process fuel scooping if appropriate |
Main flight loop (Part 16 of 16) (Bank 0) | Main loop | Call stardust routine |
Main game loop (Part 1 of 6) (Bank 0) | Main loop | Spawn a trader (a Cobra Mk III, Python, Boa or Anaconda) |
Main game loop (Part 2 of 6) (Bank 0) | Main loop | Call the main flight loop, and potentially spawn a trader, an asteroid, or a cargo canister |
Main game loop (Part 3 of 6) (Bank 0) | Main loop | Potentially spawn a cop, particularly if we've been bad |
Main game loop (Part 4 of 6) (Bank 0) | Main loop | Potentially spawn a lone bounty hunter, a Thargoid, or up to four pirates |
Main game loop (Part 5 of 6) (Bank 0) | Main loop | Cool down lasers, make calls to update the dashboard |
Main game loop (Part 6 of 6) (Bank 0) | Main loop | Process non-flight key presses (icon bar selections) |
MakeHyperSound (Bank 7) | Sound | Make the hyperspace sound |
MakeMusic (Bank 6) | Sound | Play the current music on the SQ1, SQ2, TRI and NOISE channels |
MakeMusicOnNOISE (Bank 6) | Sound | Play the current music on the NOISE channel |
MakeMusicOnSQ1 (Bank 6) | Sound | Play the current music on the SQ1 channel |
MakeMusicOnSQ2 (Bank 6) | Sound | Play the current music on the SQ2 channel |
MakeMusicOnTRI (Bank 6) | Sound | Play the current music on the TRI channel |
MakeScoopSound (Bank 7) | Sound | Make the sound of the fuel scoops working |
MakeSound (Bank 6) | Sound | Make the current sound effects on the SQ1, SQ2 and NOISE channels |
MakeSoundOnNOISE (Bank 6) | Sound | Make the current sound effect on the NOISE channel |
MakeSoundOnSQ1 (Bank 6) | Sound | Make the current sound effect on the SQ1 channel |
MakeSoundOnSQ2 (Bank 6) | Sound | Make the current sound effect on the SQ2 channel |
MakeSounds (Bank 6) | Sound | Make the current sounds (music and sound effects) |
MakeSounds_b6 (Bank 7) | Sound | Call the MakeSounds routine in ROM bank 6 |
MakeSoundsAtVBlank (Bank 7) | Sound | Wait for the next VBlank and make the current sounds (music and sound effects) |
MakeSoundsS (Bank 6) | Sound | A jump table entry at the start of bank 6 for the MakeSounds routine |
MAL1 (Bank 0) | Main loop | Marks the beginning of the ship analysis loop, so we can jump back here from part 12 of the main flight loop to work our way through each ship in the local bubble. We also jump back here when a ship is removed from the bubble, so we can continue processing from the next ship |
MANY (Common) | Workspace variable | The number of ships of each type in the local bubble of universe |
MAS1 (Bank 0) | Maths (Geometry) | Add an orientation vector coordinate to an INWK coordinate |
MAS2 (Bank 0) | Maths (Geometry) | Calculate a cap on the maximum distance to the planet or sun |
MAS3 (Bank 0) | Maths (Arithmetic) | Calculate A = x_hi^2 + y_hi^2 + z_hi^2 in the K% block |
MAS4 (Bank 0) | Maths (Geometry) | Calculate a cap on the maximum distance to a ship |
maxNameTileToClear (Common) | Workspace variable | The tile number at which the NMI handler should stop clearing tiles in the nametable buffers during its clearing cycle |
MCASH (Bank 0) | Maths (Arithmetic) | Add an amount of cash to the cash pot |
MCNT (Common) | Workspace variable | The main loop counter |
mes9 (Bank 0) | Flight | Print a text token, possibly followed by " DESTROYED" |
mes9+3 (Bank 0) | Flight | Don't print the text token, just print " DESTROYED" where applicable |
MESS (Bank 0) | Flight | Display an in-flight message |
messageBuffer (Common) | Workspace variable | A buffer for the in-flight message text |
messageLength (Common) | Workspace variable | The length of the message stored in the message buffer |
messXC (Common) | Workspace variable | Temporary storage, used to store the text column of the in-flight message in MESS, so it can be erased from the screen at the correct time |
messYC (Common) | Workspace variable | Used to specify the text row of the in-flight message in MESS, so it can be shown at a different positions in different views |
missileNames (Bank 7) | Dashboard | Tile numbers for the four missile indicators on the dashboard, as offsets from the start of tile row 22 |
missileNames_b6 (Bank 6) | Dashboard | Tile numbers for the four missile indicators on the dashboard, as offsets from the start of tile row 22 |
MJ (Common) | Workspace variable | Are we in witchspace (i.e. have we mis-jumped)? |
MJP (Bank 0) | Flight | Process a mis-jump into witchspace |
MLOOP (Bank 0) | Main loop | The entry point for the main game loop. This entry point comes after the call to the main flight loop and spawning routines, so it marks the start of the main game loop for when we are docked (as we don't need to call the main flight loop or spawning routines if we aren't in space) |
MLS1 (Bank 7) | Maths (Arithmetic) | Calculate (A P) = ALP1 * A |
MLS2 (Bank 7) | Maths (Arithmetic) | Calculate (S R) = XX(1 0) and (A P) = A * ALP1 |
MLTU2 (Bank 7) | Maths (Arithmetic) | Calculate (A P+1 P) = (A ~P) * Q |
MLTU2-2 (Bank 7) | Maths (Arithmetic) | Set Q to X, so this calculates (A P+1 P) = (A ~P) * X |
MLU1 (Bank 7) | Maths (Arithmetic) | Calculate Y1 = y_hi and (A P) = |y_hi| * Q for Y-th stardust |
MLU2 (Bank 7) | Maths (Arithmetic) | Calculate (A P) = |A| * Q |
MoveEquipmentDown (Bank 0) | Equipment | Move the currently selected item down the list of equipment |
MoveEquipmentUp (Bank 0) | Equipment | Move the currently selected item up the list of equipment |
MoveIconBarPointer (Bank 7) | Icon bar | Move the sprites that make up the icon bar pointer and record any choices |
MoveInLeftColumn (Bank 6) | Save and load | Process moving the highlight when it's in the left column (the current commander) |
MoveInMiddleColumn (Bank 6) | Save and load | Process moving the highlight when it's in the middle column |
MoveInRightColumn (Bank 6) | Save and load | Process moving the highlight when it's in the right column (the save slots) |
MoveToLeftColumn (Bank 6) | Save and load | Move the highlight to the left column (the current commander) |
MSAR (Common) | Workspace variable | The targeting state of our leftmost missile |
MSBAR (Bank 7) | Dashboard | Draw a specific indicator in the dashboard's missile bar |
MSBAR_b6 (Bank 6) | Dashboard | Draw a specific indicator in the dashboard's missile bar |
msblob (Bank 0) | Dashboard | Display the dashboard's missile indicators in black or grey |
MSTG (Common) | Workspace variable | The current missile lock target |
MT1 (Bank 2) | Text | Switch to ALL CAPS when printing extended tokens |
MT13 (Bank 2) | Text | Switch to lower case when printing extended tokens |
MT14 (Bank 2) | Text | Switch to justified text when printing extended tokens |
MT15 (Bank 2) | Text | Switch to left-aligned text when printing extended tokens |
MT16 (Bank 2) | Text | Print the character in variable DTW7 |
MT17 (Bank 2) | Text | Print the selected system's adjective, e.g. Lavian for Lave |
MT18 (Bank 2) | Text | Print a random 1-8 letter word in Sentence Case |
MT19 (Bank 2) | Text | Capitalise the next letter |
MT2 (Bank 2) | Text | Switch to Sentence Case when printing extended tokens |
MT23 (Bank 2) | Text | Move to row 9 and switch to lower case when printing extended tokens |
MT26 (Bank 2) | Text | Print a space and capitalise the next letter |
MT27 (Bank 2) | Text | Print the captain's name during mission briefings |
MT28 (Bank 2) | Text | Print the location hint during the mission 1 briefing |
MT29 (Bank 2) | Text | Move to row 7 and switch to lower case when printing extended tokens |
MT5 (Bank 2) | Text | Switch to extended tokens |
MT6 (Bank 2) | Text | Switch to standard tokens in Sentence Case |
MT8 (Bank 2) | Text | Tab to column 6 and start a new word when printing extended tokens |
MT9 (Bank 2) | Text | Clear the screen and set the view type for a text-based mission briefing |
MTIN (Bank 2) | Text | Lookup table for random tokens in the extended token table (0-37) |
MU1 (Bank 7) | Maths (Arithmetic) | Copy X into P and A, and clear the C flag |
MU11 (Bank 7) | Maths (Arithmetic) | Calculate (A P) = P * X |
MU5 (Bank 7) | Maths (Arithmetic) | Set K(3 2 1 0) = (A A A A) and clear the C flag |
MU6 (Bank 7) | Maths (Arithmetic) | Set P(1 0) = (A A) |
MULT1 (Bank 7) | Maths (Arithmetic) | Calculate (A P) = Q * A |
MULT12 (Bank 7) | Maths (Arithmetic) | Calculate (S R) = Q * A |
MULT3 (Bank 7) | Maths (Arithmetic) | Calculate K(3 2 1 0) = (A P+1 P) * Q |
MULTS-2 (Bank 7) | Maths (Arithmetic) | Calculate (A P) = X * A |
MULTU (Bank 7) | Maths (Arithmetic) | Calculate (A P) = P * Q |
MUT1 (Bank 7) | Maths (Arithmetic) | Calculate R = XX and (A P) = Q * A |
MUT2 (Bank 7) | Maths (Arithmetic) | Calculate (S R) = XX(1 0) and (A P) = Q * A |
MUT3 (Bank 7) | Maths (Arithmetic) | An unused routine that does the same as MUT2 |
MV30 (Bank 0) | Moving | Move the ship in space but without tidying the orientation vectors or applying tactics |
MV40 (Bank 0) | Moving | Rotate the planet or sun's location in space by the amount of pitch and roll of our ship |
MV45 (Bank 0) | Moving | Rejoin the MVEIT routine after the rotation, tactics and scanner code |
MVEIT (Part 1 of 9) (Bank 0) | Moving | Move current ship: Tidy the orientation vectors |
MVEIT (Part 2 of 9) (Bank 0) | Moving | Move current ship: Call tactics routine, remove ship from scanner |
MVEIT (Part 3 of 9) (Bank 0) | Moving | Move current ship: Move ship forward according to its speed |
MVEIT (Part 4 of 9) (Bank 0) | Moving | Move current ship: Apply acceleration to ship's speed as a one-off |
MVEIT (Part 5 of 9) (Bank 0) | Moving | Move current ship: Rotate ship's location by our pitch and roll |
MVEIT (Part 6 of 9) (Bank 0) | Moving | Move current ship: Move the ship in space according to our speed |
MVEIT (Part 7 of 9) (Bank 0) | Moving | Move current ship: Rotate ship's orientation vectors by pitch/roll |
MVEIT (Part 8 of 9) (Bank 0) | Moving | Move current ship: Rotate ship about itself by its own pitch/roll |
MVEIT (Part 9 of 9) (Bank 0) | Moving | Move current ship: Redraw on scanner, if it hasn't been destroyed |
MVS4 (Bank 0) | Moving | Apply pitch and roll to an orientation vector |
MVS5 (Bank 0) | Moving | Apply a 3.6 degree pitch or roll to an orientation vector |
MVS5_b0 (Bank 7) | Moving | Call the MVS5 routine in ROM bank 0 |
MVT1 (Bank 0) | Moving | Calculate (x_sign x_hi x_lo) = (x_sign x_hi x_lo) + (A R) |
MVT1-2 (Bank 0) | Moving | Clear bits 0-6 of A before entering MVT1 |
MVT3 (Bank 0) | Moving | Calculate K(3 2 1) = (x_sign x_hi x_lo) + K(3 2 1) |
MVT6 (Bank 0) | Moving | Calculate (A P+2 P+1) = (x_sign x_hi x_lo) + (A P+2 P+1) |
NA2% (Bank 6) | Save and load | The data block for the default commander |
NAME (Common) | Workspace variable | The current commander name |
nameBuffer0 (Common) | Workspace variable | The buffer for nametable 0 that gets sent to the PPU during VBlank |
nameBuffer1 (Common) | Workspace variable | The buffer for nametable 1 that gets sent to the PPU during VBlank |
nameBufferHi (Common) | Workspace variable | High byte of the address of the current nametable buffer ($70 or $74) |
nameBufferHiAddr (Bank 7) | Drawing the screen | The high bytes of the addresses of the two nametable buffers |
nameTileBuffHi (Common) | Workspace variable | (nameTileBuffHi nameTileBuffLo) contains the address of the nametable buffer for the tile we are sending to the PPU from bitplane 0 (i.e. for tile number sendingNameTile in bitplane 0) |
nameTileBuffLo (Common) | Workspace variable | (nameTileBuffHi nameTileBuffLo) contains the address of the nametable buffer for the tile we are sending to the PPU from bitplane 0 (i.e. for tile number sendingNameTile in bitplane 0) |
nameTileCounter (Common) | Workspace variable | Counts tiles as they are written to the PPU nametable in the NMI handler |
NEWB (Common) | Workspace variable | The ship's "new byte flags" (or NEWB flags) |
newTune (Common) | Workspace variable | The number of the new tune when choosing the background music |
newzp (Common) | Workspace variable | This is used by the STARS2 routine for storing the stardust particle's delta_x value |
nextSectionNOISE (Common) | Workspace variable | The next section for the NOISE channel of the current tune |
nextSectionSQ1 (Common) | Workspace variable | The next section for the SQ1 channel of the current tune |
nextSectionSQ2 (Common) | Workspace variable | The next section for the SQ2 channel of the current tune |
nextSectionTRI (Common) | Workspace variable | The next section for the TRI channel of the current tune |
NLIN2 (Bank 7) | Drawing lines | Draw a horizontal line on tile row 2 to box in a title |
NLIN3 (Bank 7) | Drawing lines | Print a title and draw a screen-wide horizontal line on tile row 2 to box it in |
NLIN4 (Bank 7) | Drawing lines | Draw a horizontal line on tile row 2 to box in a title |
NMI (Bank 7) | Utility routines | The NMI interrupt handler that gets called every VBlank and which updates the screen, reads the controllers and plays music |
nmiBitplane (Common) | Workspace variable | The number of the bitplane (0 or 1) that is currently being processed in the NMI handler during VBlank |
nmiBitplane8 (Common) | Workspace variable | Used when sending patterns to the PPU to calculate the address offset of bitplanes 0 and 1 |
nmiCounter (Common) | Workspace variable | A counter that increments every VBlank at the start of the NMI handler |
nmiStoreA (Common) | Workspace variable | Temporary storage for the A register during NMI |
nmiStoreX (Common) | Workspace variable | Temporary storage for the X register during NMI |
nmiStoreY (Common) | Workspace variable | Temporary storage for the Y register during NMI |
nmiTimer (Common) | Workspace variable | A counter that gets decremented each time the NMI interrupt is called, starting at 50 and counting down to zero, at which point it jumps back up to 50 again and triggers an increment of (nmiTimerHi nmiTimerLo) |
nmiTimerHi (Common) | Workspace variable | High byte of a counter that's incremented by 1 every time nmiTimer wraps |
nmiTimerLo (Common) | Workspace variable | Low byte of a counter that's incremented by 1 every time nmiTimer wraps |
NO1 (Bank 7) | Maths (Geometry) | Contains an RTS |
NOFX (Bank 6) | Combat demo | The x-coordinates of the scroll text letter grid |
NOFY (Bank 6) | Combat demo | The y-coordinates of the scroll text letter grid |
NOISE (Bank 7) | Sound | Make the sound effect whose number is in Y |
noiseLo (Common) | Workspace variable | The value that we are going to send to the APU via NOISE_LO for the current tune |
noiseLoCopy (Common) | Workspace variable | A copy of the value that we are going to send to the APU via NOISE_LO for the current tune |
noiseVolume (Common) | Workspace variable | The value that we are going to send to the APU via NOISE_VOL for the current tune |
NOMSL (Common) | Workspace variable | The number of missiles we have fitted (0-4) |
NORM (Bank 7) | Maths (Geometry) | Normalise the three-coordinate vector in XX15 |
NOSTM (Common) | Workspace variable | The number of stardust particles shown on screen, which is 20 (#NOST) for normal space, and 3 for witchspace |
noteFrequency (Bank 6) | Sound | A table of note frequencies |
NRU (Bank 2) | Text | The number of planetary systems with extended system description overrides in the RUTOK table (NRU%) in three different languages |
numberOfPilots (Common) | Workspace variable | A flag to determine whether the game is configured for one or two pilots |
nWq (Bank 0) | Stardust | Create a random cloud of stardust |
NwS1 (Bank 0) | Universe | Flip the sign and double an INWK byte |
NWSHP (Bank 0) | Universe | Add a new ship to our local bubble of universe |
NWSPS (Bank 0) | Universe | Add a new space station to our local bubble of universe |
NWSTARS (Bank 0) | Stardust | Initialise the stardust field |
oh (Bank 0) | Drawing the screen | Contains an RTS |
OOPS (Bank 0) | Flight | Take some damage |
OTHERFILEPR (Bank 2) | Save and load | Display the non-selected media (disk or tape) |
ou2 (Bank 0) | Flight | Display "E.C.M.SYSTEM DESTROYED" as an in-flight message |
ou3 (Bank 0) | Flight | Display "FUEL SCOOPS DESTROYED" as an in-flight message |
OUCH (Bank 0) | Flight | Potentially lose cargo or equipment following damage |
ouch1 (Bank 0) | Flight | Print the token in A as an in-flight message |
P (Common) | Workspace variable | Temporary storage, used in a number of places |
paletteColour2 (Common) | Workspace variable | Contains the colour to use for palette entry 2 in the current (non-space) view |
paletteColour3 (Common) | Workspace variable | Contains the colour to use for palette entry 3 in the current (non-space) view |
paletteForView (Bank 3) | Drawing the screen | Palette numbers for each view |
PAS1 (Bank 0) | Missions | Display a rotating ship at space coordinates (0, 100, 256) and scan the controllers |
PAS1_b0 (Bank 7) | Missions | Call the PAS1 routine in ROM bank 0 |
pattBuffer0 (Common) | Workspace variable | The pattern buffer for bitplane 0 (1 bit per pixel) that gets sent to the PPU during VBlank |
pattBuffer1 (Common) | Workspace variable | The pattern buffer for bitplane 1 (1 bit per pixel) that gets sent to the PPU during VBlank |
pattBufferAddr (Common) | Workspace variable | Address of the current pattern buffer: |
pattBufferHiAddr (Bank 7) | Drawing the screen | The high bytes of the addresses of the two pattern buffers |
pattBufferHiDiv8 (Common) | Workspace variable | High byte of the address of the current pattern buffer ($60 or $68) divided by 8 |
patternBufferHi (Common) | Workspace variable | (patternBufferHi patternBufferLo) contains the address of the pattern buffer for the pattern we are sending to the PPU from bitplane 0 (i.e. for pattern number sendingPattern in bitplane 0) |
patternBufferLo (Common) | Workspace variable | (patternBufferHi patternBufferLo) contains the address of the pattern buffer for the pattern we are sending to the PPU from bitplane 0 (i.e. for pattern number sendingPattern in bitplane 0) |
patternCounter (Common) | Workspace variable | Counts patterns as they are written to the PPU pattern table in the NMI handler |
pattSprite0 (Common) | Workspace variable | Pattern number for sprite 0 |
pattSprite1 (Common) | Workspace variable | Pattern number for sprite 1 |
pattSprite10 (Common) | Workspace variable | Pattern number for sprite 10 |
pattSprite11 (Common) | Workspace variable | Pattern number for sprite 11 |
pattSprite12 (Common) | Workspace variable | Pattern number for sprite 12 |
pattSprite13 (Common) | Workspace variable | Pattern number for sprite 13 |
pattSprite14 (Common) | Workspace variable | Pattern number for sprite 14 |
pattSprite15 (Common) | Workspace variable | Pattern number for sprite 15 |
pattSprite16 (Common) | Workspace variable | Pattern number for sprite 16 |
pattSprite17 (Common) | Workspace variable | Pattern number for sprite 17 |
pattSprite18 (Common) | Workspace variable | Pattern number for sprite 18 |
pattSprite19 (Common) | Workspace variable | Pattern number for sprite 19 |
pattSprite2 (Common) | Workspace variable | Pattern number for sprite 2 |
pattSprite20 (Common) | Workspace variable | Pattern number for sprite 20 |
pattSprite21 (Common) | Workspace variable | Pattern number for sprite 21 |
pattSprite22 (Common) | Workspace variable | Pattern number for sprite 22 |
pattSprite23 (Common) | Workspace variable | Pattern number for sprite 23 |
pattSprite24 (Common) | Workspace variable | Pattern number for sprite 24 |
pattSprite25 (Common) | Workspace variable | Pattern number for sprite 25 |
pattSprite26 (Common) | Workspace variable | Pattern number for sprite 26 |
pattSprite27 (Common) | Workspace variable | Pattern number for sprite 27 |
pattSprite28 (Common) | Workspace variable | Pattern number for sprite 28 |
pattSprite29 (Common) | Workspace variable | Pattern number for sprite 29 |
pattSprite3 (Common) | Workspace variable | Pattern number for sprite 3 |
pattSprite30 (Common) | Workspace variable | Pattern number for sprite 30 |
pattSprite31 (Common) | Workspace variable | Pattern number for sprite 31 |
pattSprite32 (Common) | Workspace variable | Pattern number for sprite 32 |
pattSprite33 (Common) | Workspace variable | Pattern number for sprite 33 |
pattSprite34 (Common) | Workspace variable | Pattern number for sprite 34 |
pattSprite35 (Common) | Workspace variable | Pattern number for sprite 35 |
pattSprite36 (Common) | Workspace variable | Pattern number for sprite 36 |
pattSprite37 (Common) | Workspace variable | Pattern number for sprite 37 |
pattSprite38 (Common) | Workspace variable | Pattern number for sprite 38 |
pattSprite39 (Common) | Workspace variable | Pattern number for sprite 39 |
pattSprite4 (Common) | Workspace variable | Pattern number for sprite 4 |
pattSprite40 (Common) | Workspace variable | Pattern number for sprite 40 |
pattSprite41 (Common) | Workspace variable | Pattern number for sprite 41 |
pattSprite42 (Common) | Workspace variable | Pattern number for sprite 42 |
pattSprite43 (Common) | Workspace variable | Pattern number for sprite 43 |
pattSprite44 (Common) | Workspace variable | Pattern number for sprite 44 |
pattSprite45 (Common) | Workspace variable | Pattern number for sprite 45 |
pattSprite46 (Common) | Workspace variable | Pattern number for sprite 46 |
pattSprite47 (Common) | Workspace variable | Pattern number for sprite 47 |
pattSprite48 (Common) | Workspace variable | Pattern number for sprite 48 |
pattSprite49 (Common) | Workspace variable | Pattern number for sprite 49 |
pattSprite5 (Common) | Workspace variable | Pattern number for sprite 5 |
pattSprite50 (Common) | Workspace variable | Pattern number for sprite 50 |
pattSprite51 (Common) | Workspace variable | Pattern number for sprite 51 |
pattSprite52 (Common) | Workspace variable | Pattern number for sprite 52 |
pattSprite53 (Common) | Workspace variable | Pattern number for sprite 53 |
pattSprite54 (Common) | Workspace variable | Pattern number for sprite 54 |
pattSprite55 (Common) | Workspace variable | Pattern number for sprite 55 |
pattSprite56 (Common) | Workspace variable | Pattern number for sprite 56 |
pattSprite57 (Common) | Workspace variable | Pattern number for sprite 57 |
pattSprite58 (Common) | Workspace variable | Pattern number for sprite 58 |
pattSprite59 (Common) | Workspace variable | Pattern number for sprite 59 |
pattSprite6 (Common) | Workspace variable | Pattern number for sprite 6 |
pattSprite60 (Common) | Workspace variable | Pattern number for sprite 60 |
pattSprite61 (Common) | Workspace variable | Pattern number for sprite 61 |
pattSprite62 (Common) | Workspace variable | Pattern number for sprite 62 |
pattSprite63 (Common) | Workspace variable | Pattern number for sprite 63 |
pattSprite7 (Common) | Workspace variable | Pattern number for sprite 7 |
pattSprite8 (Common) | Workspace variable | Pattern number for sprite 8 |
pattSprite9 (Common) | Workspace variable | Pattern number for sprite 9 |
PAUSE (Bank 2) | Missions | Display a rotating ship, waiting until a key is pressed, then remove the ship from the screen |
PAUSE2 (Bank 2) | Controllers | Wait until a key is pressed, ignoring any existing key press |
pauseCountNOISE (Common) | Workspace variable | Pause for this many iterations before continuing to process note data on channel NOISE, decrementing the value for each paused iteration |
pauseCountSQ1 (Common) | Workspace variable | Pause for this many iterations before continuing to process note data on channel SQ1, decrementing the value for each paused iteration |
pauseCountSQ2 (Common) | Workspace variable | Pause for this many iterations before continuing to process note data on channel SQ2, decrementing the value for each paused iteration |
pauseCountTRI (Common) | Workspace variable | Pause for this many iterations before continuing to process note data on channel TRI, decrementing the value for each paused iteration |
PauseGame (Bank 6) | Icon bar | Pause the game and process choices from the pause menu until the game is unpaused by another press of Start |
PauseGame_b6 (Bank 7) | Icon bar | Call the PauseGame routine in ROM bank 6 |
PCASH (Bank 0) | Status | Print the amount of cash only |
PDESC (Bank 2) | Universe | Print the system's extended description or a mission 1 directive |
PDESC_b2 (Bank 7) | Text | Call the PDESC routine in ROM bank 2 |
picturePattern (Common) | Workspace variable | The number of the first free pattern where commander and system images can be stored in the buffers |
ping (Bank 0) | Universe | Set the selected system to the current system |
pitchEnvelope (Bank 6) | Sound | Pitch envelope data for the game music |
pitchEnvelopeNOISE (Common) | Workspace variable | The number of the pitch envelope to be applied to the current tune on channel NOISE |
pitchEnvelopeSQ1 (Common) | Workspace variable | The number of the pitch envelope to be applied to the current tune on channel SQ1 |
pitchEnvelopeSQ2 (Common) | Workspace variable | The number of the pitch envelope to be applied to the current tune on channel SQ2 |
pitchEnvelopeTRI (Common) | Workspace variable | The number of the pitch envelope to be applied to the current tune on channel TRI |
pitchIndexNOISE (Common) | Workspace variable | The index of the entry within the pitch envelope to be applied to the current tune on channel NOISE |
pitchIndexSQ1 (Common) | Workspace variable | The index of the entry within the pitch envelope to be applied to the current tune on channel SQ1 |
pitchIndexSQ2 (Common) | Workspace variable | The index of the entry within the pitch envelope to be applied to the current tune on channel SQ2 |
pitchIndexTRI (Common) | Workspace variable | The index of the entry within the pitch envelope to be applied to the current tune on channel TRI |
PIXEL (Bank 7) | Drawing pixels | Draw a one-pixel dot |
PIXEL2 (Bank 1) | Drawing pixels | Draw a stardust particle relative to the screen centre |
pixl2 (Bank 7) | Drawing pixels | Restore the value of Y and return from the subroutine |
PL21 (Bank 1) | Drawing planets | Return from a planet/sun-drawing routine with a failure flag |
PL21S-1 (Bank 7) | Drawing planets | Set the C flag and return from the subroutine |
PL40 (Bank 1) | Drawing planets | Contains an RTS |
PL44 (Bank 1) | Drawing planets | Return from a planet/sun-drawing routine with a success flag |
PL9 (Part 1 of 3) (Bank 1) | Drawing planets | Draw the planet, with either an equator and meridian, or a crater |
PL9 (Part 2 of 3) (Bank 1) | Drawing planets | Draw the planet's equator and meridian |
PL9 (Part 3 of 3) (Bank 1) | Drawing planets | Draw the planet's crater |
PLANET (Bank 1) | Drawing planets | Draw the planet or sun |
PlayDemo (Bank 0) | Combat demo | Play the combat demo |
PlayDemo_b0 (Bank 7) | Combat demo | Call the PlayDemo routine in ROM bank 0 |
playMusic (Common) | Workspace variable | Controls whether to keep playing the current tune: |
plf (Bank 0) | Text | Print a text token followed by a newline |
PLFL (Bank 1) | Drawing suns | Calculate the sun's width on a given pixel row |
PLS1 (Bank 1) | Drawing planets | Calculate (Y A) = nosev_x / z |
PLS2 (Bank 1) | Drawing planets | Draw a half-ellipse |
PLS22 (Bank 1) | Drawing planets | Draw an ellipse or half-ellipse |
PLS3 (Bank 1) | Drawing planets | Calculate (Y A P) = 222 * roofv_x / z |
PLS4 (Bank 1) | Drawing planets | Calculate CNT2 = arctan(P / A) / 4 |
PLS5 (Bank 1) | Drawing planets | Calculate roofv_x / z and roofv_y / z |
PLS6 (Bank 7) | Drawing planets | Calculate (X K) = (A P+1 P) / (z_sign z_hi z_lo) |
PLUT (Bank 0) | Flight | Flip the coordinate axes for the four different views |
pointerMoveCounter (Common) | Workspace variable | The position of the icon bar pointer as it moves between icons, counting down from 12 (at the start of the move) to 0 (at the end of the move) |
pointerPressedB (Common) | Workspace variable | Controls whether the MoveIconBarPointer routine looks for a second tap of the B button when trying to detect a double-tap on the B button |
pointerTimer (Common) | Workspace variable | A timer that counts down by 1 on each call to the MoveIconBarPointer routine, so that a double-tap on the B button can be interpreted as such |
pointerTimerB (Common) | Workspace variable | A timer used in the PAL version to detect the B button being pressed twice in quick succession (a double-tap) |
popupWidth (Bank 0) | Equipment | The width of the popup that shows the views available for installing lasers in the Equipment screen |
ppuCtrlCopy (Common) | Workspace variable | Contains a copy of PPU_CTRL, so we can check the PPU configuration without having to access the PPU |
ppuNametableAddr (Common) | Workspace variable | Address of the current PPU nametable: |
ppuPatternTableHi (Common) | Workspace variable | High byte of the address of the PPU pattern table to which we send patterns |
ppuToBuffNameHi (Common) | Workspace variable | A high byte that we can add to an address in nametable buffer 0 to get the corresponding address in the PPU nametable |
pr2 (Bank 0) | Text | Print an 8-bit number, left-padded to 3 digits, and optional point |
pr2+2 (Bank 0) | Text | Print the 8-bit number in X to the number of digits in A |
pr5 (Bank 0) | Text | Print a 16-bit number, left-padded to 5 digits, and optional point |
pr6 (Bank 0) | Text | Print 16-bit number, left-padded to 5 digits, no point |
pres (Bank 0) | Equipment | Given an item number A with the item name in recursive token Y, show an error to say that the item is already present, refund the cost of the item, and then beep and exit to the docking bay (i.e. show the Status Mode screen) |
previousCondition (Common) | Workspace variable | Used to store the ship's previous status condition (i.e. docked, green, yellow or red), so we can tell how the situation is changing |
priceDebug (Common) | Workspace variable | This is only referenced by some disabled test code in the prx routine, where it was presumably used for testing different equipment prices |
Print2Spaces (Bank 0) | Text | Print two spaces |
Print4Spaces (Bank 0) | Text | An unused routine that prints four spaces |
PrintCash (Bank 0) | Market | Print our cash levels in the correct place for the chosen language |
PrintCharacter (Bank 0) | Text | An unused routine that prints a character and sets the C flag |
PrintCombatRank (Bank 0) | Status | Print the current combat rank |
PrintCommanderName (Bank 6) | Save and load | Print the commander name from the commander file in BUF, with the save count added to the end |
PrintCrTab (Bank 0) | Text | Print a newline and the correct indent for Status Mode entries in the chosen language |
PrintCtrlCode (Bank 0) | Text | Print a control code (in the range 0 to 9) |
PrintCtrlCode_b0 (Bank 7) | Text | Call the PrintCtrlCode routine in ROM bank 0 |
PrintEquipment (Bank 0) | Equipment | Print the name and price for a specified item of equipment |
PrintEquipment+2 (Bank 0) | Equipment | Print the item number in X |
PrintFlightMessage (Bank 0) | Text | Print an in-flight message |
PrintLaserView (Bank 0) | Equipment | Print the name of a laser view in the laser-buying popup, filled to the right by the correct number of spaces to fill the popup |
PrintLegalStatus (Bank 0) | Status | Print the current legal status (clean, offender or fugitive) |
PrintMarketItem (Bank 0) | Market | Print the name, price and availability of a market item on the correct row for the chosen language |
PrintMessage (Bank 0) | Text | Print a message in the middle of the screen (used for "GAME OVER" and demo missile messages only) |
PrintNameInMiddle (Bank 6) | Save and load | Print the commander name in the middle column using the highlight font |
PrintNumberInHold (Bank 0) | Market | Print the number of units of a specified item that we have in the hold |
PrintSaveHeader (Bank 6) | Save and load | Print header text for the Save and Load screen |
PrintSaveName (Bank 6) | Save and load | Print the name of a specific save slot |
PrintSpaceAndToken (Bank 0) | Text | Print a space followed by a text token |
PrintSpacedHyphen (Bank 0) | Text | Print two spaces, then a "-", and then another two spaces |
PrintSpaceViewName (Bank 0) | Text | Print the name of the current space view |
PrintTokenAndColon (Bank 0) | Text | Print a character followed by a colon, ensuring that the colon is always drawn in colour 3 on a black background |
PrintTokenCrTab (Bank 0) | Text | Print a token, a newline and the correct indent for Status Mode entries in the chosen language |
PROJ (Bank 7) | Maths (Geometry) | Project the current ship or planet onto the screen |
ProjectScrollText (Bank 6) | Combat demo | Project a scroll text coordinate onto the screen |
prq (Bank 0) | Text | Print a text token followed by a question mark |
prq+3 (Bank 0) | Text | Print a question mark |
prx (Bank 0) | Equipment | Return the price of a piece of equipment |
prx-3 (Bank 0) | Equipment | Return the price of the item with number A - 1 c Contains an RTS |
PRXS (Bank 0) | Equipment | Equipment prices |
Q (Common) | Workspace variable | Temporary storage, used in a number of places |
QQ0 (Common) | Workspace variable | The current system's galactic x-coordinate (0-256) |
QQ1 (Common) | Workspace variable | The current system's galactic y-coordinate (0-256) |
QQ10 (Common) | Workspace variable | The galactic y-coordinate of the crosshairs in the galaxy chart (and, most of the time, the selected system's galactic y-coordinate) |
QQ11 (Common) | Workspace variable | This contains the type of the current view (or, if we are changing views, the type of the view we are changing to) |
QQ11a (Common) | Workspace variable | Contains the old view type when changing views |
QQ12 (Common) | Workspace variable | Our "docked" status |
QQ14 (Common) | Workspace variable | Our current fuel level (0-70) |
QQ15 (Common) | Workspace variable | The three 16-bit seeds for the selected system, i.e. the one in the crosshairs in the Short-range Chart |
QQ16 (Bank 2) | Text | The two-letter token lookup table |
QQ17 (Common) | Workspace variable | Contains a number of flags that affect how text tokens are printed, particularly capitalisation: |
QQ18 (Bank 2) | Text | The recursive token table for tokens 0-148 |
QQ18_DE (Bank 2) | Text | The recursive token table for tokens 0-148 (German) |
QQ18_FR (Bank 2) | Text | The recursive token table for tokens 0-148 (French) |
QQ18Hi (Common) | Workspace variable | Gets set to the high byte of the address of the text token table used by the ex routine (QQ18) |
QQ18Lo (Common) | Workspace variable | Gets set to the low byte of the address of the text token table used by the ex routine (QQ18) |
QQ19 (Common) | Workspace variable | Temporary storage, used in a number of places |
QQ2 (Common) | Workspace variable | The three 16-bit seeds for the current system, i.e. the one we are currently in |
QQ20 (Common) | Workspace variable | The contents of our cargo hold |
QQ21 (Common) | Workspace variable | The three 16-bit seeds for the current galaxy |
QQ22 (Common) | Workspace variable | The two hyperspace countdown counters |
QQ23 (Bank 0) | Market | Market prices table |
QQ24 (Common) | Workspace variable | Temporary storage, used to store the current market item's price in routine TT151 |
QQ25 (Common) | Workspace variable | Temporary storage, used to store the current market item's availability in routine TT151 |
QQ26 (Common) | Workspace variable | A random value used to randomise market data |
QQ28 (Common) | Workspace variable | The current system's economy (0-7) |
QQ29 (Common) | Workspace variable | Temporary storage, used in a number of places |
QQ3 (Common) | Workspace variable | The selected system's economy (0-7) |
QQ4 (Common) | Workspace variable | The selected system's government (0-7) |
QQ5 (Common) | Workspace variable | The selected system's tech level (0-14) |
QQ6 (Common) | Workspace variable | The selected system's population in billions * 10 (1-71), so the maximum population is 7.1 billion |
QQ7 (Common) | Workspace variable | The selected system's productivity in M CR (96-62480) |
QQ8 (Common) | Workspace variable | The distance from the current system to the selected system in light years * 10, stored as a 16-bit number |
QQ9 (Common) | Workspace variable | The galactic x-coordinate of the crosshairs in the galaxy chart (and, most of the time, the selected system's galactic x-coordinate) |
qv (Bank 0) | Equipment | Print a popup menu of the four space views, for buying lasers |
qw (Bank 2) | Text | Print a recursive token in the range 128-145 |
R (Common) | Workspace variable | Temporary storage, used in a number of places |
radiusText (Bank 0) | Universe | The text string "RADIUS" for use in the Data on System screen |
RAND (Common) | Workspace variable | Four 8-bit seeds for the random number generation system implemented in the DORND routine |
RAT (Common) | Workspace variable | Used to store different signs depending on the current space view, for use in calculating stardust movement |
RAT2 (Common) | Workspace variable | Temporary storage, used to store the pitch and roll signs when moving objects and stardust |
RE2+2 (Bank 7) | Dashboard | Restore A from T and return from the subroutine |
ReadControllers (Bank 7) | Controllers | Read the buttons on the controllers and update the control variables |
RedrawCurrentView (Bank 0) | Drawing the screen | Update the current view when we arrive in a new system |
REDU2 (Bank 7) | Dashboard | Reduce the value of the pitch or roll dashboard indicator |
refund (Bank 0) | Equipment | Install a new laser, processing a refund if applicable |
RemoveShip (Bank 0) | Universe | Fetch a ship data block and remove that ship from our local bubble of universe |
RES2 (Bank 0) | Start and end | Reset a number of flight variables and workspaces |
RESET (Bank 0) | Start and end | Reset most variables |
ResetBank (Bank 7) | Utility routines | Retrieve a ROM bank number from the stack and page that bank into memory at $8000 |
ResetBankA (Bank 7) | Utility routines | Page a specified bank into memory at $8000 while preserving the value of A |
ResetBankP (Bank 7) | Utility routines | Page a specified bank into memory at $8000 while preserving the value of A and the processor flags |
ResetBuffers (Bank 7) | Drawing the screen | Reset the pattern and nametable buffers |
ResetCommander (Bank 6) | Save and load | Reset the current commander to the default "JAMESON" commander |
ResetCommander_b6 (Bank 7) | Save and load | Call the ResetCommander routine in ROM bank 6 |
ResetMMC1_b0 (Bank 0) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b1 (Bank 1) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b2 (Bank 2) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b3 (Bank 3) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b4 (Bank 4) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b5 (Bank 5) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b6 (Bank 6) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMMC1_b7 (Bank 7) | Start and end | The MMC1 mapper reset routine at the start of the ROM bank |
ResetMusic (Bank 7) | Sound | Reset the current tune to the default and stop all sounds (music and sound effects) |
ResetMusicAfterNMI (Bank 7) | Sound | Wait for the next NMI before resetting the current tune to 0 and stopping the music |
ResetOptions (Bank 7) | Start and end | Reset the game options to their default values |
ResetSaveBuffer (Bank 6) | Save and load | Reset the commander file buffer at BUF to the default commander |
ResetSaveBuffer+1 (Bank 6) | Save and load | Omit the initial PHA (so we can jump here if the value of the preserved A is already on the stack from another routine) |
ResetSaveSlots (Bank 6) | Save and load | Reset the save slots for all eight save slots, so they will fail their checksums and get reset when they are next checked |
ResetScanner (Bank 3) | Dashboard | Reset the sprites used for drawing ships on the scanner |
ResetScanner_b3 (Bank 7) | Dashboard | Call the ResetScanner routine in ROM bank 3 |
ResetScreen (Bank 3) | Start and end | Reset the screen by clearing down the PPU, setting all colours to black, and resetting the screen-related variables |
ResetScreen_b3 (Bank 7) | Start and end | Call the ResetScreen routine in ROM bank 3 |
ResetShipStatus (Bank 0) | Flight | Reset the ship's speed, hyperspace counter, laser temperature, shields and energy banks |
ResetStardust (Bank 0) | Stardust | Hide the sprites for the stardust |
ResetToStartScreen (Bank 7) | Start and end | Reset the stack and the game's variables and show the Start screen |
ResetVariables (Bank 7) | Start and end | Reset all the RAM (in both the NES and cartridge), initialise all the game's variables, and switch to ROM bank 0 |
ReturnFromSearch (Bank 0) | Icon bar | Re-entry point following a system search in HME2 |
RTOK (Common) | Text | Macro definition for recursive tokens in the recursive token table |
RTS1 (Bank 7) | PPU | Contains an RTS |
RTS10 (Bank 6) | Combat demo | Contains an RTS |
RTS2 (Bank 1) | Drawing suns | Contains an RTS |
RTS3 (Bank 7) | Controllers | Contains an RTS |
RTS4 (Bank 7) | Utility routines | Contains an RTS |
RTS5 (Bank 0) | Text | Contains an RTS |
RTS6 (Bank 0) | Universe | Contains an RTS |
RTS7 (Bank 1) | Drawing suns | Contains an RTS DrawSunEdge Draw a sun line from (X1, Y) to (X2, Y) |
RTS8 (Bank 7) | Sound | Contains an RTS |
RTS9 (Bank 3) | Icon bar | Contains an RTS |
RUGAL (Bank 2) | Text | The criteria for systems with extended description overrides |
RUGAL_DE (Bank 2) | Text | The criteria for systems with extended description overrides (German) |
RUGAL_FR (Bank 2) | Text | The criteria for systems with extended description overrides (French) |
rugalHi (Bank 2) | Text | Address lookup table for the RUGAL text token table in three different languages (high byte) |
rugalLo (Bank 2) | Text | Address lookup table for the RUGAL text token table in three different languages (low byte) |
RunDemoFlightLoop (Bank 0) | Combat demo | Run a fixed number of iterations of the main flight loop for the combat demo |
runningSetBank (Common) | Workspace variable | A flag that records whether we are in the process of switching ROM banks in the SetBank routine when the NMI handler is called |
RUPLA (Bank 2) | Text | System numbers that have extended description overrides |
RUPLA_DE (Bank 2) | Text | System numbers that have extended description overrides (German) |
RUPLA_FR (Bank 2) | Text | System numbers that have extended description overrides (French) |
ruplaHi (Bank 2) | Text | Address lookup table for the RUPLA text token table in three different languages (high byte) |
ruplaLo (Bank 2) | Text | Address lookup table for the RUPLA text token table in three different languages (low byte) |
RUTOK (Bank 2) | Text | The second extended token table for recursive tokens 0-26 (DETOK3) |
RUTOK_DE (Bank 2) | Text | The second extended token table for recursive tokens 0-26 (DETOK3) (German) |
RUTOK_FR (Bank 2) | Text | The second extended token table for recursive tokens 0-26 (DETOK3) (French) |
rutokHi (Bank 2) | Text | Address lookup table for the RUTOK text token table in three different languages (high byte) |
rutokLo (Bank 2) | Text | Address lookup table for the RUTOK text token table in three different languages (low byte) |
S (Common) | Workspace variable | Temporary storage, used in a number of places |
safehouse (Common) | Workspace variable | Backup storage for the seeds for the selected system |
saveBracketPatts (Bank 6) | Save and load | Pattern numbers for the bracket on the Save and Load screen |
saveHeader1_DE (Bank 6) | Save and load | The Save and Load screen title in German |
saveHeader1_EN (Bank 6) | Save and load | The Save and Load screen title in English |
saveHeader1_FR (Bank 6) | Save and load | The Save and Load screen title in French |
saveHeader1Hi (Bank 6) | Save and load | Lookup table for the high byte of the address of the saveHeader1 text for each language |
saveHeader1Lo (Bank 6) | Save and load | Lookup table for the low byte of the address of the saveHeader1 text for each language |
saveHeader2_DE (Bank 6) | Save and load | The subheaders for the Save and Load screen title in German |
saveHeader2_EN (Bank 6) | Save and load | The subheaders for the Save and Load screen title in English |
saveHeader2_FR (Bank 6) | Save and load | The subheaders for the Save and Load screen title in French |
saveHeader2Hi (Bank 6) | Save and load | Lookup table for the high byte of the address of the saveHeader2 text for each language |
saveHeader2Lo (Bank 6) | Save and load | Lookup table for the low byte of the address of the saveHeader2 text for each language |
SaveLoadCommander (Bank 6) | Save and load | Either save the commander from BUF into a save slot, or load the commander from BUF into the game and start the game |
saveSlotAddr1 (Bank 6) | Save and load | The address of the first saved part for each save slot |
saveSlotAddr2 (Bank 6) | Save and load | The address of the second saved part for each save slot |
saveSlotAddr3 (Bank 6) | Save and load | The address of the third saved part for each save slot |
saveSlotPart1 (Common) | Workspace variable | The first part of each of the eight save slots, which are split into three for checksum purposes |
saveSlotPart2 (Common) | Workspace variable | The second part of each of the eight save slots, which are split into three for checksum purposes |
saveSlotPart3 (Common) | Workspace variable | The third part of each of the eight save slots, which are split into three for checksum purposes |
SC (Common) | Workspace variable | Screen address (low byte) |
SC2 (Common) | Workspace variable | Temporary storage, typically used to store an address when writing data to the PPU or into the buffers |
SC3 (Common) | Workspace variable | Temporary storage, used to store an address in the pattern buffers when drawing horizontal lines |
scacol (Bank 0) | Drawing ships | Ship colours on the scanner |
SCAN (Bank 1) | Dashboard | Display the current ship on the scanner |
SCAN_b1 (Bank 7) | Dashboard | Call the SCAN routine in ROM bank 1 |
ScanButtons (Bank 7) | Controllers | Scan a specific controller and update the control variables |
scannerColour (Common) | Workspace variable | The colour of each ship number on the scanner, stored as the sprite palette number for that ship's three scanner sprites |
scannerNumber (Common) | Workspace variable | Details of which scanner numbers are allocated to ships on the scanner |
SCH (Common) | Workspace variable | Screen address (high byte) |
screenFadedToBlack (Common) | Workspace variable | Records whether the screen has been faded to black |
screenHeight (Common) | Workspace variable | The height of the drawable part of the screen in pixels (can be 144, 154 or 208 pixels) |
screenReset (Common) | Workspace variable | Gets set to 245 when the screen is reset, but this value is only read once (in SetupViewInNMI) and the value is ignored, so this doesn't have any effect |
scrollProgress (Common) | Workspace variable | Keeps track of the progress of the demo scroll text, starting from zero and increasing as the text scrolls up the screen |
scrollText1_DE (Bank 6) | Combat demo | Text for the first scroll text in German |
scrollText1_EN (Bank 6) | Combat demo | Text for the first scroll text in English |
scrollText1_FR (Bank 6) | Combat demo | Text for the first scroll text in French |
scrollText1Hi (Bank 6) | Combat demo | Lookup table for the high byte of the address of the scrollText1 text for each language |
scrollText1Lo (Bank 6) | Combat demo | Lookup table for the low byte of the address of the scrollText1 text for each language |
scrollText2_DE (Bank 6) | Combat demo | Text for the second scroll text in German |
scrollText2_EN (Bank 6) | Combat demo | Text for the second scroll text in English |
scrollText2_FR (Bank 6) | Combat demo | Text for the second scroll text in French |
scrollText2Hi (Bank 6) | Combat demo | Lookup table for the high byte of the address of the scrollText2 text for each language |
scrollText2Lo (Bank 6) | Combat demo | Lookup table for the low byte of the address of the scrollText2 text for each language |
scrollTextSpeed (Common) | Workspace variable | Controls the speed of the scroll text in the demo |
ScrollTextUpScreen (Bank 6) | Combat demo | Go through the line y-coordinate table at Y1TB, moving each line coordinate up the screen by W2Y (i.e. by one full line of text) |
sectionDataNOISE (Common) | Workspace variable | The address of the note data for channel NOISE of the the current section of the current tune |
sectionDataSQ1 (Common) | Workspace variable | The address of the note data for channel SQ1 of the the current section of the current tune |
sectionDataSQ2 (Common) | Workspace variable | The address of the note data for channel SQ2 of the the current section of the current tune |
sectionDataTRI (Common) | Workspace variable | The address of the note data for channel TRI of the the current section of the current tune |
sectionListNOISE (Common) | Workspace variable | The address of the section list for channel NOISE of the current tune |
sectionListSQ1 (Common) | Workspace variable | The address of the section list for channel SQ1 of the current tune |
sectionListSQ2 (Common) | Workspace variable | The address of the section list for channel SQ2 of the current tune |
sectionListTRI (Common) | Workspace variable | The address of the section list for channel TRI of the current tune |
selectedSystem (Common) | Workspace variable | The three 16-bit seeds for the selected system, i.e. the one we most recently snapped the crosshairs to in a chart view |
selectedSystemFlag (Common) | Workspace variable | Flags for the currently selected system |
SelectNearbySystem (Bank 0) | Universe | Set the current system to the nearest system and update the selected system flags accordingly |
SEND_DATA_TO_PPU (Common) | Drawing the screen | Send a specified block of memory to the PPU |
SendBarNamesToPPU (Bank 7) | PPU | Send the nametable entries for the icon bar to the PPU |
SendBarNamesToPPUS (Bank 7) | PPU | Send the nametable entries for the icon bar to the PPU (this is a jump so we can call this routine using a branch instruction) |
SendBarPatts2ToPPU (Bank 7) | PPU | Send pattern data for tiles 64-127 for the icon bar to the PPU, split across multiple calls to the NMI handler if required |
SendBarPattsToPPU (Bank 7) | PPU | Send pattern data for tiles 0-127 for the icon bar to the PPU, split across multiple calls to the NMI handler if required |
SendBarPattsToPPUS (Bank 7) | PPU | Send the pattern data for the icon bar to the PPU (this is a jump so we can call this routine using a branch instruction) |
SendBitplaneToPPU (Bank 3) | PPU | Send a bitplane to the PPU immediately |
SendBitplaneToPPU_b3 (Bank 7) | PPU | Call the SendBitplaneToPPU routine in ROM bank 3 |
SendBuffersToPPU (Part 1 of 3) (Bank 7) | PPU | Send the icon bar nametable and palette data to the PPU, if it has changed, before moving on to tile data in part 2 |
SendBuffersToPPU (Part 2 of 3) (Bank 7) | PPU | If we are already sending tile data to the PPU, pick up where we left off, otherwise jump to part 3 to check for new data to send |
SendBuffersToPPU (Part 3 of 3) (Bank 7) | PPU | If we need to send tile nametable and pattern data to the PPU for either bitplane, start doing just that |
sendDashboardToPPU (Common) | Workspace variable | A flag that controls whether we send the dashboard to the PPU during the main loop |
SendDashImageToPPU (Bank 3) | PPU | Unpack the dashboard image and send it to patterns 69 to 255 in pattern table 0 in the PPU |
SendDataNowToPPU (Bank 3) | PPU | Send the specified bitplane buffers to the PPU immediately, without trying to squeeze it into VBlanks |
SendFontImageToPPU (Bank 3) | PPU | Send a font to the PPU as a colour 1 font on a colour 0 background (i.e. colour 1 on black) |
sendingNameTile (Common) | Workspace variable | The number of the most recent tile that was sent to the PPU nametable by the NMI handler for bitplane 0 (or the number of the first tile to send if none have been sent), divided by 8 |
sendingPattern (Common) | Workspace variable | The number of the most recent pattern that was sent to the PPU pattern table by the NMI handler for bitplane 0 (or the number of the first pattern to send if none have been sent) |
SendInventoryToPPU (Bank 7) | PPU | Send X batches of 16 bytes from SC(1 0) to the PPU, for sending the inventory icon bar image |
SendNametableNow (Bank 7) | PPU | Send the nametable without checking the cycle count |
SendNametableToPPU (Bank 7) | PPU | Send the tile nametable to the PPU if there are enough cycles left in the current VBlank |
SendOtherBitplane (Bank 7) | PPU | Check whether we should send another bitplane to the PPU |
SendPaletteSprites (Bank 7) | Drawing sprites | Send the current palette and sprite data to the PPU |
SendPalettesToPPU (Bank 7) | PPU | Send the palette data from XX3 to the PPU |
SendPatternsToPPU (Part 1 of 6) (Bank 7) | PPU | Calculate how many patterns we need to send and jump to the most efficient routine for sending them |
SendPatternsToPPU (Part 2 of 6) (Bank 7) | PPU | Configure variables for sending data to the PPU one pattern at a time with checks |
SendPatternsToPPU (Part 3 of 6) (Bank 7) | PPU | Send pattern data to the PPU for one pattern at a time, checking after each one to see if is the last one |
SendPatternsToPPU (Part 4 of 6) (Bank 7) | PPU | Configure variables for sending data to the PPU until we run out of cycles |
SendPatternsToPPU (Part 5 of 6) (Bank 7) | PPU | Send pattern data to the PPU for two patterns at a time, until we run out of cycles (and without checking for the last pattern) |
SendPatternsToPPU (Part 6 of 6) (Bank 7) | PPU | Save progress for use in the next VBlank and return from the subroutine |
SendScreenToPPU (Bank 7) | PPU | Update the screen with the contents of the buffers |
SendScreenToPPU+4 (Bank 7) | PPU | Re-entry point following the call to SendPalettesToPPU at the start of the routine |
SendSpaceViewToPPU (Bank 0) | PPU | Set a new space view, clear the screen, copy the nametable buffers and configure the PPU for the new view |
SendTilesToPPU (Bank 7) | PPU | Set up the variables needed to send the tile nametable and pattern data to the PPU, and then send them |
SendViewToPPU (Bank 3) | PPU | Configure the PPU for the view type in QQ11 |
SendViewToPPU_b3 (Bank 7) | PPU | Call the SendViewToPPU routine in ROM bank 3 |
SESCP (Bank 0) | Flight | Spawn an escape pod from the current (parent) ship |
SetAXTo15 (Bank 0) | Utility routines | An unused routine that sets A and X to 15 |
SetBank (Bank 7) | Utility routines | Page a specified ROM bank into memory at $8000 |
SetBank0 (Bank 7) | Utility routines | Page ROM bank 0 into memory at $8000 |
SetChosenLanguage (Bank 6) | Start and end | Set the language-related variables according to the language chosen on the Start screen |
SetControllerPast (Bank 7) | Controllers | Set the controller history variables to the values from four VBlanks ago |
SetCurrentSystem (Bank 0) | Universe | Set the seeds for the selected system to the system that we last snapped the crosshairs to |
SetDemoAutoPlay (Bank 5) | Combat demo | Set up the NMI handler to automatically play the demo using the controller key presses in the autoPlayKeys table |
SetDemoAutoPlay_b5 (Bank 7) | Combat demo | Call the SetDemoAutoPlay routine in ROM bank 5 |
SetDrawingBitplane (Bank 7) | Drawing the screen | Set the drawing bitplane to a specified value |
SetDrawingPlaneTo0 (Bank 7) | Drawing the screen | Set the drawing bitplane to 0 |
SetDrawPlaneFlags (Bank 7) | Drawing the screen | Set the drawing bitplane flags to the specified value, draw the box edges and set the next free tile number |
SetEquipmentSprite (Bank 6) | Equipment | Set up the sprites in the sprite buffer for a specific bit of equipment to show on our Cobra Mk III on the Equip Ship screen |
SetIconBarButtons (Bank 3) | Icon bar | Set the correct list of button numbers for the icon bar |
SetIconBarButtonsS (Bank 3) | Icon bar | Set the correct list of button numbers for the icon bar (this is a jump so we can call this routine using a branch instruction) |
SetIconBarPointer (Bank 7) | Icon bar | Set the icon bar pointer to a specific position |
SetIconBarRow (Bank 3) | Icon bar | Set the row on which the icon bar appears, which depends on the view type |
SetKeyLogger (Bank 6) | Controllers | Populate the key logger table with the controller button presses |
SetKeyLogger_b6 (Bank 7) | Controllers | Call the SetKeyLogger routine in ROM bank 6 |
SetLanguage (Bank 6) | Start and end | Set the language-related variables for a specific language |
SetLaserSprite (Bank 6) | Equipment | Set up the sprites in the sprite buffer for a specific laser to show on our Cobra Mk III on the Equip Ship screen |
SetLinePatterns (Bank 3) | Drawing the screen | Copy the patterns for horizontal line, vertical line and block images into the pattern buffers, depending on the view |
SetLinePatterns_b3 (Bank 7) | Drawing the screen | Call the SetLinePatterns routine in ROM bank 3 |
SetNewViewType (Bank 0) | Drawing the screen | Clear the screen, set the current view type and move the cursor to row 0 |
SetNonZeroBank (Bank 7) | Utility routines | An unused routine that pages a specified ROM bank into memory at $8000, but only if it is non-zero |
SetPaletteColours (Bank 3) | Drawing the screen | Set the view's palette from the entries in the XX3 palette table |
SetPaletteForView (Bank 7) | Drawing the screen | Send palette 0 for the current view to the PPU |
SetPatternBuffer (Bank 7) | Drawing the screen | Set the high byte of the pattern buffer address variables |
SetPPURegisters (Bank 7) | PPU | Set PPU_CTRL, PPU_ADDR and PPU_SCROLL for the current hidden bitplane |
SetPPUTablesTo0 (Bank 7) | PPU | Set nametable 0 and pattern table 0 for drawing the icon bar |
SetScreenForUpdate (Bank 7) | Drawing sprites | Get the screen ready for updating by hiding all sprites, after fading the screen to black if we are changing view |
SetScreenHeight (Bank 0) | Drawing the screen | Set the screen height variables to the specified height |
SetSelectedSeeds (Bank 0) | Universe | Set the seeds for the selected system in QQ15 to the seeds in the safehouse |
SetSelectedSystem (Bank 0) | Universe | Set the selected system to the nearest system, if we don't already have a selected system |
SetSelectionFlags (Bank 0) | Universe | Set the selected system flags for the currently selected system and update the icon bar if required |
SetSpaceViewInNMI (Bank 0) | Drawing the screen | Change the current space view and configure the NMI to send both bitplanes to the PPU during VBlank |
SETUP_PPU_FOR_ICON_BAR (Common) | PPU | If the PPU has started drawing the icon bar, configure the PPU to use nametable 0 and pattern table 0 |
SetupAfterLoad (Bank 0) | Start and end | Configure the game following a commander file load |
SetupAfterLoad_b0 (Bank 7) | Start and end | Call the SetupAfterLoad routine in ROM bank 0 |
SetupDemoShip (Bank 0) | Combat demo | Set up the ship workspace for a new ship in the combat demo |
SetupDemoUniverse (Bank 7) | Combat demo | Initialise the local bubble of universe for the demo |
SetupFullViewInNMI (Bank 7) | Drawing the screen | Configure the PPU to send tiles for the full screen during VBlank |
SetupIconBar (Bank 3) | Icon bar | Set up the icons on the icon bar to show all available options |
SetupIconBar_b3 (Bank 7) | Icon bar | Call the SetupIconBar routine in ROM bank 3 |
SetupIconBarCharts (Bank 3) | Icon bar | Set up the Charts icon bar |
SetupIconBarDocked (Bank 3) | Icon bar | Set up the Docked icon bar |
SetupIconBarFlight (Bank 3) | Icon bar | Set up the Flight icon bar |
SetupIconBarPause (Bank 3) | Icon bar | Set up the game options shown on the icon bar when the game is paused |
SetupMMC1 (Bank 7) | Utility routines | Configure the MMC1 mapper and page ROM bank 0 into memory at $8000 |
SetupPPUForIconBar (Bank 7) | PPU | If the PPU has started drawing the icon bar, configure the PPU to use nametable 0 and pattern table 0, while preserving A |
setupPPUForIconBar (Common) | Workspace variable | Controls whether we force the nametable and pattern table to 0 when the PPU starts drawing the icon bar |
SetupSpaceView (Bank 0) | Drawing the screen | Set up the NMI variables for the space view |
SetupSprite0 (Bank 3) | PPU | Set the coordinates of sprite 0 so we can detect when the PPU starts to draw the icon bar |
SetupViewInNMI (Bank 3) | Drawing the screen | Setup the view and configure the NMI to send both bitplanes to the PPU during VBlank |
SetupViewInNMI_b3 (Bank 7) | Drawing the screen | Call the SetupViewInNMI routine in ROM bank 3 |
SetViewAttrs (Bank 3) | Drawing the screen | Set up attribute buffer 0 for the chosen view |
SetViewAttrs_b3 (Bank 7) | Drawing the screen | Call the SetViewAttrs routine in ROM bank 3 |
SFRMIS (Bank 0) | Tactics | Add an enemy missile to our local bubble of universe |
SFS1 (Bank 0) | Universe | Spawn a child ship from the current (parent) ship |
SFS1-2 (Bank 0) | Universe | Add a missile to the local bubble that has AI enabled, is hostile, but has no E.C.M. |
SFS2 (Bank 0) | Moving | Move a ship in space along one of the coordinate axes |
SHD (Bank 0) | Flight | Charge a shield and drain some energy from the energy banks |
SHIP_ADDER (Bank 1) | Drawing ships | Ship blueprint for an Adder |
SHIP_ANACONDA (Bank 1) | Drawing ships | Ship blueprint for an Anaconda |
SHIP_ASP_MK_2 (Bank 1) | Drawing ships | Ship blueprint for an Asp Mk II |
SHIP_ASTEROID (Bank 1) | Drawing ships | Ship blueprint for an asteroid |
SHIP_BOA (Bank 1) | Drawing ships | Ship blueprint for a Boa |
SHIP_BOULDER (Bank 1) | Drawing ships | Ship blueprint for a boulder |
SHIP_CANISTER (Bank 1) | Drawing ships | Ship blueprint for a cargo canister |
SHIP_COBRA_MK_1 (Bank 1) | Drawing ships | Ship blueprint for a Cobra Mk I |
SHIP_COBRA_MK_3 (Bank 1) | Drawing ships | Ship blueprint for a Cobra Mk III |
SHIP_COBRA_MK_3_P (Bank 1) | Drawing ships | Ship blueprint for a Cobra Mk III (pirate) |
SHIP_CONSTRICTOR (Bank 1) | Drawing ships | Ship blueprint for a Constrictor |
SHIP_CORIOLIS (Bank 1) | Drawing ships | Ship blueprint for a Coriolis space station |
SHIP_COUGAR (Bank 1) | Drawing ships | Ship blueprint for a Cougar |
SHIP_DODO (Bank 1) | Drawing ships | Ship blueprint for a Dodecahedron ("Dodo") space station |
SHIP_ESCAPE_POD (Bank 1) | Drawing ships | Ship blueprint for an escape pod |
SHIP_FER_DE_LANCE (Bank 1) | Drawing ships | Ship blueprint for a Fer-de-Lance |
SHIP_GECKO (Bank 1) | Drawing ships | Ship blueprint for a Gecko |
SHIP_KRAIT (Bank 1) | Drawing ships | Ship blueprint for a Krait |
SHIP_MAMBA (Bank 1) | Drawing ships | Ship blueprint for a Mamba |
SHIP_MISSILE (Bank 1) | Drawing ships | Ship blueprint for a missile |
SHIP_MORAY (Bank 1) | Drawing ships | Ship blueprint for a Moray |
SHIP_PLATE (Bank 1) | Drawing ships | Ship blueprint for an alloy plate |
SHIP_PYTHON (Bank 1) | Drawing ships | Ship blueprint for a Python |
SHIP_PYTHON_P (Bank 1) | Drawing ships | Ship blueprint for a Python (pirate) |
SHIP_ROCK_HERMIT (Bank 1) | Drawing ships | Ship blueprint for a rock hermit (asteroid) |
SHIP_SHUTTLE (Bank 1) | Drawing ships | Ship blueprint for a Shuttle |
SHIP_SIDEWINDER (Bank 1) | Drawing ships | Ship blueprint for a Sidewinder |
SHIP_SPLINTER (Bank 1) | Drawing ships | Ship blueprint for a splinter |
SHIP_THARGOID (Bank 1) | Drawing ships | Ship blueprint for a Thargoid mothership |
SHIP_THARGON (Bank 1) | Drawing ships | Ship blueprint for a Thargon |
SHIP_TRANSPORTER (Bank 1) | Drawing ships | Ship blueprint for a Transporter |
SHIP_VIPER (Bank 1) | Drawing ships | Ship blueprint for a Viper |
SHIP_WORM (Bank 1) | Drawing ships | Ship blueprint for a Worm |
shipIsAggressive (Common) | Workspace variable | A flag to record just how aggressive the current ship is in the TACTICS routine |
ShowIconBar (Bank 3) | Icon bar | Show a specified icon bar on-screen |
ShowIconBar_b3 (Bank 7) | Icon bar | Call the ShowIconBar routine in ROM bank 3 |
showIconBarPointer (Common) | Workspace variable | Controls whether to show the icon bar pointer |
ShowScrollText (Bank 6) | Combat demo | Show a scroll text and start the combat demo |
ShowScrollText_b6 (Bank 7) | Combat demo | Call the ShowScrollText routine in ROM bank 6 |
ShowStartScreen (Bank 0) | Start and end | Show the start screen and start the game |
showUserInterface (Common) | Workspace variable | Bit 7 set means display the user interface (so we only clear it for the game over screen) |
SHPPT (Bank 1) | Drawing ships | Draw a distant ship as a point rather than a full wireframe |
SIGHT (Bank 3) | Flight | Draw the laser crosshairs |
SIGHT_b3 (Bank 7) | Flight | Call the SIGHT routine in ROM bank 3 |
skipBarPatternsPPU (Common) | Workspace variable | A flag to control whether to send the icon bar's patterns to the PPU, after sending the nametable entries (this only applies if barPatternCounter = 0) |
smallLogoImage (Bank 3) | Save and load | Packed image data for the small Elite logo shown on the Save and Load screen |
smallLogoTile (Bank 4) | Save and load | Pattern numbers in the smallLogoImage table for the sprites that make up the small Elite logo on the Save and Load screen |
SNE (Bank 7) | Maths (Geometry) | Sine/cosine table |
SOLAR (Bank 0) | Universe | Set up various aspects of arriving in a new system |
SOS1 (Bank 0) | Universe | Update the missile indicators, set up the planet data block |
soundAddr (Common) | Workspace variable | Temporary storage, used in a number of places in the sound routines to hold an address |
soundByteNOISE (Common) | Workspace variable | The 14 sound bytes for the sound effect being made on channel NOISE |
soundByteSQ1 (Common) | Workspace variable | The 14 sound bytes for the sound effect being made on channel SQ1 |
soundByteSQ2 (Common) | Workspace variable | The 14 sound bytes for the sound effect being made on channel SQ2 |
soundChannel (Bank 7) | Sound | The sound channels used by each sound effect |
soundData (Bank 6) | Sound | Sound data for the sound effects |
soundHiNOISE (Common) | Workspace variable | The value that we are going to send to the APU via NOISE_HI for the current sound effect |
soundHiSQ1 (Common) | Workspace variable | The value that we are going to send to the APU via SQ1_HI for the current sound effect |
soundHiSQ2 (Common) | Workspace variable | The value that we are going to send to the APU via SQ2_HI for the current sound effect |
soundLoNOISE (Common) | Workspace variable | The value that we are going to send to the APU via NOISE_LO for the current sound effect |
soundLoSQ1 (Common) | Workspace variable | The value that we are going to send to the APU via SQ1_LO for the current sound effect |
soundLoSQ2 (Common) | Workspace variable | The value that we are going to send to the APU via SQ2_LO for the current sound effect |
soundPitchEnvNOISE (Common) | Workspace variable | Controls how often we apply the pitch envelope to the sound effect on channel NOISE |
soundPitchEnvSQ1 (Common) | Workspace variable | Controls how often we apply the pitch envelope to the sound effect on channel SQ1 |
soundPitchEnvSQ2 (Common) | Workspace variable | Controls how often we apply the pitch envelope to the sound effect on channel SQ2 |
soundPitCountNOISE (Common) | Workspace variable | Controls how often we send pitch data to the APU for the sound effect on channel NOISE |
soundPitCountSQ1 (Common) | Workspace variable | Controls how often we send pitch data to the APU for the sound effect on channel SQ1 |
soundPitCountSQ2 (Common) | Workspace variable | Controls how often we send pitch data to the APU for the sound effect on channel SQ2 |
soundPriority (Bank 7) | Sound | The default priority for each sound effect |
soundVibrato (Common) | Workspace variable | The four-byte seeds for adding randomised vibrato to the current sound effect |
soundVolCountNOISE (Common) | Workspace variable | Controls how often we apply the volume envelope to the sound effect on channel NOISE |
soundVolCountSQ1 (Common) | Workspace variable | Controls how often we apply the volume envelope to the sound effect on channel SQ1 |
soundVolCountSQ2 (Common) | Workspace variable | Controls how often we apply the volume envelope to the sound effect on channel SQ2 |
soundVolIndexNOISE (Common) | Workspace variable | The index into the volume envelope data of the next volume byte to apply to the sound effect on channel NOISE |
soundVolIndexSQ1 (Common) | Workspace variable | The index into the volume envelope data of the next volume byte to apply to the sound effect on channel SQ1 |
soundVolIndexSQ2 (Common) | Workspace variable | The index into the volume envelope data of the next volume byte to apply to the sound effect on channel SQ2 |
soundVolume (Bank 6) | Sound | Volume envelope data for the sound effects |
soundVolumeNOISE (Common) | Workspace variable | The address of the volume envelope data for the sound effect currently being made on channel NOISE |
soundVolumeSQ1 (Common) | Workspace variable | The address of the volume envelope data for the sound effect currently being made on channel SQ1 |
soundVolumeSQ2 (Common) | Workspace variable | The address of the volume envelope data for the sound effect currently being made on channel SQ2 |
SP1 (Bank 0) | Dashboard | Draw the space station on the compass |
SP2 (Bank 0) | Dashboard | Draw a dot on the compass, given the planet/station vector |
spasto (Common) | Workspace variable | Contains the address of the ship blueprint of the space station (which can be a Coriolis or Dodo) |
SpawnSpaceStation (Bank 0) | Universe | Add a space station to the local bubble of universe if we are close enough to the station's orbit |
spc (Bank 0) | Text | Print a text token followed by a space |
SPIN (Bank 0) | Universe | Randomly spawn cargo from a destroyed ship |
SPIN2 (Bank 0) | Universe | Remove any randomness: spawn cargo of a specific type (given in X), and always spawn the number given in A |
Sprite buffer (Common) | Drawing sprites | Configuration data for sprites 0 to 63, which gets copied to the PPU to update the screen |
SPS1 (Bank 0) | Maths (Geometry) | Calculate the vector to the planet and store it in XX15 |
SPS1+1 (Bank 0) | Maths (Geometry) | A BRK instruction |
SPS2 (Bank 0) | Maths (Arithmetic) | Calculate X = A / 16 |
SPS3 (Bank 0) | Maths (Geometry) | Copy a space coordinate from the K% block into K3 |
SPS4 (Bank 0) | Maths (Geometry) | Calculate the vector to the space station |
sq1Hi (Common) | Workspace variable | The value that we are going to send to the APU via SQ1_HI for the current tune |
sq1Lo (Common) | Workspace variable | The value that we are going to send to the APU via SQ1_LO for the current tune |
sq1LoCopy (Common) | Workspace variable | A copy of the value that we are going to send to the APU via SQ1_LO for the current tune |
sq1Sweep (Common) | Workspace variable | The value that we are going to send to the APU via SQ1_SWEEP for the current tune |
sq1Volume (Common) | Workspace variable | The value that we are going to send to the APU via SQ1_VOL for the current tune |
sq2Hi (Common) | Workspace variable | The value that we are going to send to the APU via SQ2_HI for the current tune |
sq2Lo (Common) | Workspace variable | The value that we are going to send to the APU via SQ2_LO for the current tune |
sq2LoCopy (Common) | Workspace variable | A copy of the value that we are going to send to the APU via SQ2_LO for the current tune |
sq2Sweep (Common) | Workspace variable | The value that we are going to send to the APU via SQ2_SWEEP for the current tune |
sq2Volume (Common) | Workspace variable | The value that we are going to send to the APU via SQ2_VOL for the current tune |
SQUA (Bank 7) | Maths (Arithmetic) | Clear bit 7 of A and calculate (A P) = A * A |
SQUA2 (Bank 7) | Maths (Arithmetic) | Calculate (A P) = A * A |
SSPR (Common) | Workspace variable | "Space station present" flag |
STARS (Bank 1) | Stardust | The main routine for processing the stardust |
STARS1 (Bank 1) | Stardust | Process the stardust for the front view |
STARS2 (Bank 1) | Stardust | Process the stardust for the left or right view |
STARS6 (Bank 1) | Stardust | Process the stardust for the rear view |
STARS_b1 (Bank 7) | Stardust | Call the STARS routine in ROM bank 1 |
StartEffect (Bank 6) | Sound | Start making a sound effect on the specified channel |
StartEffect_b6 (Bank 7) | Sound | Call the StartEffect routine in ROM bank 6 |
StartEffect_b7 (Bank 7) | Sound | Call the StartEffect routine |
StartEffectOnNOISE (Bank 6) | Sound | Make a sound effect on the NOISE channel |
StartEffectOnNOISES (Bank 6) | Sound | A jump table entry at the start of bank 6 for the StartEffectOnNOISE routine |
StartEffectOnSQ1 (Bank 6) | Sound | Make a sound effect on the SQ1 channel |
StartEffectOnSQ1S (Bank 6) | Sound | A jump table entry at the start of bank 6 for the StartEffectOnSQ1 routine |
StartEffectOnSQ2 (Bank 6) | Sound | Make a sound effect on the SQ2 channel |
StartEffectOnSQ2S (Bank 6) | Sound | A jump table entry at the start of bank 6 for the StartEffectOnSQ2 routine |
StartGame (Bank 0) | Start and end | Reset the stack and game variables, and start the game by going to the docking bay |
StartGame_b0 (Bank 7) | Start and end | Switch to ROM bank 0 and call the StartGame routine |
startPauseNOISE (Common) | Workspace variable | Pause for this many iterations before starting to process each batch of note data on channel NOISE |
startPauseSQ1 (Common) | Workspace variable | Pause for this many iterations before starting to process each batch of note data on channel SQ1 |
startPauseSQ2 (Common) | Workspace variable | Pause for this many iterations before starting to process each batch of note data on channel SQ2 |
startPauseTRI (Common) | Workspace variable | Pause for this many iterations before starting to process each batch of note data on channel TRI |
startupDebug (Common) | Workspace variable | This variable is set to 0 in the game's entry routine at S%, but it is never read, so maybe this is part of some debug code that was left behind? |
STATUS (Bank 0) | Status | Show the Status Mode screen |
statusCondition (Common) | Workspace variable | Used to store the ship's current status condition (i.e. docked, green, yellow or red) |
StopSounds (Bank 6) | Sound | Stop all sounds (music and sound effects) |
StopSounds_b6 (Bank 7) | Sound | Call the StopSounds routine in ROM bank 6 |
StopSoundsS (Bank 6) | Sound | A jump table entry at the start of bank 6 for the StopSounds routine |
storeA (Common) | Workspace variable | Temporary storage for saving the value of the A register, used in the bank-switching routines in bank 7 |
StoreMessage (Bank 0) | Text | Copy a message from the justified text buffer at BUF into the message buffer |
STP (Common) | Workspace variable | The step size for drawing circles |
SUBTRACT_CYCLES (Common) | Drawing the screen | Subtract a specified number from the cycle count |
SUN (Part 1 of 2) (Bank 1) | Drawing suns | Draw the sun: Set up all the variables needed to draw the sun |
SUN (Part 2 of 2) (Bank 1) | Drawing suns | Draw the sun: Starting from the bottom of the sun, draw the new sun line by line |
SUN_b1 (Bank 7) | Drawing suns | Call the SUN routine in ROM bank 1 |
sunWidth0 (Common) | Workspace variable | The half-width of the sun on pixel row 0 in the tile row that is currently being drawn |
sunWidth1 (Common) | Workspace variable | The half-width of the sun on pixel row 1 in the tile row that is currently being drawn |
sunWidth2 (Common) | Workspace variable | The half-width of the sun on pixel row 2 in the tile row that is currently being drawn |
sunWidth3 (Common) | Workspace variable | The half-width of the sun on pixel row 3 in the tile row that is currently being drawn |
sunWidth4 (Common) | Workspace variable | The half-width of the sun on pixel row 4 in the tile row that is currently being drawn |
sunWidth5 (Common) | Workspace variable | The half-width of the sun on pixel row 5 in the tile row that is currently being drawn |
sunWidth6 (Common) | Workspace variable | The half-width of the sun on pixel row 6 in the tile row that is currently being drawn |
sunWidth7 (Common) | Workspace variable | The half-width of the sun on pixel row 7 in the tile row that is currently being drawn |
SVC (Common) | Workspace variable | The save count |
SVE (Bank 6) | Save and load | Display the Save and Load screen and process saving and loading of commander files |
SVE_b6 (Bank 7) | Save and load | Call the SVE routine in ROM bank 6 |
SWAP (Common) | Workspace variable | Temporary storage, used to store a flag that records whether or not we had to swap a line's start and end coordinates around when clipping the line in routine LL145 (the flag is used in places like BLINE to swap them back) |
SX (Common) | Workspace variable | This is where we store the x_hi coordinates for all the stardust particles |
SXL (Common) | Workspace variable | This is where we store the x_lo coordinates for all the stardust particles |
SY (Common) | Workspace variable | This is where we store the y_hi coordinates for all the stardust particles |
SYL (Common) | Workspace variable | This is where we store the y_lo coordinates for all the stardust particles |
systemCount (Bank 5) | Universe | The number of system images in the systemOffset table |
systemImage0 (Bank 5) | Universe | Packed image data for system image 0 |
systemImage1 (Bank 5) | Universe | Packed image data for system image 1 |
systemImage10 (Bank 5) | Universe | Packed image data for system image 10 |
systemImage11 (Bank 5) | Universe | Packed image data for system image 11 |
systemImage12 (Bank 5) | Universe | Packed image data for system image 12 |
systemImage13 (Bank 5) | Universe | Packed image data for system image 13 |
systemImage14 (Bank 5) | Universe | Packed image data for system image 14 |
systemImage2 (Bank 5) | Universe | Packed image data for system image 2 |
systemImage3 (Bank 5) | Universe | Packed image data for system image 3 |
systemImage4 (Bank 5) | Universe | Packed image data for system image 4 |
systemImage5 (Bank 5) | Universe | Packed image data for system image 5 |
systemImage6 (Bank 5) | Universe | Packed image data for system image 6 |
systemImage7 (Bank 5) | Universe | Packed image data for system image 7 |
systemImage8 (Bank 5) | Universe | Packed image data for system image 8 |
systemImage9 (Bank 5) | Universe | Packed image data for system image 9 |
systemNumber (Common) | Workspace variable | The current system number, as calculated in TT111 when finding the nearest system in the galaxy |
systemOffset (Bank 5) | Universe | Offset to the data for each of the 15 system images |
systemPalettes (Bank 3) | Universe | Palettes for the system images |
systemsOnChart (Common) | Workspace variable | A counter for the number of systems drawn on the Short-range Chart, so it gets limited to 24 systems |
SZ (Common) | Workspace variable | This is where we store the z_hi coordinates for all the stardust particles |
SZL (Common) | Workspace variable | This is where we store the z_lo coordinates for all the stardust particles |
T (Common) | Workspace variable | Temporary storage, used in a number of places |
T1 (Common) | Workspace variable | Temporary storage, used in a number of places |
TA151 (Bank 0) | Tactics | Make the ship head towards the planet |
TA2 (Bank 0) | Maths (Geometry) | Calculate the length of the vector in XX15 (ignoring the low coordinates), returning it in Q |
TACTICS (Part 1 of 7) (Bank 0) | Tactics | Apply tactics: Process missiles, both enemy missiles and our own |
TACTICS (Part 2 of 7) (Bank 0) | Tactics | Apply tactics: Escape pod, station, lone Thargon, safe-zone pirate |
TACTICS (Part 3 of 7) (Bank 0) | Tactics | Apply tactics: Calculate dot product to determine ship's aim |
TACTICS (Part 4 of 7) (Bank 0) | Tactics | Apply tactics: Check energy levels, maybe launch escape pod if low |
TACTICS (Part 5 of 7) (Bank 0) | Tactics | Apply tactics: Consider whether to launch a missile at us |
TACTICS (Part 6 of 7) (Bank 0) | Tactics | Apply tactics: Consider firing a laser at us, if aim is true |
TACTICS (Part 7 of 7) (Bank 0) | Tactics | Apply tactics: Set pitch, roll, and acceleration |
tal (Bank 0) | Universe | Print the current galaxy number |
TALLY (Common) | Workspace variable | Our combat rank |
TALLYL (Common) | Workspace variable | Combat rank fraction |
tals (Bank 0) | Text | Print the current galaxy number |
TAS1 (Bank 0) | Maths (Arithmetic) | Calculate K3 = (x_sign x_hi x_lo) - V(1 0) |
TAS2 (Bank 0) | Maths (Geometry) | Normalise the three-coordinate vector in K3 |
TAS3 (Bank 7) | Maths (Geometry) | Calculate the dot product of XX15 and an orientation vector |
TAS4 (Bank 0) | Maths (Geometry) | Calculate the dot product of XX15 and one of the space station's orientation vectors |
TAS6 (Bank 0) | Maths (Geometry) | Negate the vector in XX15 so it points in the opposite direction |
TBRIEF (Bank 0) | Missions | Start mission 3 |
tek (Common) | Workspace variable | The current system's tech level (0-14) |
TENS (Bank 0) | Text | A constant used when printing large numbers in BPRNT |
TGT (Common) | Workspace variable | Temporary storage, typically used as a target value for counters when drawing explosion clouds and partial circles |
THERE (Bank 0) | Missions | Check whether we are in the Constrictor's system in mission 1 |
TIDY (Bank 1) | Maths (Geometry) | Orthonormalise the orientation vectors for a ship |
TIDY_b1 (Bank 7) | Maths (Geometry) | Call the TIDY routine in ROM bank 1 |
TIS1 (Bank 7) | Maths (Arithmetic) | Calculate (A ?) = (-X * A + (S R)) / 96 |
TIS2 (Bank 7) | Maths (Arithmetic) | Calculate A = A / Q |
TIS3 (Bank 1) | Maths (Arithmetic) | Calculate -(nosev_1 * roofv_1 + nosev_2 * roofv_2) / nosev_3 |
TITLE (Bank 0) | Start and end | Display a title screen with a rotating ship and prompt |
titleShip (Common) | Workspace variable | Used to store the current ship number in the title screen |
titleShipDist (Bank 7) | Start and end | The distances at which to show the rotating title screen ships |
titleShipType (Bank 7) | Start and end | The types of ship to show rotating on the title screen |
TKN1 (Bank 2) | Text | The first extended token table for recursive tokens 0-255 (DETOK) |
TKN1_DE (Bank 2) | Text | The first extended token table for recursive tokens 0-255 (DETOK) (German) |
TKN1_FR (Bank 2) | Text | The first extended token table for recursive tokens 0-255 (DETOK) (French) |
TKN1Hi (Common) | Workspace variable | Gets set to the high byte of the address of the text token table used by the DETOK routine (TKN1) |
TKN1Lo (Common) | Workspace variable | Gets set to the low byte of the address of the text token table used by the DETOK routine (TKN1) |
TKN2 (Bank 2) | Text | The extended two-letter token lookup table |
tnpr (Bank 0) | Market | Work out if we have space for a specific amount of cargo |
tnpr1 (Bank 0) | Market | Work out if we have space for one tonne of cargo |
tokensHi (Bank 6) | Text | High byte of the text token table for each language |
tokensLo (Bank 6) | Text | Low byte of the text token table for each language |
TOKN (Common) | Text | Macro definition for standard tokens in the extended token table |
TP (Common) | Workspace variable | The current mission status |
TRIBBLE (Common) | Workspace variable | The number of Trumbles in the cargo hold |
triHi (Common) | Workspace variable | The value that we are going to send to the APU via TRI_HI for the current tune |
triLo (Common) | Workspace variable | The value that we are going to send to the APU via TRI_LO for the current tune |
triLoCopy (Common) | Workspace variable | A copy of the value that we are going to send to the APU via TRI_LO for the current tune |
trumbleSounds (Bank 0) | Sound | The range of sounds that the Trumbles make in the hold |
TT100 (Bank 0) | Main loop | The entry point for the start of the main game loop, which calls the main flight loop and the moves into the spawning routine |
TT102 (Bank 0) | Icon bar | Process icon bar controller choices |
TT103 (Bank 0) | Charts | Draw a small set of crosshairs on a chart |
TT105 (Bank 0) | Charts | Draw crosshairs on the Short-range Chart, with clipping |
TT11 (Bank 0) | Text | Print a 16-bit number, left-padded to n digits, and optional point |
TT110 (Bank 0) | Flight | Launch from a station or show the front space view |
TT111 (Bank 0) | Universe | Set the current system to the nearest system to a point |
TT111-1 (Bank 0) | Universe | Contains an RTS |
TT113 (Bank 0) | Maths (Arithmetic) | Contains an RTS |
TT114 (Bank 0) | Charts | Display either the Long-range or Short-range Chart |
TT123 (Bank 0) | Charts | Move galactic coordinates by a signed delta |
TT128 (Bank 0) | Drawing circles | Draw a circle on a chart |
TT14 (Bank 0) | Drawing circles | Draw a circle with crosshairs on a chart |
TT146 (Bank 0) | Universe | Print the distance to the selected system in light years |
TT147 (Bank 0) | Flight | Print an error when a system is out of hyperspace range |
TT15 (Bank 0) | Drawing lines | Draw a set of crosshairs |
TT151 (Bank 0) | Market | Print the name, price and availability of a market item |
TT152 (Bank 0) | Market | Print the unit ("t", "kg" or "g") for a market item |
TT16 (Bank 0) | Charts | Move the crosshairs on a chart |
TT160 (Bank 0) | Market | Print "t" (for tonne) and a space |
TT161 (Bank 0) | Market | Print "kg" (for kilograms) |
TT162 (Bank 0) | Text | Print a space |
TT162+2 (Bank 0) | Text | Jump to TT27 to print the text token in A |
TT163 (Bank 0) | Market | Print the headers for the table of market prices |
TT167 (Bank 0) | Market | Show the Market Price screen |
TT16a (Bank 0) | Market | Print "g" (for grams) |
TT17 (Bank 0) | Controllers | Scan the key logger for the directional pad buttons |
TT18 (Bank 0) | Flight | Try to initiate a jump into hyperspace |
TT180 (Bank 0) | Charts | Contains an RTS |
TT20 (Bank 0) | Universe | Twist the selected system's seeds four times |
TT210 (Bank 0) | Market | Show a list of current cargo in our hold, optionally to sell |
TT213 (Bank 0) | Market | Show the Inventory screen |
TT22 (Bank 0) | Charts | Show the Long-range Chart |
TT23 (Bank 0) | Charts | Show the Short-range Chart |
TT24 (Bank 6) | Universe | Calculate system data from the system seeds |
TT24_b6 (Bank 7) | Universe | Call the TT24 routine in ROM bank 6 |
TT25 (Bank 0) | Universe | Show the Data on System screen |
TT26 (Bank 2) | Text | Print a character at the text cursor, with support for verified text in extended tokens |
TT27 (Bank 2) | Text | Print a text token |
TT27_b2 (Bank 7) | Text | Call the TT27 routine in ROM bank 2 |
TT41 (Bank 2) | Text | Print a letter according to Sentence Case |
TT42 (Bank 2) | Text | Print a letter in lower case |
TT43 (Bank 2) | Text | Print a two-letter token or recursive token 0-95 |
TT44 (Bank 2) | Text | Jumps to TT26 to print the character in A (used to enable us to use a branch instruction to jump to TT26) |
TT45 (Bank 2) | Text | Print a letter in lower case |
TT48 (Bank 2) | Text | Contains an RTS |
TT54 (Bank 0) | Universe | Twist the selected system's seeds |
TT60 (Bank 0) | Text | Print a text token and a paragraph break |
TT66 (Bank 0) | Drawing the screen | Clear the screen and set the new view type |
TT66_b0 (Bank 7) | Drawing the screen | Call the TT66 routine in ROM bank 0 |
TT67 (Bank 0) | Text | Print a newline |
TT68 (Bank 0) | Text | Print a text token followed by a colon |
TT69 (Bank 0) | Text | Set Sentence Case and print a newline |
TT70 (Bank 0) | Universe | Display "MAINLY " and jump to TT72 |
TT72 (Bank 0) | Universe | Used by TT70 to re-enter the routine after displaying "MAINLY" for the economy type |
TT73 (Bank 0) | Text | Print a colon |
TT81 (Bank 0) | Universe | Set the selected system's seeds to those of system 0 |
TTX69 (Bank 0) | Text | Print a paragraph break |
tuneData (Bank 6) | Sound | Data for the tunes played in the game |
tuneProgress (Common) | Workspace variable | A variable for keeping track of progress while playing the current tune, so we send data to the APU at the correct time over multiple iterations of the MakeMusic routine, according to the tune speed in tuneSpeed |
tuneSpeed (Common) | Workspace variable | The speed of the current tune, which can vary as the tune plays |
tuneSpeedCopy (Common) | Workspace variable | The starting speed of the current tune, as stored in the tune's data |
tuningAll (Common) | Workspace variable | The tuning value for all channels |
tuningSQ1 (Common) | Workspace variable | The tuning value for the SQ1 channel |
tuningSQ2 (Common) | Workspace variable | The tuning value for the SQ2 channel |
tuningTRI (Common) | Workspace variable | The tuning value for the TRI channel |
TWFL (Bank 7) | Drawing lines | Ready-made character rows for the left end of a horizontal line in the space view |
TWFR (Bank 7) | Drawing lines | Ready-made character rows for the right end of a horizontal line in the space view |
TWOK (Common) | Text | Macro definition for two-letter tokens in the token table |
TWOS (Bank 7) | Drawing pixels | Ready-made single-pixel character row bytes for the space view |
TWOS2 (Bank 7) | Drawing pixels | Ready-made double-pixel character row bytes for the space view |
TYPE (Common) | Workspace variable | The current ship type |
U (Common) | Workspace variable | Temporary storage, used in a number of places |
U% (Bank 0) | Controllers | Clear the key logger |
UNIV (Bank 7) | Universe | Table of pointers to the local universe's ship data blocks |
UnpackToPPU (Bank 7) | Utility routines | Unpack compressed image data and send it to the PPU |
UnpackToPPU+2 (Bank 7) | Utility routines | Unpack data from offset Y onwards |
UnpackToRAM (Bank 7) | Utility routines | Unpack compressed image data to RAM |
Unused copy of XX21 (Bank 1) | Drawing ships | Remnants of an unused copy of the XX21 ship blueprints lookup table |
unusedVariable (Common) | Workspace variable | This variable is zeroed in RES2 but is never read |
UpdateEquipment (Bank 0) | Equipment | Highlight the newly chosen item of equipment, update the Cobra Mk III, redraw the screen and rejoin the main EQSHP routine |
UpdateHangarView (Bank 7) | PPU | Update the hangar view on-screen by sending the data to the PPU, either immediately or during VBlank |
UpdateIconBar (Bank 3) | Icon bar | Update the icon bar |
UpdateIconBar_b3 (Bank 7) | Icon bar | Call the UpdateIconBar routine in ROM bank 3 |
UpdateJoystick (Bank 7) | Controllers | Update the values of JSTX and JSTY with the values from the controller |
UpdateNMITimer (Bank 7) | Utility routines | Update the NMI timer, which we can use to keep track of time for places like the combat demo |
updatePaletteInNMI (Common) | Workspace variable | A flag that controls whether to send the palette data from XX3 to the PPU during NMI: |
UpdateSaveCount (Bank 7) | Save and load | Update the save counter for the current commander |
UpdateSaveScreen (Bank 6) | Save and load | Update the Save and Load screen |
UpdateScreen (Bank 7) | PPU | Update the screen by sending data to the PPU, either immediately or during VBlank, depending on whether the screen is visible |
UpdateVibratoSeeds (Bank 6) | Sound | Update the sound seeds that are used to randomise the vibrato effect |
UpdateView (Bank 0) | Drawing the screen | Update the view |
UpdateView_b0 (Bank 7) | Drawing the screen | Call the UpdateView routine in ROM bank 0 |
UpdateViewWithFade (Bank 7) | Drawing the screen | Fade the screen to black, if required, hide all sprites and update the view |
V (Common) | Workspace variable | Temporary storage, typically used for storing an address pointer |
var (Bank 0) | Market | Calculate QQ19+3 = economy * |economic_factor| |
VCSU1 (Bank 0) | Maths (Arithmetic) | Calculate vector K3(8 0) = [x y z] - coordinates of the sun or space station |
VCSUB (Bank 0) | Maths (Arithmetic) | Calculate vector K3(8 0) = [x y z] - coordinates in (A V) |
Vectors_b0 (Bank 0) | Utility routines | Vectors and padding at the end of ROM bank 0 |
Vectors_b1 (Bank 1) | Utility routines | Vectors and padding at the end of ROM bank 1 |
Vectors_b2 (Bank 2) | Utility routines | Vectors and padding at the end of ROM bank 2 |
Vectors_b3 (Bank 3) | Utility routines | Vectors and padding at the end of ROM bank 3 |
Vectors_b4 (Bank 4) | Utility routines | Vectors and padding at the end of ROM bank 4 |
Vectors_b5 (Bank 5) | Utility routines | Vectors and padding at the end of ROM bank 5 |
Vectors_b6 (Bank 6) | Utility routines | Vectors and padding at the end of ROM bank 6 |
Vectors_b7 (Bank 7) | Utility routines | Vectors at the end of ROM bank 7 |
versionNumber_b0 (Bank 0) | Text | The game's version number in bank 0 |
versionNumber_b1 (Bank 1) | Text | The game's version number in bank 1 |
versionNumber_b2 (Bank 2) | Text | The game's version number in bank 2 |
versionNumber_b3 (Bank 3) | Text | The game's version number in bank 3 |
versionNumber_b4 (Bank 4) | Text | The game's version number in bank 4 |
versionNumber_b5 (Bank 5) | Text | The game's version number in bank 5 |
versionNumber_b6 (Bank 6) | Text | The game's version number in bank 6 |
VERTEX (Common) | Drawing ships | Macro definition for adding vertices to ship blueprints |
VIEW (Common) | Workspace variable | The number of the current space view |
viewAttrCount (Bank 3) | Drawing the screen | The number of sets of view attributes in the viewAttrOffset table |
viewAttributes0 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 0 |
viewAttributes1 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 1 |
viewAttributes10 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 10 |
viewAttributes11 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 11 |
viewAttributes12 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 12 |
viewAttributes13 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 13 |
viewAttributes14 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 14 |
viewAttributes15 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 15 |
viewAttributes16 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 16 |
viewAttributes17 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 17 |
viewAttributes18 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 18 |
viewAttributes19 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 19 |
viewAttributes2 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 2 |
viewAttributes20 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 20 |
viewAttributes21 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 21 |
viewAttributes22 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 22 |
viewAttributes23 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 23 |
viewAttributes3 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 3 |
viewAttributes4 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 4 |
viewAttributes5 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 5 |
viewAttributes6 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 6 |
viewAttributes7 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 7 |
viewAttributes8 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 8 |
viewAttributes9 (Bank 3) | Drawing the screen | Packed view attribute data for attribute set 9 |
viewAttributes_DE (Bank 3) | Drawing the screen | The view attributes to use for each view type in German |
viewAttributes_EN (Bank 3) | Drawing the screen | The view attributes to use for each view type in English |
viewAttributes_FR (Bank 3) | Drawing the screen | The view attributes to use for each view type in French |
viewAttributesHi (Bank 3) | Drawing the screen | The high byte of the view attributes lookup table for each language |
viewAttributesLo (Bank 3) | Drawing the screen | The low byte of the view attributes lookup table for each language |
viewAttrOffset (Bank 3) | Drawing the screen | Offset to the data for each of the 24 sets of view attributes |
viewPalettes (Bank 3) | Drawing the screen | The palettes to use for the different views |
visibleColour (Common) | Workspace variable | Contains the colour to use for pixels that are visible in palette 0, e.g. $2C for cyan |
volumeCounterNOISE (Common) | Workspace variable | A counter for keeping track of repeated bytes from the volume envelope on channel NOISE |
volumeCounterSQ1 (Common) | Workspace variable | A counter for keeping track of repeated bytes from the volume envelope on channel SQ1 |
volumeCounterSQ2 (Common) | Workspace variable | A counter for keeping track of repeated bytes from the volume envelope on channel SQ2 |
volumeCounterTRI (Common) | Workspace variable | A counter for keeping track of repeated bytes from the volume envelope on channel TRI |
volumeEnvelope (Bank 6) | Sound | Volume envelope data for the game music |
volumeEnvelopeNOISE (Common) | Workspace variable | The number of the volume envelope to be applied to the current tune on channel NOISE |
volumeEnvelopeSQ1 (Common) | Workspace variable | The number of the volume envelope to be applied to the current tune on channel SQ1 |
volumeEnvelopeSQ2 (Common) | Workspace variable | The number of the volume envelope to be applied to the current tune on channel SQ2 |
volumeEnvelopeTRI (Common) | Workspace variable | The number of the volume envelope to be applied to the current tune on channel TRI |
volumeIndexNOISE (Common) | Workspace variable | The index into the volume envelope data of the next volume byte to apply to channel NOISE |
volumeIndexSQ1 (Common) | Workspace variable | The index into the volume envelope data of the next volume byte to apply to channel SQ1 |
volumeIndexSQ2 (Common) | Workspace variable | The index into the volume envelope data of the next volume byte to apply to channel SQ2 |
volumeRepeatNOISE (Common) | Workspace variable | The number of repeats to be applied to each byte in the volume envelope on channel NOISE |
volumeRepeatSQ1 (Common) | Workspace variable | The number of repeats to be applied to each byte in the volume envelope on channel SQ1 |
volumeRepeatSQ2 (Common) | Workspace variable | The number of repeats to be applied to each byte in the volume envelope on channel SQ2 |
VOWEL (Bank 2) | Text | Test whether a character is a vowel |
WaitFor2NMIs (Bank 7) | Utility routines | Wait until two NMI interrupts have passed (i.e. the next two VBlanks) |
WaitFor3xVBlank (Bank 7) | Utility routines | Wait for three VBlanks to pass |
WaitForIconBarPPU (Bank 7) | PPU | Wait until the PPU starts drawing the icon bar |
WaitForNextNMI (Bank 7) | Utility routines | An unused routine that waits until the NMI counter increments (i.e. the next VBlank) |
WaitForNMI (Bank 7) | Utility routines | Wait until the next NMI interrupt has passed (i.e. the next VBlank) |
WaitForNoDirection (Bank 6) | Controllers | Wait until the left and right buttons on controller 1 have been released and remain released for at least four VBlanks |
WaitForPPUToFinish (Bank 7) | PPU | Wait until the NMI handler has finished updating both bitplanes, so the screen is no longer refreshing |
WaitForVBlank (Bank 7) | Utility routines | Wait for the next VBlank to pass |
WARP (Bank 0) | Flight | Process the fast-forward button to end the demo, dock instantly or perform an in-system jump |
widget (Common) | Workspace variable | Temporary storage, used to store the original argument in A in the logarithmic FMLTU and LL28 routines |
WP (Common) | Workspaces | Ship slots, variables |
WPSHPS (Bank 0) | Dashboard | Set all ships to be hidden from the screen |
wW (Bank 0) | Flight | Start a hyperspace countdown |
wW2 (Bank 0) | Flight | Start the hyperspace countdown, starting the countdown from the value in A |
X1 (Common) | Workspace variable | Temporary storage, typically used for x-coordinates in the line-drawing routines |
X1TB (Common) | Workspace variable | The x-coordinates of the start points for character lines in the scroll text |
X2 (Common) | Workspace variable | Temporary storage, typically used for x-coordinates in the line-drawing routines |
X2TB (Common) | Workspace variable | The x-coordinates of the end points for character lines in the scroll text |
XC (Common) | Workspace variable | The x-coordinate of the text cursor (i.e. the text column), which can be from 0 to 32 |
xCash (Bank 0) | Market | The text column for our cash levels on the Market Price page |
xDataOnSystem (Bank 0) | Universe | The text column for the Data on System title for each language |
xEquipShip (Bank 0) | Equipment | The text column for the Equip Ship title for each language |
xIconBarPointer (Common) | Workspace variable | The x-coordinate of the icon bar pointer |
xLanguage (Bank 6) | Start and end | The text column for the language buttons on the Start screen |
xLaserView (Bank 0) | Equipment | The text column of the right edge of the laser-buying popup, so the popup gets filled with spaces and covers what's underneath it |
XP (Common) | Workspace variable | The x-coordinate of the current character as we construct the lines for the Star Wars scroll text |
xPointerDelta (Common) | Workspace variable | The direction in which the icon bar pointer is moving, expressed as a delta to add to the x-coordinate of the pointer sprites |
XSAV (Common) | Workspace variable | Temporary storage for saving the value of the X register, used in a number of places |
XSAV2 (Common) | Workspace variable | Temporary storage, used for storing the value of the X register in the CHPR routine |
xSaveHeader (Bank 6) | Save and load | The text column for the Save and Load screen headers for each language |
xShortRange (Bank 0) | Charts | The text column for the Short-range Chart title for each language |
xSpaceView (Bank 7) | Flight | The text column for the space view name for each language |
xSprite0 (Common) | Workspace variable | Screen x-coordinate for sprite 0 |
xSprite1 (Common) | Workspace variable | Screen x-coordinate for sprite 1 |
xSprite10 (Common) | Workspace variable | Screen x-coordinate for sprite 10 |
xSprite11 (Common) | Workspace variable | Screen x-coordinate for sprite 11 |
xSprite12 (Common) | Workspace variable | Screen x-coordinate for sprite 12 |
xSprite13 (Common) | Workspace variable | Screen x-coordinate for sprite 13 |
xSprite14 (Common) | Workspace variable | Screen x-coordinate for sprite 14 |
xSprite15 (Common) | Workspace variable | Screen x-coordinate for sprite 15 |
xSprite16 (Common) | Workspace variable | Screen x-coordinate for sprite 16 |
xSprite17 (Common) | Workspace variable | Screen x-coordinate for sprite 17 |
xSprite18 (Common) | Workspace variable | Screen x-coordinate for sprite 18 |
xSprite19 (Common) | Workspace variable | Screen x-coordinate for sprite 19 |
xSprite2 (Common) | Workspace variable | Screen x-coordinate for sprite 2 |
xSprite20 (Common) | Workspace variable | Screen x-coordinate for sprite 20 |
xSprite21 (Common) | Workspace variable | Screen x-coordinate for sprite 21 |
xSprite22 (Common) | Workspace variable | Screen x-coordinate for sprite 22 |
xSprite23 (Common) | Workspace variable | Screen x-coordinate for sprite 23 |
xSprite24 (Common) | Workspace variable | Screen x-coordinate for sprite 24 |
xSprite25 (Common) | Workspace variable | Screen x-coordinate for sprite 25 |
xSprite26 (Common) | Workspace variable | Screen x-coordinate for sprite 26 |
xSprite27 (Common) | Workspace variable | Screen x-coordinate for sprite 27 |
xSprite28 (Common) | Workspace variable | Screen x-coordinate for sprite 28 |
xSprite29 (Common) | Workspace variable | Screen x-coordinate for sprite 29 |
xSprite3 (Common) | Workspace variable | Screen x-coordinate for sprite 3 |
xSprite30 (Common) | Workspace variable | Screen x-coordinate for sprite 30 |
xSprite31 (Common) | Workspace variable | Screen x-coordinate for sprite 31 |
xSprite32 (Common) | Workspace variable | Screen x-coordinate for sprite 32 |
xSprite33 (Common) | Workspace variable | Screen x-coordinate for sprite 33 |
xSprite34 (Common) | Workspace variable | Screen x-coordinate for sprite 34 |
xSprite35 (Common) | Workspace variable | Screen x-coordinate for sprite 35 |
xSprite36 (Common) | Workspace variable | Screen x-coordinate for sprite 36 |
xSprite37 (Common) | Workspace variable | Screen x-coordinate for sprite 37 |
xSprite38 (Common) | Workspace variable | Screen x-coordinate for sprite 38 |
xSprite39 (Common) | Workspace variable | Screen x-coordinate for sprite 39 |
xSprite4 (Common) | Workspace variable | Screen x-coordinate for sprite 4 |
xSprite40 (Common) | Workspace variable | Screen x-coordinate for sprite 40 |
xSprite41 (Common) | Workspace variable | Screen x-coordinate for sprite 41 |
xSprite42 (Common) | Workspace variable | Screen x-coordinate for sprite 42 |
xSprite43 (Common) | Workspace variable | Screen x-coordinate for sprite 43 |
xSprite44 (Common) | Workspace variable | Screen x-coordinate for sprite 44 |
xSprite45 (Common) | Workspace variable | Screen x-coordinate for sprite 45 |
xSprite46 (Common) | Workspace variable | Screen x-coordinate for sprite 46 |
xSprite47 (Common) | Workspace variable | Screen x-coordinate for sprite 47 |
xSprite48 (Common) | Workspace variable | Screen x-coordinate for sprite 48 |
xSprite49 (Common) | Workspace variable | Screen x-coordinate for sprite 49 |
xSprite5 (Common) | Workspace variable | Screen x-coordinate for sprite 5 |
xSprite50 (Common) | Workspace variable | Screen x-coordinate for sprite 50 |
xSprite51 (Common) | Workspace variable | Screen x-coordinate for sprite 51 |
xSprite52 (Common) | Workspace variable | Screen x-coordinate for sprite 52 |
xSprite53 (Common) | Workspace variable | Screen x-coordinate for sprite 53 |
xSprite54 (Common) | Workspace variable | Screen x-coordinate for sprite 54 |
xSprite55 (Common) | Workspace variable | Screen x-coordinate for sprite 55 |
xSprite56 (Common) | Workspace variable | Screen x-coordinate for sprite 56 |
xSprite57 (Common) | Workspace variable | Screen x-coordinate for sprite 57 |
xSprite58 (Common) | Workspace variable | Screen x-coordinate for sprite 58 |
xSprite59 (Common) | Workspace variable | Screen x-coordinate for sprite 59 |
xSprite6 (Common) | Workspace variable | Screen x-coordinate for sprite 6 |
xSprite60 (Common) | Workspace variable | Screen x-coordinate for sprite 60 |
xSprite61 (Common) | Workspace variable | Screen x-coordinate for sprite 61 |
xSprite62 (Common) | Workspace variable | Screen x-coordinate for sprite 62 |
xSprite63 (Common) | Workspace variable | Screen x-coordinate for sprite 63 |
xSprite7 (Common) | Workspace variable | Screen x-coordinate for sprite 7 |
xSprite8 (Common) | Workspace variable | Screen x-coordinate for sprite 8 |
xSprite9 (Common) | Workspace variable | Screen x-coordinate for sprite 9 |
xStatusMode (Bank 0) | Status | The text column for the Status Mode entries for each language |
xTitleScreen (Bank 7) | Start and end | The text column for the title screen's title for each language |
XX (Common) | Workspace variable | Temporary storage, typically used for storing a 16-bit x-coordinate |
XX0 (Common) | Workspace variable | Temporary storage, used to store the address of a ship blueprint. For example, it is used when we add a new ship to the local bubble in routine NWSHP, and it contains the address of the current ship's blueprint as we loop through all the nearby ships in the main flight loop |
XX1 (Common) | Workspace variable | This is an alias for INWK that is used in the main ship-drawing routine at LL9 |
XX12 (Common) | Workspace variable | Temporary storage for a block of values, used in a number of places |
XX13 (Common) | Workspace variable | Temporary storage, typically used in the line-drawing routines |
XX14 (Common) | Workspace variable | This byte appears to be unused |
XX15 (Common) | Workspace variable | Temporary storage, typically used for storing screen coordinates in line-drawing routines |
XX16 (Common) | Workspace variable | Temporary storage for a block of values, used in a number of places |
XX17 (Common) | Workspace variable | Temporary storage, used in BPRNT to store the number of characters to print, and as the edge counter in the main ship-drawing routine |
XX18 (Common) | Workspace variable | Temporary storage used to store coordinates in the LL9 ship-drawing routine |
XX2 (Common) | Workspace variable | Temporary storage, used to store the visibility of the ship's faces during the ship-drawing routine at LL9 |
XX20 (Common) | Workspace variable | Temporary storage, used in a number of places |
XX21 (Bank 7) | Drawing ships | Ship blueprints lookup table |
XX3 (Common) | Workspaces | Temporary storage space for complex calculations |
XX4 (Common) | Workspace variable | Temporary storage, used in a number of places |
Y1 (Common) | Workspace variable | Temporary storage, typically used for y-coordinates in line-drawing routines |
Y1TB (Common) | Workspace variable | The y-coordinates of the start and end points for character lines in the scroll text, with the start point (Y1) in the low nibble and the end point (Y2) in the high nibble |
Y2 (Common) | Workspace variable | Temporary storage, typically used for y-coordinates in line-drawing routines |
YC (Common) | Workspace variable | The y-coordinate of the text cursor (i.e. the text row), which can be from 0 to 23 |
yCash (Bank 0) | Market | The text row for the cash levels on the Market Price page |
YESNO (Bank 0) | Controllers | Display "YES" or "NO" and wait until one is chosen |
yHangarFloor (Bank 1) | Ship hangar | Pixel y-coordinates for the four horizontal lines that make up the floor of the ship hangar |
yHeadshot (Bank 0) | Status | The text row for the headshot on the Status Mode page |
yIconBarPointer (Common) | Workspace variable | The y-coordinate of the icon bar pointer |
yLanguage (Bank 6) | Start and end | The text row for the language buttons on the Start screen |
yLookupHi (Bank 7) | Drawing pixels | Lookup table for converting pixel y-coordinate to tile number (high byte) |
yLookupLo (Bank 7) | Drawing pixels | Lookup table for converting pixel y-coordinate to tile number (low byte) |
yMarketPrice (Bank 0) | Market | The text row for the Market Price title for each language |
YP (Common) | Workspace variable | The y-coordinate of the current character as we construct the lines for the Star Wars scroll text |
ypl (Bank 0) | Universe | Print the current system name |
ypl-1 (Bank 0) | Universe | Contains an RTS |
ypls (Bank 0) | Text | Print the current system name |
YSAV (Common) | Workspace variable | Temporary storage for saving the value of the Y register, used in a number of places |
YSAV2 (Common) | Workspace variable | Temporary storage, used for storing the value of the Y register in the CHPR routine |
ySprite0 (Common) | Workspace variable | Screen y-coordinate for sprite 0 |
ySprite1 (Common) | Workspace variable | Screen y-coordinate for sprite 1 |
ySprite10 (Common) | Workspace variable | Screen y-coordinate for sprite 10 |
ySprite11 (Common) | Workspace variable | Screen y-coordinate for sprite 11 |
ySprite12 (Common) | Workspace variable | Screen y-coordinate for sprite 12 |
ySprite13 (Common) | Workspace variable | Screen y-coordinate for sprite 13 |
ySprite14 (Common) | Workspace variable | Screen y-coordinate for sprite 14 |
ySprite15 (Common) | Workspace variable | Screen y-coordinate for sprite 15 |
ySprite16 (Common) | Workspace variable | Screen y-coordinate for sprite 16 |
ySprite17 (Common) | Workspace variable | Screen y-coordinate for sprite 17 |
ySprite18 (Common) | Workspace variable | Screen y-coordinate for sprite 18 |
ySprite19 (Common) | Workspace variable | Screen y-coordinate for sprite 19 |
ySprite2 (Common) | Workspace variable | Screen y-coordinate for sprite 2 |
ySprite20 (Common) | Workspace variable | Screen y-coordinate for sprite 20 |
ySprite21 (Common) | Workspace variable | Screen y-coordinate for sprite 21 |
ySprite22 (Common) | Workspace variable | Screen y-coordinate for sprite 22 |
ySprite23 (Common) | Workspace variable | Screen y-coordinate for sprite 23 |
ySprite24 (Common) | Workspace variable | Screen y-coordinate for sprite 24 |
ySprite25 (Common) | Workspace variable | Screen y-coordinate for sprite 25 |
ySprite26 (Common) | Workspace variable | Screen y-coordinate for sprite 26 |
ySprite27 (Common) | Workspace variable | Screen y-coordinate for sprite 27 |
ySprite28 (Common) | Workspace variable | Screen y-coordinate for sprite 28 |
ySprite29 (Common) | Workspace variable | Screen y-coordinate for sprite 29 |
ySprite3 (Common) | Workspace variable | Screen y-coordinate for sprite 3 |
ySprite30 (Common) | Workspace variable | Screen y-coordinate for sprite 30 |
ySprite31 (Common) | Workspace variable | Screen y-coordinate for sprite 31 |
ySprite32 (Common) | Workspace variable | Screen y-coordinate for sprite 32 |
ySprite33 (Common) | Workspace variable | Screen y-coordinate for sprite 33 |
ySprite34 (Common) | Workspace variable | Screen y-coordinate for sprite 34 |
ySprite35 (Common) | Workspace variable | Screen y-coordinate for sprite 35 |
ySprite36 (Common) | Workspace variable | Screen y-coordinate for sprite 36 |
ySprite37 (Common) | Workspace variable | Screen y-coordinate for sprite 37 |
ySprite38 (Common) | Workspace variable | Screen y-coordinate for sprite 38 |
ySprite39 (Common) | Workspace variable | Screen y-coordinate for sprite 39 |
ySprite4 (Common) | Workspace variable | Screen y-coordinate for sprite 4 |
ySprite40 (Common) | Workspace variable | Screen y-coordinate for sprite 40 |
ySprite41 (Common) | Workspace variable | Screen y-coordinate for sprite 41 |
ySprite42 (Common) | Workspace variable | Screen y-coordinate for sprite 42 |
ySprite43 (Common) | Workspace variable | Screen y-coordinate for sprite 43 |
ySprite44 (Common) | Workspace variable | Screen y-coordinate for sprite 44 |
ySprite45 (Common) | Workspace variable | Screen y-coordinate for sprite 45 |
ySprite46 (Common) | Workspace variable | Screen y-coordinate for sprite 46 |
ySprite47 (Common) | Workspace variable | Screen y-coordinate for sprite 47 |
ySprite48 (Common) | Workspace variable | Screen y-coordinate for sprite 48 |
ySprite49 (Common) | Workspace variable | Screen y-coordinate for sprite 49 |
ySprite5 (Common) | Workspace variable | Screen y-coordinate for sprite 5 |
ySprite50 (Common) | Workspace variable | Screen y-coordinate for sprite 50 |
ySprite51 (Common) | Workspace variable | Screen y-coordinate for sprite 51 |
ySprite52 (Common) | Workspace variable | Screen y-coordinate for sprite 52 |
ySprite53 (Common) | Workspace variable | Screen y-coordinate for sprite 53 |
ySprite54 (Common) | Workspace variable | Screen y-coordinate for sprite 54 |
ySprite55 (Common) | Workspace variable | Screen y-coordinate for sprite 55 |
ySprite56 (Common) | Workspace variable | Screen y-coordinate for sprite 56 |
ySprite57 (Common) | Workspace variable | Screen y-coordinate for sprite 57 |
ySprite58 (Common) | Workspace variable | Screen y-coordinate for sprite 58 |
ySprite59 (Common) | Workspace variable | Screen y-coordinate for sprite 59 |
ySprite6 (Common) | Workspace variable | Screen y-coordinate for sprite 6 |
ySprite60 (Common) | Workspace variable | Screen y-coordinate for sprite 60 |
ySprite61 (Common) | Workspace variable | Screen y-coordinate for sprite 61 |
ySprite62 (Common) | Workspace variable | Screen y-coordinate for sprite 62 |
ySprite63 (Common) | Workspace variable | Screen y-coordinate for sprite 63 |
ySprite7 (Common) | Workspace variable | Screen y-coordinate for sprite 7 |
ySprite8 (Common) | Workspace variable | Screen y-coordinate for sprite 8 |
ySprite9 (Common) | Workspace variable | Screen y-coordinate for sprite 9 |
Yx2M1 (Common) | Workspace variable | The height of the drawable part of the screen in pixels minus 1, often used when calculating the y-coordinate of the bottom pixel row of the space view |
YY (Common) | Workspace variable | Temporary storage, typically used for storing a 16-bit y-coordinate |
Ze (Bank 7) | Universe | Initialise the INWK workspace to a hostile ship |
ZERO (Bank 0) | Utility routines | Reset the local bubble of universe and ship status |
ZINF (Bank 0) | Universe | Reset the INWK workspace and orientation vectors |
ZINF_b1 (Bank 1) | Universe | Reset the INWK workspace and orientation vectors |
ZP (Common) | Workspaces | Lots of important variables are stored in the zero page workspace as it is quicker and more space-efficient to access memory here |
ZZ (Common) | Workspace variable | Temporary storage, typically used for distance values |
zZ+1 (Bank 0) | Flight | Contains an RTS |