This index contains every subroutine, entry point, variable and workspace that appears in the source code for The Sentinel, sorted alphabetically.
| Name | Category | Description |
|---|---|---|
| AbortWhenVisible | Gameplay | Abort applying the tactics for this gameplay loop if updating the object on-screen will corrupt a screen pan |
| Absolute16Bit | Maths (Arithmetic) | Calculate the absolute value (modulus) of a 16-bit number |
| activateSentinel | Workspace variable | A flag to record when the Sentinel is activated at the start of the game (by the player pressing a key that expends or absorbs energy |
| AddEnemiesToTiles | Landscape | Add the required number of enemies to the landscape, starting from the highest altitude and working down, with one enemy per contour |
| AddVectorToCoord | Maths (Geometry) | Add a vector to a coordinate |
| aHi | Workspace variable | The high byte of the adjacent side of a triangle when calculating the hypotenuse |
| aLo | Workspace variable | The low byte of the adjacent side of a triangle when calculating the hypotenuse |
| AlterCrackerSeed | Cracker protection | Create an altered version of the anti-cracker seed-related data, as part of the anti-cracker code |
| alteredSeed | Workspace variable | An altered version of the anti-cracker seed-related data that gets created in AlterCrackerSeed and checked in CheckCreckerSeed as part of the anti-cracker code |
| angleHi | Workspace variable | The low byte of an angle |
| angleLo | Workspace variable | The high byte of an angle |
| angleTangent | Workspace variable | The tangent of an angle in a right-angled triangle |
| ApplyEnemyTactics | Gameplay | Apply tactics to an enemy object, setting things up so the next call applies tactics to the next enemy object |
| ApplyTactics (Part 1 of 8) | Gameplay | Apply tactics to the Sentinel or a sentry |
| ApplyTactics (Part 2 of 8) | Gameplay | Process the tactics for a meanie |
| ApplyTactics (Part 3 of 8) | Gameplay | If the enemy has any residual energy, try expending it onto the landscape in the form of a tree (and end tactics if successful) |
| ApplyTactics (Part 4 of 8) | Gameplay | If configured, search the landscape for a suitable target for the enemy to drain of energy |
| ApplyTactics (Part 5 of 8) | Gameplay | Look for a suitable robot to drain of energy, or look for a drainable tree or boulder if there are no suitable robots |
| ApplyTactics (Part 6 of 8) | Gameplay | Rotate the enemy and make a rotation sound |
| ApplyTactics (Part 7 of 8) | Gameplay | Drain energy from the enemy's target object, or try scanning for a tree to turn into a meanie if the target's tile is obscured |
| ApplyTactics (Part 8 of 8) | Gameplay | Redraw the object on the screen, optionally with a dithered effect |
| arctanHi | Maths (Geometry) | Table for arctan values when calculating yaw angles (high byte) |
| arctanLo | Maths (Geometry) | Table for arctan values when calculating yaw angles (low byte) |
| aStoreEnvelope | Sound | Temporary storage for use in the DefineEnvelope routine |
| backgroundEven | Graphics | Pixel bytes for even pixel rows in the screen background |
| backgroundOdd | Graphics | Pixel bytes for odd pixel rows in the screen background |
| bHi | Workspace variable | The high byte of the opposite side of a triangle when calculating the hypotenuse |
| bitMask | Workspace variable | Used to return a bit mask from the GetTilesAtAltitude routine that has a matching number of leading zeroes as the number of tile blocks at a specific altitude |
| bitMaskDither | Workspace variable | A bit mask for use in the DitherScreenBuffer routine that has a matching number of leading zeroes as the size of the screen buffer in bytes |
| blackDotCounter | Workspace variable | A counter for black dots that are drawn in the screen decaying routine |
| blendPolygonEdges | Workspace variable | A flag to determine whether polygon edges are drawn in the same colour as the polygon fill, thus blending the edges into the polygon body |
| bLo | Workspace variable | The low byte of the opposite side of a triangle when calculating the hypotenuse |
| boulderOnTile | Workspace variable | A flag to record whether the tile being analysed in the GetTileAltitude routine contains a boulder |
| buff1 | Screen buffer | Contains an RTS |
| bufferColumns | Workspace variable | The number of character columns in the current screen buffer |
| bufferMaxPitch | Screen buffer | Maximum allowed pitch angles for points in the screen buffer |
| bufferMaxYawHi | Workspace variable | The maximum allowed yaw angle for points in the current screen buffer (high byte) |
| bufferMinPitch | Screen buffer | Minimum allowed pitch angles for points in the screen buffer |
| bufferMinYawHi | Workspace variable | The minimum allowed yaw angle for points in the current screen buffer (high byte) |
| bufferMinYawLo | Workspace variable | The minimum allowed yaw angle for points in the current screen buffer (low byte) |
| bufferOriginHi | Workspace variable | The offset to add to yaw angles for the current screen buffer to convert them from having the origin in the buffer centre to having the origin on the left edge of the buffer (high byte) |
| bufferOriginLo | Workspace variable | The offset to add to yaw angles for the current screen buffer to convert them from having the origin in the buffer centre to having the origin on the left edge of the buffer (low byte) |
| bufferRowAddrHi | Screen buffer | Address lookup table for character rows in the screen buffer (high byte) |
| bufferRowAddrLo | Screen buffer | Address lookup table for character rows in the screen buffer (low byte) |
| buffersMinYaw | Screen buffer | Minimum allowed yaw angles for points in the screen buffer |
| buffersOffsetHi | Screen buffer | An offset to add to the address of the right column screen buffer (low byte) |
| buffersOffsetLo | Screen buffer | An offset to add to the address of the right column screen buffer (low byte) |
| buffersOrigin | Screen buffer | The offset to add to yaw angles for each screen buffer to convert from the origin in the buffer centre to the origin on the left |
| bufferWidthBytes | Workspace variable | The width of the screen buffer in pixel bytes for implementing the dithered effect in DitherScreenBuffer |
| characterDef | Workspace variable | An OSWORD block for reading a character definition |
| CheckCrackerSeed | Cracker protection | Check whether the anti-cracker seed-related data is correctly set up, as part of the anti-cracker code |
| CheckEnemyGaze (Part 1 of 2) | Gameplay | Check to see whether the current enemy can see a specific target object of a specific type |
| CheckEnemyGaze (Part 2 of 2) | Gameplay | Calculate whether the current enemy can see the specified object |
| CheckForKeyPresses | Keyboard | Check for various game key presses and update the key logger and relevant variables (during the interrupt handler) |
| CheckForSamePanKey | Keyboard | Check to see whether the same pan key is being held down compared to the last time we checked |
| CheckForTileCentre | Maths (Geometry) | Calculate max(|xCoordLo - 128|, |zCoordLo - 128|) |
| CheckObjVisibility | Drawing objects | Check whether an object is visible on-screen and should therefore not be changed if a pan operation is about to happen |
| CheckSecretCode (Part 1 of 2) | Landscape | Generate the secret code for this landscape and optionally check it against the entered code in the keyboard input buffer |
| CheckSecretCode (Part 2 of 2) | Landscape | Check the results of the secret code matching process, and if the secret codes match, jump to PlayGame to play the game |
| CheckSecretStash | Cracker protection | Check whether the secret code stash is correctly set up, as part of the anti-cracker code |
| ClearIconsScanner | Scanner/energy row | Clear the energy icon and scanner row at the top of the screen |
| ClearMemory | Setup | Clear game memory, so that the BREAK key can remove all trace of the game code in early versions of the operating system |
| clearPixelMask | Graphics | A table for converting a pixel number in the range 0 to 3 into a screen mode 5 bit mask with that pixel's bits clear and others set |
| ClearScreen | Graphics | Clear the screen to a specified background |
| colourPalettes | Graphics | The logical colours for two mode 5 palettes |
| colourPixels | Graphics | A table that maps logical colours 0 to 3 to a four-pixel byte in that colour |
| columnCounter | Workspace variable | A counter for the number of columns to fill in the FillScreen routine |
| ConfigureBuffer | Screen buffer | Set up the variables required to configure the screen buffer to a specific buffer type |
| ConfigureMachine | Setup | Configure the custom screen mode, set the break handler to clear memory, move code, reset timers and set the interrupt handler |
| ConfigureObjBuffer | Screen buffer | Set up the variables required to configure the screen buffer for updating an object |
| considerObjects | Workspace variable | Controls whether the GetTileAltitude routine takes platform objects into consideration when calculating tile altitudes (bit 7) and returns details about the gaze vector (bit 6) |
| CorruptSecretCode | Cracker protection | Corrupt the generation process for the landscape's secret code by fetching one more seed number than necessary |
| cosA | Workspace variable | The result of the cos(A) calculation in the GetSineAndCosine routine |
| cosAngleHi | Workspace variable | The high byte of the cosine of a pitch or yaw angle, as calculated by the GetRotationMatrix routine |
| cosAngleLo | Workspace variable | The low byte of the cosine of a pitch or yaw angle, as calculated by the GetRotationMatrix routine |
| cosVectorPitchHi | Workspace variable | The high byte of cos(vectorPitchAngle) when converting pitch and yaw angles to cartesian vectors |
| cosVectorPitchLo | Workspace variable | The low byte of cos(vectorPitchAngle) when converting pitch and yaw angles to cartesian vectors |
| CrackerSeed | Cracker protection | Obfuscated storage for the high byte of the landscape number as part of the anti-cracker code |
| currentObject | Workspace variable | The number of the object we are currently processing |
| currentPixelByte | Workspace variable | The original contents of the screen behind the right edge of the polygon being drawn |
| cvis1 | Drawing objects | Contains an RTS |
| DecayScreenToBlack | Graphics | Smother the screen with randomly placed black dots to decay the screen to black |
| DefineEnvelope | Sound | Define a sound envelope |
| DeleteObject | 3D objects | Delete an object, removing it from the landscape and vacating its object number |
| DigitToNumber | Text | Convert a digit from the input buffer into a number |
| ditherInnerLoop | Workspace variable | A counter for the inner loop when dithering objects to the screen in the DitherScreenBuffer routine |
| ditherObjectSights | Workspace variable | Configures how an updated object is drawn onto the screen in the DrawUpdatedObject routine |
| ditherOuterLoop | Screen buffer | A counter for the inner loop when dithering objects to the screen in the DitherScreenBuffer routine |
| ditherRandom | Workspace variable | Storage for a random value in the DitherScreenBuffer routine |
| DitherScreenBuffer | Screen buffer | Dither the contents of the screen buffer onto the screen |
| ditherStore | Workspace variable | Temporary storage for use in the DitherScreenBuffer routine |
| DivideBy16 | Maths (Arithmetic) | Divide a 16-bit sign-magnitude number by 16 |
| doNotCheckSecret | Workspace variable | A flag to control whether we perform the secret code check that's buried in the GetRowVisibility routine |
| doNotDitherObject | Workspace variable | Controls whether the DitherScreenBuffer routine can update an object on the screen using a dithered effect |
| doNotDrawSights | Workspace variable | A flag that controls whether we draw the sights in the DrawSights routine |
| doNotPlayLandscape | Workspace variable | A flag that controls whether we preview and play the landscape after generating it |
| dotColour | Graphics | A flag that determines the colour of the dots drawn by the DrawRandomDots routine |
| dotCounter | Graphics | A counter for the number of dots drawn in the DrawRandomDots routine |
| DrainObjectEnergy | Gameplay | Drain energy from an object into an enemy, transforming it into an object with an energy level of one unit less (if applicable) |
| DrawBlackDots | Graphics | Draw 80 randomly positioned dots on the screen in colour 1 (black) |
| DrawFlatTile | Drawing the landscape | Draw a flat tile in the correct colour for the chess board effect that we use to draw the landscape |
| DrawIcon | Scanner/energy row | Draw a single icon in the top-left corner of the screen (via the icon screen buffer at iconBuffer) and move along to the right |
| drawingPhase | Workspace variable | The number of the current drawing phase when drawing two-phase objects: |
| drawingPhaseCount | Workspace variable | A phase counter for objects that need to be drawn in multiple phases |
| drawingTableIndex | Workspace variable | The index into the drawing tables for the tile being analysed |
| drawingTableOffset | Workspace variable | The offset to use within the various drawing data tables for the tile we are analysing |
| drawingTitleScreen | Workspace variable | A flag to indicate whether we are currently drawing a title screen in the DrawTitleScreen routine |
| drawLandscape | Workspace variable | Configures whether to draw the landscape behind the object in the DrawUpdatedObject routine |
| DrawLandscapeRow | Drawing the landscape | Draw a row of tiles between the left visible edge and the right visible, in two parts towards each side of the viewer |
| DrawLandscapeView (Part 1 of 3) | Drawing the landscape | Set up a number of variables for drawing the landscape view |
| DrawLandscapeView (Part 2 of 3) | Drawing the landscape | Work through the landscape, drawing one row of tiles/objects at a time, from the back row to the front row |
| DrawLandscapeView (Part 3 of 3) | Drawing the landscape | Draw a tile row in two parts, one on either side of the viewer |
| DrawObject | Drawing objects | Draw a 3D object |
| DrawObjectStack | Drawing objects | Draw an entire stack of objects |
| DrawOneFaceTile | Drawing the landscape | Draw a tile with one quadrilateral (four-sided) face |
| DrawPolygon | Drawing polygons | Draw a polygon |
| drawPolygon | Workspace variable | A flag to record whether the polygon we are currently processing contains any visible pixels, so it can be used to control whether we actually draw the polygon |
| DrawPolygonLines (Part 1 of 4) | Drawing polygons | Draw an analysed polygon into the screen buffer |
| DrawPolygonLines (Part 2 of 4) | Drawing polygons | Process the line overflowing the sides of the buffer, or fitting into one pixel byte, and loop on to the next polygon pixel line |
| DrawPolygonLines (Part 3 of 4) | Drawing polygons | Draw the left and right edges of the polygon line and fall into part 4 to draw the line in between |
| DrawPolygonLines (Part 4 of 4) | Drawing polygons | Draw a horizontal pixel line of a specific length in character columns |
| DrawRandomDots | Graphics | Draw 80 randomly positioned dots on the screen |
| DrawSights | Sights | Draw the sights on the screen, saving the existing screen contents in the sights pixel byte stash |
| DrawSlopingTile | Drawing the landscape | Draw a sloping tile that is not shape 4 or 12 |
| DrawStars | Graphics | Draw 80 randomly positioned stars on the screen in colour 2 (white, yellow, cyan or red) |
| DrawTileAndObjects | Drawing the landscape | Draw a tile and any objects stacked on it |
| DrawTitleObject | Title screen | Draw an object on the title screen |
| DrawTitleObjects | Title screen | Draw an object on top of a tower on the title screen |
| DrawTitleScreen | Title screen | Draw the title screen or the screen showing the secret code |
| DrawTitleView | Title screen | Draw the main title screen, the secret code screen or the landscape preview |
| DrawTwoFaceTile | Drawing the landscape | Draw a tile with two triangular (three-sided) faces |
| DrawUpdatedObject | Drawing objects | Draw an updated object on-screen, optionally with a dithered effect, and with or without the surrounding landscape |
| drawViewAngles | Workspace variable | The address in drawViewAngles(1 0) of the pitch and yaw angles of the tile and polygon points that we are drawing in the landscape view |
| drawViewPitchHi | Drawing the landscape | Storage for the pitch angles of tiles and object points for drawing the current landscape view (high bytes) |
| drawViewPitchLo | Drawing the landscape | Storage for the pitch angles of tiles and object points for drawing the current landscape view (low bytes) |
| drawViewYawHi | Drawing the landscape | Storage for the yaw angles of tiles and object points for drawing the current landscape view (high bytes) |
| drawViewYawLo | Drawing the landscape | Storage for the yaw angles of tiles and object points for drawing the current landscape view (low bytes) |
| drow3 | Screen buffer | Contains an RTS |
| edgeGazeDistance | Workspace variable | The fractional distance along a tile edge that matches the current position along the gaze vector |
| edgePixelsLeft | Drawing polygons | Table to convert a polygon colours byte and a pixel offset (0-3) into a pixel byte for the left edge of the polygon pixel line |
| edgePixelsRight | Drawing polygons | Table to convert a polygon colours byte and a pixel offset (0-3) into a pixel byte for the right edge of the polygon pixel line |
| EnableKeyboard | Keyboard | Select the keyboard as the input stream and flush the keyboard buffer |
| enemyCheckingRobot | Workspace variable | A flag to pass to the FollowGazeVector routine, with bit 7 set if the routine is being called when an enemy is checking to see if it can see a robot object |
| enemyCounter | Workspace variable | Used as a loop counter when adding enemies to the landscape |
| enemyDrainScan | Workspace variable | Enemy will perform a scan for a drainable object (one |
| enemyDrainTimer | Workspace variable | A timer for each enemy that counts down every 0.06 |
| enemyEnergy | Workspace variable | Enemy energy levels (one byte per enemy) |
| enemyFailCounter | Workspace variable | Enemy failed to find meanie: counter (one byte per |
| enemyFailTarget | Workspace variable | Enemy failed to find meanie: target object (one byte |
| enemyMeanieScan | Workspace variable | Enemy meanie scan object counter (one byte per enemy) |
| enemyMeanieTree | Workspace variable | Enemy has turned a tree into a meanie (one byte per |
| enemyObject | Workspace variable | The object number of the enemy to which we are applying tactics in this iteration around the main loop (0-7) |
| enemyRotateTimer | Workspace variable | A timer for each enemy that counts down every 0.06 |
| enemyTacticTimer | Workspace variable | A timer for each enemy that counts down every 0.06 |
| enemyTarget | Workspace variable | The object number of the enemy's target (one byte per |
| enemyViewingArc | Workspace variable | The viewing arc of the enemy that is being processed in the ApplyTactics routine |
| enemyVisibility | Workspace variable | Visibility of the enemy's target (one byte per enemy) |
| enemyYawStep | 3D objects | The yaw angle through which each enemy rotates on each scheduled rotation |
| Entry | Setup | The main entry point for the game |
| envelopeData | Sound | Data for the six sound envelopes |
| envelopeVolumes | Sound | A table of offsets into the envelope data for bytes that control the volume of each envelope, so we can change their volume levels |
| evenVisibility | Workspace variable | The visibility of tiles corners in even rows as they are processed by the GetRowVisibility routine |
| ExpendEnemyEnergy | Gameplay | Drain one unit of energy from an enemy and expend it onto the landscape by spawning a tree, if possible |
| fillRowNumber | Workspace variable | The number of the character row we are currently filling in the FillScreen routine |
| FillScreen | Graphics | Fill a rectangular in screen memory or the screen buffer with the specified background |
| FindObjectToDrain | Gameplay | Find a suitable target object for an enemy to drain |
| FinishEnemyTactics | Gameplay | Stop applying tactics to the current enemy and return to the ProcessGameplay routine to continue with the gameplay loop |
| FinishLandscape | Main game loop | Add the player's energy to the landscape number to get the number of the next landscape and display that landscape's secret code |
| FlipBufferType | Screen buffer | Flip the buffer type between buffer type 0 (left row buffer) and buffer type 1 (right row buffer) |
| FlushBuffer | Keyboard | Flush the specified buffer |
| FlushSoundBuffer0 | Sound | Flush the sound channel 0 buffer |
| FlushSoundBuffers | Sound | Flush all four sound channel buffers |
| focu1 | Keyboard | Store the current setting of focusOnKeyAction in the previousFocus variable so we can detect (in the ProcessGameplay routine) whether the player is still holding down a pan key after we finish scrolling the screen for the previous pan... and then return from the subroutine |
| FocusOnKeyAction | Keyboard | Tell the game to start focusing effort on the action that has been initiated, such as a pan of the landscape, absorb, transfer etc. |
| focusOnKeyAction | Workspace variable | A flag that determines whether the game should focus effort on implementing a key action, such as a pan of the landscape view |
| FollowGazeVector (Part 1 of 5) | Maths (Geometry) | Follow a gaze vector from a viewing object to determine whether the viewer can see a flat tile or platform (i.e. boulder or tower) |
| FollowGazeVector (Part 2 of 5) | Maths (Geometry) | Calculate the altitudes of the four corners in a non-flat tile |
| FollowGazeVector (Part 3 of 5) | Maths (Geometry) | Calculate whether the viewing object's gaze is obstructed by a tile of shape 4 or 12 (i.e. a tile with one horizontal edge) |
| FollowGazeVector (Part 4 of 5) | Maths (Geometry) | For non-flat tiles with two horizontal edges, work out which tile edge to use when checking for obstruction of the gaze vector |
| FollowGazeVector (Part 5 of 5) | Maths (Geometry) | For non-flat tiles with two horizontal edges, work out whether the tile edge obstructs the gaze vector |
| fromAddr | Workspace variable | An address, typically used as a source address when copying |
| G | Workspace variable | Temporary storage, used in a number of places |
| G2 | Workspace variable | Temporary storage, used in the maths routines from Revs, where the original variable name was G (this variable has been renamed to G2 to prevent a clash with the G variable that is used by The Sentinel) |
| game10 | Main game loop | Jump to MainTitleLoop to restart the game |
| gameInProgress | Workspace variable | Flags whether or not a game is in progress (i.e. the player is playing a landscape rather than interacting with the title and preview screens) |
| gameKeys | Keyboard | Negative inkey values for the game keys |
| gameOverSoundPitch | Workspace variable | A timer for the game over sound |
| gamePaused | Workspace variable | A flag to record whether the game is paused |
| gameplayStack | Workspace variable | The value of the stack pointer at the start of the ApplyEnemyTactics routine, so we can return back to the ProcessGameplay routine from deep within the tactics routines if required |
| gazeCanSeeTree | Workspace variable | A flag to record whether the gaze vector can see a tree: |
| gazeCheckCounter | Workspace variable | A counter for the number of checks that are performed when following an enemy's gaze in CheckEnemyGaze |
| GenerateLandscape | Landscape | Generate tile data for the landscape |
| GetAngleFromCoords (Part 1 of 3) | Maths (Geometry) | Given the coordinates along two axes, calculate the pitch or yaw angle to those coordinates |
| GetAngleFromCoords (Part 2 of 3) | Maths (Geometry) | Overflow and accuracy calculations |
| GetAngleFromCoords (Part 3 of 3) | Maths (Geometry) | Calculate the arctangent to get the angle |
| GetAngleInRadians | Maths (Geometry) | Convert a 16-bit angle into radians, restricted to a quarter circle |
| GetEnemyCount | Landscape | Calculate the number of enemies for the current landscape |
| GetHighestTiles | Landscape | Calculate both the highest tiles in each 4x4 block of tiles in the landscape and the altitude of the highest tile in the landscape |
| GetHorizontalDelta | Maths (Geometry) | Calculate the difference in the x-axis and z-axis between two objects, as both signed and absolute deltas |
| GetHypotenuse | Maths (Geometry) | Calculate the hypotenuse from an angle and two triangle sides with one lookup and one multiplication (so without a square root) |
| GetHypotenuseAngle | Maths (Geometry) | Calculate the angle of the hypotenuse in a right-angle triangle given the two non-hypotenuse sides (i.e. two orthogonal axes) |
| GetIconRowAddress | Scanner/energy row | Calculate the address in screen memory of the icon and scanner row at the top of the screen |
| GetNextSeed0To22 | Maths (Arithmetic) | Set A to the next number from the landscape's sequence of seed numbers, converted to the range 0 to 22 |
| GetNextSeed0To30 | Maths (Arithmetic) | Set A to the next number from the landscape's sequence of seed numbers, converted to the range 0 to 30 |
| GetNextSeedAsBCD | Maths (Arithmetic) | Set A to the next number from the landscape's sequence of seed numbers, converted to a binary coded decimal (BCD) number |
| GetNextSeedNumber | Maths (Arithmetic) | Set A to a seed number |
| GetObjectAngles | 3D objects | Calculate the angles and distances of the vector from the viewer to a specific object |
| GetObjectCoords | 3D objects | Get an object's coordinates |
| GetObjPointAngles | Drawing objects | Calculate the view-relative pitch and yaw angles of all the points in an object |
| GetObjVisibility | Gameplay | Calculate whether any part of an object is visible on-screen, and if so, which character columns it spans on the screen |
| GetPitchAngleDelta | Maths (Geometry) | Calculate the pitch angle of a vector relative to an object's pitch angle |
| GetPlayerDrain | Gameplay | Calculate whether the player is being scanned by an enemy and whether the enemy can see the player's tile |
| GetPlayerEnergyBCD | Maths (Arithmetic) | Fetch the player's energy in binary coded decimal (BCD) |
| GetPolygonLines (Part 1 of 6) | Drawing polygons | Calculate the points in a two-face tile polygon when it consists of a pair of triangles |
| GetPolygonLines (Part 2 of 6) | Drawing polygons | The main entry point for the routine to calculate the horizontal lines in filled polygon and prepare them for drawing on-screen |
| GetPolygonLines (Part 3 of 6) | Drawing polygons | Convert all the polygon point yaw angles into pixel x-coordinates (for larger yaw angles that convert into a 16-bit x-coordinate) |
| GetPolygonLines (Part 4 of 6) | Drawing polygons | Convert all the polygon point yaw angles into pixel x-coordinates (for smaller yaw angles that convert into an 8-bit x-coordinate) |
| GetPolygonLines (Part 5 of 6) | Drawing polygons | Loop through all the edges in the polygon and call the correct routines to process one-byte, two-byte or horizontal edges |
| GetPolygonLines (Part 6 of 6) | Drawing polygons | Split polygon edges whose coordinates are stored in two-byte numbers into smaller sections for processing |
| GetRandomNumber | Maths (Arithmetic) | Set A to a random number |
| GetRotationMatrix (Part 1 of 5) | Maths (Geometry) | Calculate the rotation matrix for rotating the pitch or yaw angle for the sights into the global 3D coordinate system |
| GetRotationMatrix (Part 2 of 5) | Maths (Geometry) | Calculate sin(H G) for smaller angles |
| GetRotationMatrix (Part 3 of 5) | Maths (Geometry) | Calculate sin(H G) for bigger angles |
| GetRotationMatrix (Part 4 of 5) | Maths (Geometry) | Loop back to calculate cos instead of sin |
| GetRotationMatrix (Part 5 of 5) | Maths (Geometry) | Apply the correct signs to the result |
| GetRowVisibility (Part 1 of 2) | Drawing the landscape | Set up the calculations to determine whether each tile corner in a tile row is obscured from the player by any intervening landscape |
| GetRowVisibility (Part 2 of 2) | Drawing the landscape | Calculate whether each tile corner in a tile row is obscured from the player by any intervening landscape |
| GetSightsVector | Maths (Geometry) | Calculate the angles of the vector from the player's eyes to the sights |
| GetSineAndCosine | Maths (Geometry) | Calculate the sine and the cosine of an angle |
| GetTileAltitude | Landscape | Calculate the altitude of a tile, optionally including platform objects and trees in the calculation |
| GetTileAltitudes | Drawing the landscape | Calculate tile corner altitudes and maximum tile corner altitudes for each tile in the landscape |
| GetTileData | Landscape | Get the tile data and tile data address for a specific tile |
| GetTileEdgeToLeft | Drawing the landscape | Move one tile to the left along the tile row that we are analysing for view edges and tile angles |
| GetTileEdgeToRight | Drawing the landscape | Move one tile to the right along the tile row that we are analysing for view edges and tile angles |
| GetTilesAtAltitude | Landscape | Return a list of tile blocks at a specified altitude |
| GetTileShape | Landscape | Calculate the shape of the tile anchored at (xTile, zTile) |
| GetTileViewAngles (Part 1 of 4) | Drawing the landscape | Calculate the pitch and yaw angles for a tile corner, relative to a viewer object (e.g. the player), and whether it is on-screen |
| GetTileViewAngles (Part 2 of 4) | Drawing the landscape | Fetch the tile data for the tile corner we are analysing |
| GetTileViewAngles (Part 3 of 4) | Drawing the landscape | Calculate the pitch angle for the tile corner |
| GetTileViewAngles (Part 4 of 4) | Drawing the landscape | Calculate how much of the tile is on-screen |
| GetTileViewEdges | Drawing the landscape | For a given tile row, work out the edges of the visible portion of the row in the current player view, as left to right tile numbers |
| GetTileVisibility | Drawing the landscape | For each tile in the landscape, calculate whether the player can see that tile, to speed up the process of drawing the landscape |
| GetVectorForAngles | Maths (Geometry) | Convert a vector from pitch and yaw angles into a 3D cartesian vector |
| GetVerticalDelta | Maths (Geometry) | Calculate the difference in the y-axis between two objects as a signed delta |
| H | Workspace variable | Temporary storage, used in the maths routines |
| H2 | Workspace variable | Temporary storage, used in the maths routines from Revs, where the original variable name was H (this variable has been renamed to H2 to prevent a clash with the H variable that is used by The Sentinel) |
| highestPitchAngle | Sights | The pitch angle of the highest point that the player can look at with the sights |
| horizontalEdges | Workspace variable | A counter to keep track of how many polygon edges are horizontal in the polygon we are drawing |
| hyperspaceEndsGame | Workspace variable | Records whether the player performing a hyperspace has just ended the game |
| hypotenuseHi | Workspace variable | The high byte of the hypotenuse of a triangle |
| hypotenuseLo | Workspace variable | The low byte of the hypotenuse of a triangle |
| iconBuffer | Graphics | The icon screen buffer, which is used to buffer the energy icon and scanner row before writing to screen memory |
| iconData | Graphics | Screen mode 5 bitmap data for the ten icons that make up the energy icon and scanner row at the top of the screen |
| iconRowAddr | Workspace variable | The screen address of the icon and scanner row along the top of the screen |
| InitialiseSeeds | Landscape | Initialise the seed number generator so it generates the sequence of seed numbers for a specific landscape number |
| InitialiseSights | Sights | Initialise the variables used to manage the sights, so the sights appear in the middle of the screen |
| inputBuffer | Workspace variable | The eight-byte keyboard input buffer |
| irq1Address | Main game loop | Stores the previous value of IRQ1V before we install our custom IRQ handler |
| IRQHandler | Main game loop | The main interrupt handler, which gets run 50 times a second to update the game state and check for game key presses |
| J | Workspace variable | Temporary storage, used in the maths routines from Revs |
| JumpToPreview | Cracker protection | An intentionally confusing jump point for controlling the main title loop flow when returning from the GenerateLandscape routine |
| keepCheckingPanKey | Workspace variable | Controls whether the DrawLandscapeView routine aborts drawing if the pan key is released before it has finished |
| keyLogger | Workspace variable | The four-byte key logger for logging game key presses |
| keyLoggerConfig | Keyboard | The configuration table for storing keys the key logger |
| keyPress | Workspace variable | The key logger value for a key press |
| landscapeColour2 | Landscape | Physical colours for colour 2 in the game palette for the different numbers of enemies |
| landscapeColour3 | Landscape | Physical colours for colour 3 in the game palette for the different numbers of enemies |
| landscapeNumberHi | Workspace variable | The high byte of the four-digit binary coded decimal landscape number (0000 to 9999) |
| landscapeNumberLo | Workspace variable | The low byte of the four-digit binary coded decimal landscape number (0000 to 9999) |
| landscapeZero | Workspace variable | A flag that is set depending on whether we are playing landscape 0000 |
| lastPanKeyPressed | Workspace variable | The direction of the last pan key that was pressed (which may not still be held down) |
| lastScannerState | Workspace variable | The state of the scanner the last time that it was updated: |
| latestPanKeyPress | Workspace variable | The key logger value of the latest pan key press, which will either be a current key press or the value from the last pan key press to be made |
| leadingBitMask | Landscape | A table for converting the number of leading clear bits in a number into a bit mask with the same number of leading zeroes |
| leftPixels | Graphics | Pixel byte with all the pixels to the right of position X + 1 set, to give the complementary pixel byte to pixelsToRight |
| loopCounter | Workspace variable | A general-purpose loop counter |
| lowestPitchAngle | Sights | The pitch angle of the lowest point that the player can look at with the sights |
| lowNibbleBCD | Maths (Arithmetic) | Storage for the low nibble when constructing a BCD seed number in the GetNextSeedAsBCD routine |
| Main variable workspace | Workspaces | The main block of game variables |
| main1 | Main title loop | The entry point for rejoining the main title loop after the player enters an incorrect secret code |
| main4 | Main title loop | The entry point for restarting a landscape after dying, so the player doesn't have to enter the landscape's secret code again |
| MainGameLoop | Main game loop | The main game loop for playing a landscape |
| MainTitleLoop | Main title loop | The main title loop: display the title screen, fetch the landscape number/code, preview the landscape and jump to the main game loop |
| MainTitleLoop-1 | Main title loop | Contains an RTS |
| MakeSound | Sound | Make a sound |
| MakeSound-6 | Sound | Make a two-part sound at the pitches defined in X and Y, where X is the pitch for sound data block #0 and Y is the pitch for sound data block #1 |
| MakeSoundEnvelope | Sound | Either make a sound or set up an envelope |
| maxAltitude | Landscape | The maximum tile altitude for each 4x4 block of tiles |
| maxNumberOfEnemies | Workspace variable | The maximum number of enemies that can appear on the current landscape, which is calculated as follows: |
| maxPitchAngle | Workspace variable | The maximum pitch angle that fits into the current screen buffer |
| meanieYawStep | Workspace variable | The yaw angle through which we rotate a meanie as it searches for the player in the ApplyTactics routine |
| minEnemyAltitude | Workspace variable | The altitude of the lowest enemy on the landscape |
| minObjWidth | Workspace variable | The on-screen width to use when updating objects |
| minPitchAngle | Workspace variable | The minimum pitch angle that fits into the current screen buffer |
| ModifyStoringCode | Drawing polygons | Modify the code in TracePolygonEdge that stores the coordinates of the polygon edge that is being traced |
| moreColumnsToFill | Workspace variable | Stores the number of extra columns we need to fill in the FillScreen routine after filling up to 32 columns |
| MoveOnToNextEnemy | Gameplay | Update enemyObject so the next time we consider applying enemy tactics, we apply them to the next enemy, looping from 7 to 0 |
| MoveSights | Sights | Check for up/down/left/right key presses and move the sights accordingly, panning the screen if they go past the screen edges |
| MoveSightsSideways | Sights | Check for the left/right keys and move the sights accordingly, panning to the left or right if they go past the screen edges |
| MoveSightsUpDown | Sights | Check for the up/down keys and move the sights accordingly, panning up or down if they go past the screen edges |
| Multiply16x16 | Maths (Arithmetic) | Multiply a sign-magnitude 16-bit number and a signed 16-bit number |
| Multiply8x16 | Maths (Arithmetic) | Multiply an 8-bit and a 16-bit number |
| Multiply8x8 | Maths (Arithmetic) | Calculate (A T) = T * U |
| Multiply8x8+2 | Maths (Arithmetic) | Calculate (A T) = T * U |
| MultiplyCoords | Maths (Arithmetic) | Multiply a 16-bit signed number and a 16-bit sign-magnitude value |
| musicCounter | Workspace variable | A counter for the music currently being made, which counts up in the ProcessMusic routine while the music is being played |
| musicData | Sound | Data for the game's music |
| Negate16Bit | Maths (Arithmetic) | Negate a 16-bit number |
| Negate16Bit+2 | Maths (Arithmetic) | Set (A T) = -(U T) |
| NMIHandler | Setup | The NMI handler at the start of the NMI workspace |
| noteCounter | Workspace variable | The sound counter for an individual note while playing chords in the music player |
| numberOfEnemies | Workspace variable | The number of enemies in the current landscape, including the Sentinel (in the range 1 to 8) |
| numberOfScrolls | Workspace variable | The total number of scrolls that we need to perform for the current panning operation |
| objBlockNumber | Title screen | A lookup table to convert bit pairs into object numbers for spawning 3D text blocks on the landscape |
| objBoulder | Drawing objects | The list of polygons and points for the boulder object (polygons 67 to 76, using points 68 to 75) |
| objectAdjacentHi | Workspace variable | The distance of an object from the viewer, expressed as the length of the adjacent side in a triangle with the vector from the viewer to the object as the hypotenuse (high byte) |
| objectAdjacentLo | Workspace variable | The distance of an object from the viewer, expressed as the length of the adjacent side in a triangle with the vector from the viewer to the object as the hypotenuse (low byte) |
| objectFlags | Workspace variable | Object flags for up to 64 objects |
| objectGazeYawHi | Workspace variable | The difference in the yaw angle of the viewer's gaze and the yaw angle (i.e. the gaze) of the object being analysed (low byte) |
| objectGazeYawLo | Workspace variable | The difference in the yaw angle of the viewer's gaze and the yaw angle (i.e. the gaze) of the object being analysed (low byte) |
| objectHalfWidth | Gameplay | Each object's width in terms of tile widths, for half the object |
| objectLastPoint | Workspace variable | The number of the last point in the object being drawn |
| objectLastPolygon | Workspace variable | The number of the last polygon in the object being drawn |
| objectOppositeHi | Workspace variable | The height of an object relative to the viewer, expressed as the length of the opposite side in a triangle with the vector from the viewer to the object as the hypotenuse (high byte) |
| objectOppositeLo | Workspace variable | The height of an object relative to the viewer, expressed as the length of the opposite side in a triangle with the vector from the viewer to the object as the hypotenuse (low byte) |
| objectPitchAngle | Workspace variable | The pitch angle for each object (i.e. the vertical direction in which they are facing) |
| objectStackCounter | Workspace variable | A counter for the objects in an object stack, for use when drawing the stack |
| objectToAnalyse | Workspace variable | The number of the object to analyse in the GetObjectAngles routine |
| objectType | Workspace variable | The type of object that we are spawning |
| objectTypeEnergy | 3D objects | The amount of energy required to create each object or the amount energy acquired when absorbing each object |
| objectTypes | 3D objects | The object types table for up to 64 objects |
| objectViewYawHi | Workspace variable | The yaw angle of the object being analysed, relative to the current viewer (high byte) |
| objectViewYawLo | Workspace variable | The yaw angle of the object being analysed, relative to the current viewer (low byte) |
| objectYawAngle | 3D objects | The yaw angle for each object (i.e. the horizontal direction in which they are facing) |
| objMeanie | Drawing objects | The list of polygons and points for the meanie object (polygons 77 to 101, using points 76 to 93) |
| objPointDistance | Drawing objects | Polar distances for each of the points in each of the objects |
| objPointHeight | Drawing objects | The height of each of the points in each of the objects, relative to the object's origin |
| objPointRange | Drawing objects | The first and last point numbers for each object |
| objPointYaw | Drawing objects | Polar yaw angles for each of the points in each of the objects |
| objPolygonAddrHi | Drawing objects | Addresses for the list of polygons and points for each object (high byte) |
| objPolygonAddrLo | Drawing objects | Addresses for the list of polygons and points for each object (low byte) |
| objPolygonData | Drawing objects | Various data for object polygons (colour, drawing phase) |
| objPolygonPhases | Drawing objects | The phase configuration for each object |
| objPolygonRange | Drawing objects | The first and last polygon numbers for each object |
| objRobot | Drawing objects | The list of polygons and points for the robot object (polygons 0 to 26, using points 0 to 28) |
| objScreenAddr | Screen buffer | The screen address of the object we are updating |
| objSentinel | Drawing objects | The list of polygons and points for the Sentinel object (polygons 102 to 136, using points 94 to 123) |
| objSentry | Drawing objects | The list of polygons and points for the sentry object (polygons 27 to 51, using points 29 to 50) |
| objTextBlock | Drawing objects | The list of polygons and points for the 3D text block object (polygons 148 to 151, using points 136 to 143) |
| objTower | Drawing objects | The list of polygons and points for the Sentinel's tower object (polygons 137 to 147, using points 124 to 135) |
| objTree | Drawing objects | The list of polygons and points for the tree object (polygons 52 to 66, using points 51 to 67) |
| objTypeToAnalyse | Workspace variable | The type of the object being analysed in the GetObjectAngles routine |
| objYawOffset | Workspace variable | The yaw offset of the left edge of the object being analysed in GetObjVisibility, relative to the left edge of the screen, in on-screen character columns |
| objYawWidth | Workspace variable | The width of the visible portion of the object being analysed in GetObjVisibility, in on-screen character columns |
| oddVisibility | Workspace variable | The visibility of tiles corners in odd rows as they are processed by the GetRowVisibility routine |
| P | Workspace variable | Temporary storage, used in a number of places |
| panAngleToUpdate | Drawing the landscape | Pitch and yaw angles for panning the landscape view, so the output of DrawLandscapeView will be the bit we add when updating the view |
| panKeyBeingPressed | Workspace variable | The direction in which the player is currently panning |
| PanLandscapeView | Drawing the landscape | Pan the landscape and update the landscape view |
| PerformHyperspace | Gameplay | Hyperspace the player to a brand new tile, ideally at the same altitude as the current tile |
| pitchDeltaHi | Workspace variable | The delta between two pitch angles (high byte) |
| pitchDeltaLo | Workspace variable | The delta between two pitch angles (low byte) |
| pixelBitMask | Graphics | A table for converting a pixel number in the range 0 to 3 into a screen mode 5 bit mask with that pixel's bits set and others clear |
| pixelByteColour1 | Sights | A table for converting a pixel number in the range 0 to 3 into a screen mode 5 pixel byte with that pixel set to colour 1 (%01) |
| pixelByteColour2 | Graphics | A table for converting a pixel number in the range 0 to 3 into a screen mode 5 pixel byte with that pixel set to colour 2 (%10) |
| pixelByteToDither | Workspace variable | A random pixel byte in a character row in the screen buffer to use when dithering an object to the screen |
| pixelsToLeft | Graphics | Pixel byte with all the pixels to the left of position X set |
| pixelsToRight | Graphics | Pixel byte with all the pixels to the right of position X set |
| PlaceObjectBelow | 3D objects | Attempt to place an object on a tile that is below the maximum altitude specified in A |
| PlaceObjectOnTile | 3D objects | Place an object on a tile, putting it on top of any existing boulders or towers |
| playerEnergy | Workspace variable | The player's energy level (in the range 0 to 63) |
| playerHasMovedTile | Workspace variable | A flag to record whether the player has moved to a new tile by transferring or hyperspacing, so we can decide whether to regenerate the player's landscape view |
| playerIsOnTower | Workspace variable | A flag to record whether the player is on top of the the Sentinel's tower |
| playerObject | Workspace variable | The number of the player object |
| playerTileIsHidden | Workspace variable | A flag that records when the player is being scanned but the player's tile is hidden from the Sentinel or sentry doing the scan |
| playerTileObscured | Workspace variable | Records when an enemy can see the player object but can't see the tile that the player is on |
| PlayGame | Main game loop | Start playing the generated landscape |
| PlayMusic | Sound | Play a piece of music |
| pointNumber | Workspace variable | A counter for the point number as we work through the points in an object when calculating the point's angles |
| pointX | Workspace variable | Temporary storage for the number of point #X while processing polygon lines |
| polygonColours | Workspace variable | The colours of the polygon that's being drawn in the DrawPolygon routine |
| polygonEdge | Workspace variable | The number the side of the polygon that we are currently processing |
| polygonEdgeCount | Workspace variable | The number of sides in the polygon we are drawing, which is one less than the number of points in the polygon's point list (as the last point in the list is always a repeat of the first point) |
| polygonFillPixels | Workspace variable | A pixel byte containing four pixels set to the fill colour for the polygon we are drawing |
| polygonGoesLeft | Workspace variable | A flag to record whether the polygon we are drawing extends to the left of the screen buffer we are drawing in |
| polygonGoesRight | Workspace variable | A flag to record whether the polygon we are drawing extends to the right of the screen buffer we are drawing in |
| polygonNumber | Workspace variable | A counter for the polygon number as we work through the polygons in an object when drawing the object |
| polygonPoint | Workspace variable | Up to five coordinates for the points of the polygon being drawn |
| polygonType | Workspace variable | Bits 6 and 7 determine the type of polygon to draw in the DrawPolygon routine (the calling subroutine is in brackets) |
| PP | Workspace variable | Temporary storage, used in the maths routines |
| prev1 | Drawing the landscape | Return from the subroutine with the C flag set |
| PreviewLandscape | Landscape | Draw an aerial preview of the landscape |
| previousFocus | Workspace variable | The previous setting of focusOnKeyAction, so we can detect (in the ProcessGameplay routine) whether the player is still holding down a pan key after we finish scrolling the screen for the previous pan |
| Print2DigitBCD | Text | Print a binary coded decimal (BCD) number using two digits |
| PrintCharacter | Text | Print a single-byte VDU command or character from a text token, optionally printing a drop shadow if the character is alphanumeric |
| PrintDigit | Text | Print a numerical digit, printing zero as a capital "O" |
| PrintInputBuffer | Text | Print the contents of the keyboard input buffer |
| PrintLandscapeNum | Text | Print the four-digit landscape number (0000 to 9999) |
| PrintNumber | Text | Print a number as a single digit, printing zero as a capital "O" |
| printTextIn3D | Workspace variable | Controls whether we are printing text normally or in 3D (as in the game's title on the title screen) |
| PrintTextToken | Text | Print a recursive text token |
| PrintVduCharacter | Text | Print a one-byte character from a text token or a multi-byte VDU 25 command |
| processAction | Workspace variable | Defines the following: |
| ProcessActionKeys (Part 1 of 2) | Keyboard | Process an action key press from key logger entry 1 (absorb, transfer, create, hyperspace, U-turn) |
| ProcessActionKeys (Part 2 of 2) | Keyboard | Process an action key press from key logger entry 1 (absorb, transfer, create, hyperspace, U-turn) |
| ProcessCharacter | Text | Process and print a character from a text token, which can encode another text token or be a one-byte character or VDU command |
| ProcessGameplay | Gameplay | A gameplay loop that processes all game key presses, returning to the main game loop when the player moves, quits, loses or pans |
| ProcessMusic | Sound | Play the configured music in the background |
| ProcessPauseKeys | Keyboard | Pause or unpause the game when COPY or DELETE are pressed |
| ProcessSound | Sound | Process any sound effects that have been configured so they play in the background (this is called regularly throughout gameplay) |
| ProcessTileData | Landscape | Process the tile data for all tiles in the landscape |
| ProcessVolumeKeys | Sound | Adjust the volume of the sound envelopes when the volume keys are pressed |
| Q | Workspace variable | Temporary storage, used in a number of places |
| Workspace variable | Temporary storage, used in the maths routines | |
| quadrantOffset | Workspace variable | The offset into the drawing tables for the quadrant containing the right edge of the viewing arc |
| quadrantOffsets | Drawing the landscape | Offsets into the tile view data tables for the four different viewing directions |
| quitGame | Workspace variable | A flag to record whether the player has pressed function key f1 to quit the game |
| R | Workspace variable | Temporary storage, used in a number of places |
| randomGenerator | Maths (Arithmetic) | A 24-bit random number generator that works independently from the landscape seeds and with a much simpler generation algorithm |
| randomPixel | Workspace variable | Storage for a random value in the DrawRandomDots routine to use as a random pixel number when drawing dots |
| rbuf1 | Screen buffer | Set the minimum and maximum pitch angled for the buffer type specified in Y (0 = row buffer, 1 = column buffer) |
| ReadCharacter | Keyboard | Read a character from the currently selected input stream |
| ReadKeyboard | Keyboard | Enable the keyboard and read a character from it |
| ReadNumber | Keyboard | Read a number from the keyboard into the input buffer |
| RemoveSights | Sights | Remove the sights from the screen |
| ResetMeanieScan | Gameplay | Reset the data stored for any meanie scans that the enemy has tried in the past, so we can start looking with a clean slate |
| ResetScreenAddress | Graphics | Reset the address of the start of screen memory |
| ResetTilesObjects | Main title Loop | Reset the tile visibility table and deallocate all object numbers |
| ResetVariables | Main title Loop | Reset all the game's main variables |
| RR | Workspace variable | Temporary storage, used in the maths routines |
| S | Workspace variable | Temporary storage, used in a number of places |
| sadr3 | Sights | Contains an RTS |
| samePanKeyPress | Workspace variable | Records whether the same pan key is being held down after we have just finished panning the landscape view |
| scaleFactor | Workspace variable | The scale factor for the x-axis and y-axis deltas when fitting them into single-byte numbers during the tracing of polygon edges |
| scan6 | Scanner/energy row | Contains an RTS |
| ScanForGameKeys | Keyboard | Scan for game key presses and update the key logger |
| ScanForMeanieTree | Gameplay | Scan through the objects in the landscape to see if any of them are trees that are suitable for turning into a meanie |
| ScanKeyboard | Keyboard | Scan the keyboard for a specific key press |
| scannerBlock | Scanner/energy row | A counter for the eight character blocks that make up the scanner |
| scannerPixelByte | Scanner/energy row | Pixel bytes for the three states of the scanner (black, static and green) |
| scannerState | Scanner/energy row | The current state of the scanner (black, static or green) |
| scannerStatic | Scanner/energy row | Storage for a random number that's used to generate static in the scanner |
| scannerUpdate | Workspace variable | A flag to control whether the scanner gets updated: |
| screenAddr | Workspace variable | Storage for a screen address |
| screenAddrHi | Workspace variable | The high byte of the screen memory address in the ScrollPlayerView routine |
| screenBackground | Workspace variable | The type of screen background when clearing the screen |
| screenBufferAddr | Screen buffer | Storage for the address for the current drawing operation in the screen buffer |
| screenBufferHi | Screen buffer | The value to add to scrollScreenHi for each direction to get the high byte of the screen buffer address of the content to scroll in |
| screenBufferLo | Screen buffer | The value to add to scrollScreenLo for each direction to get the low byte of the screen buffer address of the content to scroll in |
| screenBufferRow0 | Screen buffer | The screen buffer for character row 0 |
| screenBufferRow1 | Screen buffer | The screen buffer for character row 1 |
| screenBufferRow10 | Screen buffer | The screen buffer for character row 10 |
| screenBufferRow11 | Screen buffer | The screen buffer for character row 11 |
| screenBufferRow12 | Screen buffer | The screen buffer for character row 12 |
| screenBufferRow13 | Screen buffer | The screen buffer for character row 13 |
| screenBufferRow14 | Screen buffer | The screen buffer for character row 14 |
| screenBufferRow15 | Screen buffer | The screen buffer for character row 15 |
| screenBufferRow16 | Screen buffer | The screen buffer for character row 16 (as part of a column buffer) |
| screenBufferRow17 | Screen buffer | The screen buffer for character row 17 (as part of a column buffer) |
| screenBufferRow18 | Screen buffer | The screen buffer for character row 18 (as part of a column buffer) |
| screenBufferRow19 | Screen buffer | The screen buffer for character row 19 (as part of a column buffer) |
| screenBufferRow2 | Screen buffer | The screen buffer for character row 2 |
| screenBufferRow20 | Screen buffer | The screen buffer for character row 20 (as part of a column buffer) |
| screenBufferRow21 | Screen buffer | The screen buffer for character row 21 (as part of a column buffer) |
| screenBufferRow22 | Screen buffer | The screen buffer for character row 22 (as part of a column buffer) |
| screenBufferRow23 | Screen buffer | The screen buffer for character row 23 (as part of a column buffer) |
| screenBufferRow3 | Screen buffer | The screen buffer for character row 3 |
| screenBufferRow4 | Screen buffer | The screen buffer for character row 4 |
| screenBufferRow5 | Screen buffer | The screen buffer for character row 5 |
| screenBufferRow6 | Screen buffer | The screen buffer for character row 6 |
| screenBufferRow7 | Screen buffer | The screen buffer for character row 7 |
| screenBufferRow8 | Screen buffer | The screen buffer for character row 8 |
| screenBufferRow9 | Screen buffer | The screen buffer for character row 9 |
| screenBufferType | Workspace variable | The type of screen buffer that is currently being used |
| screenLeftYawHi | Workspace variable | The high byte of the yaw angle of the left edge of the screen, reduced into the range of a single 90-degree quadrant (so it's relative to the 90-degree viewing arc) |
| screenOrBuffer | Workspace variable | Controls whether the graphics routines draw directly onto the screen, or into the screen buffer |
| screenRowAddrHi | Graphics | Address lookup table for character rows in screen memory (high byte) |
| screenRowAddrLo | Screen buffer | Address lookup table for character rows in screen memory (low byte) |
| screenRowCounter | Workspace variable | A counter for filling screen rows in the FillScreen routine |
| screenType | Title screen | A variable that determines whether we are drawing the title screen or the secret code screen in the DrawTitleScreen routine |
| scrollCounter | Workspace variable | A counter for the number of columns or rows we still need to scroll in the player's scrolling landscape view when the player pans |
| ScrollPlayerView | Graphics | Scroll the screen and copy data from the screen buffer into screen memory to implement the player's scrolling landscape view |
| scrollScreenHi | Screen buffer | The amount to change the start of screen memory in order to scroll the player's landscape view through each direction (high byte) |
| scrollScreenLo | Screen buffer | The amount to change the start of screen memory in order to scroll the player's landscape view through each direction (low byte) |
| secondAxis | Workspace variable | The number of the second axis to calculate in the GetRotationMatrix routine |
| secretCode0000 | Landscape | The secret entry code for landscape 0000 (06045387) |
| secretCodeChecks | Workspace variable | Bits 1 to 4 store the results of checking each of the four two-digit numbers in a landscape's secret entry code |
| SecretCodeError | Main title loop | Display the "WRONG SECRET CODE" error, wait for a key press and rejoin the main title loop |
| secretCodeStash | Landscape | A stash for calculated values for each iteration in the CheckSecretCode routine |
| seedNumberLFSR | Workspace variable | A five-byte linear feedback shift register for |
| sentinelHasWon | Workspace variable | A flag to record when the player runs out of energy (i.e. the energy level goes negative), at which point the Sentinel wins |
| SetBufferAddress | Screen buffer | Set screenBufferAddr(1 0) to the address from which the interrupt handler should fetch new content to scroll onto the screen |
| SetColourPalette | Graphics | Set the logical colours for each of the four physical colours in screen mode 5 |
| SetColumnBufferMax | Screen buffer | Set the maximum and minimum pitch angles for the column buffer |
| SetCrackerSeed | Cracker protection | Set up anti-cracker tile-related data that can be checked in the CheckCrackerSeed routine |
| SetPlayerIsOnTower | Cracker protection | Set up the playerIsOnTower value for checking the game is won, as part of the anti-cracker code |
| SetScannerAndPause | Main game loop | Set the scanner update status and delay for 40 empty loops of 256 iterations each (i.e. 10,240 loops) |
| SetSecretStash | Cracker protection | Alter the secret code stash, as part of the anti-cracker code |
| SetSightsAddress | Sights | Update the address variables for the sights when they move into a new character block or row |
| shiftGenerator | Maths (Arithmetic) | Storage for randomGenerator(2 1 0) while we shift it left by two places |
| ShowBufferBlock | Screen buffer | Update the player's scrolling landscape view by copying an 8-byte character block from the screen buffer into screen memory |
| ShowBufferColumn | Screen buffer | Update the player's scrolling landscape view by copying a 2-pixel wide column from the screen buffer into screen memory |
| ShowBufferRow | Screen buffer | Update the player's scrolling landscape view by copying an 8-pixel high character row from the screen buffer into screen memory |
| ShowGameOverScreen | Title screen | Display the game over screen |
| ShowIconBuffer | Screen buffer | Display the redrawn icon and scanner row by copying the contents of the icon screen buffer into screen memory |
| ShowScreenBuffer | Screen buffer | Update the player's scrolling landscape view by copying the relevant parts of the screen buffer into screen memory |
| sightsAreVisible | Workspace variable | Controls whether the sights are being shown |
| sightsByte | Sights | The sights pixel byte stash, which contains the screen pixel bytes behind the sights, so they can be restored to remove the sights |
| sightsByteAddr | Workspace variable | Storage for an address that loops through the pixel bytes in screen memory where the sights appear, so the sights can be drawn and removed using the contents of the sights pixel byte stash |
| sightsByteAddrHi | Sights | The screen addresses of the bytes in the sights pixel byte stash, to which they can be restored to remove the sights (high byte) |
| sightsByteAddrLo | Sights | The screen addresses of the bytes in the sights pixel byte stash, to which they can be restored to remove the sights (low byte) |
| sightsByteCount | Workspace variable | The number of screen bytes in the sights pixel byte stash that contain the contents of the screen behind the sights (so they can be restored to remove the sights) |
| sightsInitialMoves | Workspace variable | Controls the initial movement of the sights over the first eight calls to the CheckForKeyPresses routine |
| sightsMoveAddrHi | Sights | The change to apply to the screen address of the sights when they move into a new character block or row (high byte) |
| sightsMoveAddrLo | Sights | The change to apply to the screen address of the sights when they move into a new character block or row (low byte) |
| sightsScreenAddr | Workspace variable | The screen address of the sights |
| sin | Maths (Geometry) | Table for sine values |
| sinA | Workspace variable | The result of the sin(A) calculation in the GetSineAndCosine routine |
| sinAngleHi | Workspace variable | The high byte of the sine of a pitch or yaw angle, as calculated by the GetRotationMatrix routine |
| sinAngleLo | Workspace variable | The low byte of the sine of a pitch or yaw angle, as calculated by the GetRotationMatrix routine |
| smoothingAction | Workspace variable | The action that's applied to tile data by the SmoothTileData routine |
| SmoothTileCorners (Part 1 of 4) | Landscape | Smooth a row or column of tile corners (a "strip of tiles") |
| SmoothTileCorners (Part 2 of 4) | Landscape | Smooth a strip by moving each outlier tile corner to the altitude of its closest immediate neighbour (in terms of altitude) |
| SmoothTileCorners (Part 3 of 4) | Landscape | Smooth a strip by setting the tile corner altitudes to the average of the current tile corner altitude and three following corners |
| SmoothTileCorners (Part 4 of 4) | Landscape | Copy the smoothed strip data back into the tileData table |
| SmoothTileData | Landscape | Smooth the entire landscape |
| soundCounter | Workspace variable | A counter for the sound currently being made, which counts down in the IRQHandler routine at a rate of 50 times a second |
| soundData | Sound | OSWORD blocks for making the various game sounds |
| soundEffect | Workspace variable | Determines how the current sound is processed by the ProcessSound routine |
| soundNumberData | Sound | A table to map a sound number (0 to 6) to the sound data block(s) that are used to make the sound |
| spaceKeyDebounce | Keyboard | A variable to flag whether the SPACE key has been pressed, so we can implement debounce |
| SpawnCharacter3D (Part 1 of 2) | Title screen | Spawn a character on the landscape in large 3D blocks for drawing on the main title screen or secret code screen |
| SpawnCharacter3D (Part 2 of 2) | Title screen | Spawn large 3D blocks for the extracted character definition |
| SpawnEnemies | Landscape | Calculate the number of enemies for this landscape, add them to the landscape and set the palette accordingly |
| SpawnObject | 3D objects | Add a new object of the specified type to the objectTypes table |
| SpawnObject+3 | 3D objects | Spawn an object of the type specified in keyPress |
| SpawnPlayer | Landscape | Add the player object to the landscape, ideally placing it below all the enemies and in the bottom half of the landscape |
| SpawnSecretCode3D | Title screen | Draw the landscape's secret code by spawning a set of large 3D text block objects |
| SpawnTitleObject | Title screen | Spawn the title object (robot or the Sentinel) as object #1 |
| SpawnTrees | Landscape | Add trees to the landscape, ideally placing them below all the enemies in the landscape |
| SS | Workspace variable | Temporary storage, used in the maths routines |
| Stack variables | Workspaces | Variables that share page 1 with the stack |
| StartScrollingView | Screen buffer | Start a scroll process in the background by setting the number of scroll steps and the address to start copying new content from |
| stashAddr | Workspace variable | The address of the four bytes in the secretCodeStash that correspond to the landscape's secret code |
| stashOffset | Workspace variable | The offset into the secretCodeStash where we store a set of generated values for later checking in the GetRowVisibility routine |
| StringToNumber | Text | Convert a string of ASCII digits in the input buffer in-place into a multi-byte BCD number |
| stripData | Landscape | Storage for tile data when smoothing strips of tiles during the landscape generation process |
| T | Workspace variable | Temporary storage, used in a number of places |
| tact25 | Gameplay | Dither the updated object #X onto the screen, with bit 7 of drawLandscape determining whether the object is drawn on its own (bit 7 set) or with the surrounding landscape (bit 7 clear) |
| talt2 | Drawing the landscape | Jump to MainTitleLoop via game10 |
| tanHalfAngle | Maths (Geometry) | Table for hypotenuse lengths given the tangent of an angle |
| targetObject | Workspace variable | The number of the object that is being targeted in the DrainObjectEnergy routine |
| targetOnTile | Workspace variable | A flag to record whether the tile being analysed in the GetTileAltitude routine contains the target object whose number is in targetObject |
| targetVisibility | Workspace variable | Reports whether a target object is visible from an enemy in the CheckEnemyGaze routine |
| textDropShadow | Workspace variable | Controls whether text in text tokens is printed with a drop shadow |
| textViewerPitch | Title screen | The pitch angle of the viewer for the large 3D text on the title screen |
| textViewerYaw | Title screen | The yaw angle of the viewer for the large 3D text on the title screen |
| tileAltitude | Workspace variable | The altitude of the tile that we are currently processing |
| tileData | Landscape | Altitude and shape data for landscape tiles |
| tileDataMultiplier | Workspace variable | A multiplier that we apply to the altitudes of the tile corners to alter the steepness of the landscape during landscape generation |
| tileDataPage | Workspace variable | The address of the tileData page containing the current tile's data |
| tileEdges | Landscape | A table to map tile shapes and gaze vector direction to tile edges |
| tileIsOnScreen | Workspace variable | Information on whether a tile is fully on-screen, partially on-screen or fully off-screen |
| tileNumber | 3D objects | The tile number to which we are adding an object in the PlaceObjectOnTile routine |
| tilesAtAltitude | Landscape | Storage for tile blocks at specific altitudes for placing enemies on the landscape |
| tileShapeColour | Drawing the landscape | Tile colours by shape and the orientation of the viewer |
| tileShapeOffset | Workspace variable | The tile shape we are drawing, amended to use as an offset into the tileShapeColour table |
| tileViewData | Workspace variable | The tile data for tiles in the current landscape view |
| tileVisibility | Drawing the landscape | A table for storing the visibility of each tile from the player's point of view, with one bit per tile (1 = visible, 0 = hidden) |
| titleObjectToDraw | Workspace variable | The object we are drawing in the DrawTitleView routine |
| titleObjectYaw | Title screen | The yaw angle of an object on the title screen |
| titleOffset | Title screen | An offset to apply to the large 3D text for the title screen |
| titleText | Title screen | The text to draw on the title screen |
| titleViewerPitch | Title screen | The pitch angle of the viewer for objects on the title screen |
| titleViewerYaw | Title screen | The yaw angle of the viewer for objects on the title screen |
| toAddr | Workspace variable | An address, typically used as a destination address when copying |
| token0 | Text | Background colour blue, print "PRESS ANY KEY" at (64, 100), set text background to black |
| token1 | Text | Print 13 spaces at (64, 100), print "LANDSCAPE NUMBER?" at (64, 768), switch to text cursor, move text cursor to (5, 27) |
| token2 | Text | Background colour blue, print "SECRET ENTRY CODE?" at (64, 768), switch to text cursor, move text cursor to (2, 27) |
| token3 | Text | Background colour blue, print "WRONG SECRET CODE" at (64, 768), print "PRESS ANY KEY" at (64, 100), set text background to black |
| token4 | Text | Background colour black, print "PRESS ANY KEY" at (192, 64), print "LANDSCAPE" two chars right of (64, 768), move cursor right |
| token5 | Text | Text token 5: Print "SECRET ENTRY CODE" at (64, 768), "LANDSCAPE" at (192, 704), move cursor right |
| token6 | Text | Text token 6: Print "PRESS ANY KEY" at (64, 100) |
| token7 | Text | Text token 7: Move the graphics cursor to (64, 768) |
| token8 | Text | Text token 8: Move the graphics cursor to (192, 704) |
| token9 | Text | Text token 9: Move the graphics cursor to (192, 64) |
| token10 | Text | Text token 10: Configure text to be printed at the graphics cursor and set the background colour to colour 0 (blue) |
| token11 | Text | Text token 11: Configure text to be printed at the graphics cursor and set the background colour to colour 1 (black) |
| token12 | Text | Text token 12: Move graphics cursor to (64, 100) |
| token13 | Text | Text token 13: Print "LANDSCAPE" |
| token14 | Text | Text token 14: Print "SECRET ENTRY CODE" |
| token15 | Text | Text token 15: Print five spaces |
| token16 | Text | Text token 16: Print three spaces |
| token17 | Text | Text token 17: Print "PRESS ANY KEY" |
| tokenOffset | Text | Address offsets for the text tokens (each offset in the table is the offset of the token from tokenBase) |
| topObjectOnStack | Workspace variable | The number of the object on the top of an object stack |
| TracePolygonEdge (Part 1 of 8) | Drawing polygons | Trace a polygon edge, populating xPolygonRight or xPolygonLeft with the x-coordinate of the edge for each y-coordinate |
| TracePolygonEdge (Part 2 of 8) | Drawing polygons | Trace a polygon edge with a steep gradient by stepping along the y-axis |
| TracePolygonEdge (Part 3 of 8) | Drawing polygons | Trace a polygon edge with a shallow gradient by stepping along the x-axis |
| TracePolygonEdge (Part 4 of 8) | Drawing polygons | Trace a steep edge that starts off-screen, without storing the coordinates, until we reach the screen and return to part 2 |
| TracePolygonEdge (Part 5 of 8) | Drawing polygons | Trace a shallow edge that starts off-screen, without storing the coordinates, until we reach the screen and return to part 3 |
| TracePolygonEdge (Part 6 of 8) | Drawing polygons | Trace a polygon edge where the start or end point x-coordinates are two-byte numbers |
| TracePolygonEdge (Part 7 of 8) | Drawing polygons | Trace a polygon edge with a steep gradient by stepping along the y-axis (for two-byte x-coordinates) |
| TracePolygonEdge (Part 8 of 8) | Drawing polygons | Trace a polygon edge with a shallow gradient by stepping along the x-axis (for two-byte x-coordinates) |
| traceStepCounter | Workspace variable | The number of steps in the ray-tracing process when calculating tile visibility in the GetRowVisibility routine |
| treeCounter | Workspace variable | A counter for the number of trees that are added to the landscape in the SpawnTrees routine |
| treeVisibility | Workspace variable | Reports whether a gaze is interrupted by a tree in the CheckEnemyGaze routine |
| trianglePointAdd | Drawing polygons | The value to add to the second point number to get the third point number when drawing a tile face as two triangles |
| triangleStart | Drawing polygons | The number of the first point in each two-face shape that is drawn as a pair of triangles |
| triangleStartPoint | Workspace variable | The number of the starting point for the tile shape being drawn |
| U | Workspace variable | Temporary storage, used in a number of places |
| UpdateEnemyTimers | Gameplay | Update the timers that control the enemy tactics |
| UpdateIconsScanner | Scanner/energy row | Update the icons in the top-left corner of the screen to show the player's current energy level and redraw the scanner box |
| updateOffsetHi | Screen buffer | The offset within screen memory for the player's landscape view of the area to update following a scroll (high byte) |
| updateOffsetLo | Screen buffer | The offset within screen memory for the player's landscape view of the area to update following a scroll (low byte) |
| UpdatePlayerEnergy | Gameplay | Update the player's energy levels by adding or subtracting the amount of energy in a specific object |
| UpdateScanner | Scanner/energy row | Update the scanner, if required |
| UpdateScannerNow | Scanner/energy row | Update the scanner to a new state |
| updateTimer | Workspace variable | A counter that ensures the enemy timers are updated on one of every three calls to the interrupt handler |
| UseColumnBuffer | Screen buffer | Configure the column buffer for use |
| UseRowBuffer | Screen buffer | Configure the row buffer for use |
| uTurnStatus | Workspace variable | A flag to record whether we are performing or have just performed a U-turn |
| V | Workspace variable | Temporary storage, used in a number of places |
| vduCounter | Text | The number of bytes in a VDU 25, n, x; y; command |
| vduShadowFront | Text | VDU commands for printing the front character of a drop shadow |
| vduShadowRear | Text | VDU commands for printing the rear character of a drop shadow |
| vectorPitchAngleHi | Workspace variable | The pitch angle of a vector (high byte) |
| vectorPitchAngleLo | Workspace variable | The pitch angle of a vector (low byte) |
| vectorYawAngleHi | Workspace variable | The yaw angle of a vector (high byte) |
| vectorYawAngleLo | Workspace variable | The yaw angle of a vector (low byte) |
| viewingArcRightYaw | Workspace variable | The yaw angle of the right edge of the viewing arc, where the arc is 90 degrees wide |
| viewingObject | Workspace variable | The number of the viewing object |
| viewingQuadrantOpp | Workspace variable | The opposite quadrant number to that containing the right edge of the viewing arc |
| viewingQuadrantx4 | Workspace variable | The quadrant number containing the right edge of the viewing arc, multiplied by 4, for use when calculating the number of faces in a tile in DrawSlopingTile |
| viewScreenAddr | Workspace variable | The screen address of the player's scrolling landscape view, which is just below the icon and scanner row at the top of the screen |
| viewType | Title screen | Storage for the type of title view we are drawing in DrawTitleView (title screen or landscape preview) |
| visibileBitMask | Drawing the landscape | A table for converting a number in the range 0 to 7 into a bit mask with only that bit set, when counting from the left |
| volumeLevel | Sound | The volume level, which can be changed by pressing "7" and "8" |
| W | Workspace variable | Temporary storage, used in a number of places |
| xBlock | Workspace variable | The tile x-coordinate of the tile we are analysing when calculating the highest tile in a block |
| xBufferLeft | Workspace variable | The left edge of the screen buffer in pixels |
| xBufferRight | Workspace variable | The right edge of the screen buffer in pixels |
| xBuffersLeft | Screen buffer | The left edge of each screen buffer in pixels |
| xBuffersWidth | Screen buffer | The width of each screen buffer in pixels |
| xBufferWidth | Workspace variable | The width in pixels of the screen buffer |
| xCoordBot | Workspace variable | The x-coordinate of an object or point (bottom byte) |
| xCoordHi | Workspace variable | The x-coordinate of an object or point (high byte) |
| xCoordLo | Workspace variable | The x-coordinate of an object or point (low byte) |
| xCounter | Workspace variable | A counter to iterate along tiles in the x-axis |
| xDeltaAbsoluteHi | Workspace variable | The absolute difference between two x-coordinates (high byte), i.e. |xDeltaHi| |
| xDeltaHi | Workspace variable | The difference between two x-coordinates (high byte) |
| xDeltaLo | Workspace variable | The difference between two x-coordinates (low byte) |
| xEdgeDelta | Workspace variable | The scaled and signed x-axis delta between two polygon points when tracing the polygon edges (single byte) |
| xEdgeDeltaHi | Workspace variable | The high byte of the scaled and signed x-axis delta between two polygon points when tracing the polygon edges |
| xEdgeDeltaLo | Workspace variable | The low byte of the scaled and signed x-axis delta between two polygon points when tracing the polygon edges |
| xEdgeEndHi | Workspace variable | The x-coordinate of the end point in the polygon edge being processed (high byte) |
| xEdgeEndLo | Workspace variable | The x-coordinate of the end point in the polygon edge being processed (low byte) |
| xEdgeStartHi | Workspace variable | The x-coordinate of the start point in the polygon edge being processed (high byte) |
| xEdgeStartLo | Workspace variable | The x-coordinate of the start point in the polygon edge being processed (low byte) |
| xIconCounter | Workspace variable | A counter for drawing the icons in the top-left of the screen that show the player's energy level, as we work from left to right along the x-axis |
| xMaxHorizontal | Workspace variable | A variable to keep track of the maximum x-coordinates of any polygon edges that are horizontal in the polygon we are drawing |
| xMinHorizontal | Workspace variable | A variable to keep track of the minimum x-coordinates of any polygon edges that are horizontal in the polygon we are drawing |
| xObject | 3D objects | The x-coordinates in 3D space for the 3D objects |
| xPointDeltaHi | Workspace variable | Temporary storage for the high byte of the x-axis delta between two polygon points |
| xPolygonAddrHi | Workspace variable | The high byte of the address of the table where we store the x-coordinate of the polygon line being processed, so this is either HI(xPolygonLeft) or HI(xPolygonRight) |
| xPolygonLeft | Drawing polygons | The pixel x-coordinate of the left edge of each pixel line in the polygon being drawn |
| xPolygonPointHi | Drawing polygons | Pixel x-coordinates for all the points in the polygon that we are currently drawing (high bytes) |
| xPolygonPointLo | Drawing polygons | Pixel x-coordinates for all the points in the polygon that we are currently drawing (low bytes) |
| xPolygonPointScale | Workspace variable | A flag to record whether the pixel x-coordinate of the polygon points being processed fit into one or two bytes |
| xPolygonRight | Drawing polygons | The pixel x-coordinate of the right edge of each pixel line in the polygon being drawn |
| xPolygonRightEdge | Workspace variable | The screen x-coordinate of the right edge of the polygon being drawn |
| xSights | Workspace variable | The pixel x-coordinate of the sights on-screen |
| xSightsBrush | Workspace variable | The x-coordinate of the "brush" that we use to draw the sights, relative to the top-left corner of the character block containing the top of the sights |
| xSightsStep | Sights | Steps to take along the x-axis when drawing the sights |
| xStoreEnemyGaze | Gameplay | Temporary storage for X so it can be preserved through calls to CheckEnemyGaze |
| xStoreMatrix | Maths (Geometry) | Temporary storage for X so it can be preserved through calls to GetRotationMatrix |
| xTextViewer | Title screen | The x-coordinate of the viewer for the large 3D text on the title screen |
| xTile | Workspace variable | Tile corner x-coordinate |
| xTileCharacter | Workspace variable | The tile x-coordinate of the character being spawned in large 3D blocks on the landscape for the title screen |
| xTileLeftPrevious | Workspace variable | The previous value of xTileViewLeft |
| xTileMaxAltitude | Landscape | The tile x-coordinate of the highest tile within each 4x4 block of tiles |
| xTileRow | Workspace variable | The tile x-coordinate of the tile we are analysing in the GetRowVisibility routine |
| xTileSentinel | Workspace variable | The tile x-coordinate of the Sentinel |
| xTileToDraw | Workspace variable | The column number of the tile we are currently drawing |
| xTileViewer | Workspace variable | The tile x-coordinate of the viewer, but with the axes rotated to match the orientation of the viewer, so we can draw the landscape along the line of sight, towards the viewer's tile |
| xTileViewLeft | Workspace variable | The tile number at the left edge of the tile row we are currently processing when drawing the landscape |
| xTileViewLeftEdge | Workspace variable | The tile number at the left edge of the visible portion of the row we are currently processing when drawing the landscape |
| xTileViewRight | Workspace variable | The tile number at the right edge of the tile row we are currently processing when drawing the landscape |
| xTileViewRightEdge | Workspace variable | The tile number at the right edge of the visible portion of the row we are currently processing when drawing the landscape |
| xTitleOffset | Workspace variable | An x-coordinate offset for drawing the title screen this is zero during gameplay) |
| xVectorBot | Workspace variable | The x-coordinate of a vector (bottom byte) |
| xVectorHi | Workspace variable | The x-coordinate of a vector (high byte) |
| xVectorLo | Workspace variable | The x-coordinate of a vector (low byte) |
| yAccuracyLo | Workspace variable | The vertical accuracy for considering a tile as being seen by the viewer, as a fractional part |
| yawAdjustmentHi | Screen buffer | The yaw offset of the left edge of the object being updated, relative to the left edge of the screen, in yaw angles |
| yawAdjustmentLo | Workspace variable | A yaw adjustment to apply to the landscape drawing process so that when we update objects on-screen, we can yaw the viewer's gaze to the right to move the left edge of the object to the left edge of the screen so the object will fit into the screen buffer as efficiently as possible (low byte) |
| yCoordBot | Workspace variable | The y-coordinate of an object or point (bottom byte) |
| yCoordHi | Workspace variable | The y-coordinate of an object or point (high byte) |
| yCoordLo | Workspace variable | The y-coordinate of an object or point (low byte) |
| yDeltaHi | Workspace variable | The difference between two y-coordinates (high byte) |
| yDeltaLo | Workspace variable | The difference between two y-coordinates (low byte) |
| yEdgeDeltaHi | Workspace variable | The difference in pitch angle between two polygon points, i.e. the delta along the y-axis (high byte) |
| yEdgeDeltaLo | Workspace variable | The difference in pitch angle between two polygon points, i.e. the delta along the y-axis (low byte) |
| yEdgeEndHi | Workspace variable | The y-coordinate of the end point in the polygon edge being processed (high byte) |
| yEdgeEndLo | Workspace variable | The y-coordinate of the end point in the polygon edge being processed (low byte) |
| yEdgeStartHi | Workspace variable | The y-coordinate of the start point in the polygon edge being processed (high byte) |
| yEdgeStartLo | Workspace variable | The y-coordinate of the start point in the polygon edge being processed (low byte) |
| yObjectHi | 3D objects | The y-coordinates in 3D space for the 3D objects (high byte) |
| yObjectLo | 3D objects | The y-coordinates in 3D space for the 3D objects (low byte) |
| yPlatformLo | Workspace variable | The low byte of the altitude of the Sentinel's tower or boulder when returning tile data from the GetTileAltitude routine |
| yPolygonBottom | Workspace variable | The y-coordinate of the bottom of the polygon being drawn (where higher y-coordinates are up the screen) |
| yPolygonLine | Workspace variable | The polygon y-coordinate of the pixel line being drawn in the DrawPolygonLines routine |
| yPolygonTop | Workspace variable | The y-coordinate of the top of the polygon being drawn (where higher y-coordinates are up the screen) |
| ySights | Workspace variable | The pixel y-coordinate of the sights on-screen |
| ySightsStep | Sights | Steps to take along the y-axis when drawing the sights |
| yStoreHypotenuse | Maths (Geometry) | Temporary storage for Y so it can be preserved through calls to GetHypotenuse |
| yStoreNextSeed | Maths (Arithmetic) | Temporary storage for Y so it can be preserved through calls to GetNextSeedNumber |
| yStoreTileView | Workspace variable | Temporary storage for Y so it can be preserved through calls to GetTileViewAngles |
| yTextViewer | Title screen | The y-coordinate of the viewer for the large 3D text on the title screen |
| yTileRow | Workspace variable | The tile y-coordinate of the tile we are analysing in the GetRowVisibility routine |
| yTitleObject | Title screen | The y-coordinate of an object on the title screen, as a delta from the y-coordinate of the viewing object |
| yVectorBot | Workspace variable | The y-coordinate of a vector (bottom byte) |
| yVectorHi | Workspace variable | The y-coordinate of a vector (high byte) |
| yVectorLo | Workspace variable | The y-coordinate of a vector (low byte) |
| zBlock | Workspace variable | The tile z-coordinate of the tile we are analysing when calculating the highest tile in a block |
| zCoordBot | Workspace variable | The z-coordinate of an object or point (bottom byte) |
| zCoordHi | Workspace variable | The z-coordinate of an object or point (high byte) |
| zCoordLo | Workspace variable | The z-coordinate of an object or point (low byte) |
| zCounter | Workspace variable | A counter to iterate along tiles in the z-axis |
| zDeltaAbsoluteHi | Workspace variable | The absolute difference between two z-coordinates (high byte), i.e. |zDeltaHi| |
| zDeltaHi | Workspace variable | The difference between two z-coordinates (high byte) |
| zDeltaLo | Workspace variable | The difference between two z-coordinates (low byte) |
| Zero page | Workspaces | Mainly temporary variables that are used a lot |
| zObject | 3D objects | The z-coordinates in 3D space for the 3D objects |
| zTextViewer | Title screen | The z-coordinate of the viewer for the large 3D text on the title screen |
| zTile | Workspace variable | Tile corner z-coordinate |
| zTileCharacter | Workspace variable | The tile z-coordinate of the character being spawned in large 3D blocks on the landscape for the title screen |
| zTileMaxAltitude | Landscape | The tile z-coordinate of the highest tile within each 4x4 block of tiles |
| zTileRow | Workspace variable | The tile z-coordinate of the tile we are analysing in the GetRowVisibility routine |
| zTileSentinel | Workspace variable | The tile z-coordinate of the Sentinel |
| zTileViewer | Workspace variable | The tile z-coordinate of the viewer, but with the axes rotated to match the orientation of the viewer, so we can draw the landscape along the line of sight, towards the viewer's tile |
| zTitleObject | Title screen | The z-coordinate of an object on the title screen, as a delta from the z-coordinate of the viewing object |
| zVectorBot | Workspace variable | The z-coordinate of a vector (bottom byte) |
| zVectorHi | Workspace variable | The z-coordinate of a vector (high byte) |
| zVectorLo | Workspace variable | The z-coordinate of a vector (low byte) |