ORG &5E40 .xVergeRightLo SKIP 40Name: xVergeRightLo [Show more] Type: Variable Category: Track geometry Summary: Low byte of segment yaw angles along the right track verge in front of the player (i.e. along the x-axis)Context: See this variable on its own page References: This variable is used as follows: * AssistSteering uses xVergeRightLo * DrawCornerMarkers uses xVergeRightLo * DrawSegmentEdge (Part 1 of 7) uses xVergeRightLo * DrawSegmentEdge (Part 2 of 7) uses xVergeRightLo * GetSectionYawAngle uses xVergeRightLo * GetVergeAndMarkers (Part 2 of 4) uses xVergeRightLo * ShuffleSectionList uses xVergeRightLo * SpinTrackSection uses xVergeRightLo
Stored as a 16-bit value (xVergeRightHi xVergeRightLo)..xVergeLeftLo SKIP 40Name: xVergeLeftLo [Show more] Type: Variable Category: Track geometry Summary: Low byte of segment yaw angles along the left track verge in front of the player (i.e. along the x-axis)Context: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (xVergeLeftHi xVergeLeftLo)..xVergeRightHi SKIP 40Name: xVergeRightHi [Show more] Type: Variable Category: Track geometry Summary: High byte of segment yaw angles along the right track verge in front of the player (i.e. along the x-axis)Context: See this variable on its own page References: This variable is used as follows: * AssistSteering uses xVergeRightHi * CheckVergeOnScreen uses xVergeRightHi * DrawCornerMarkers uses xVergeRightHi * DrawSegmentEdge (Part 1 of 7) uses xVergeRightHi * DrawSegmentEdge (Part 2 of 7) uses xVergeRightHi * GetSectionYawAngle uses xVergeRightHi * GetSegmentAngles (Part 1 of 3) uses xVergeRightHi * GetSegmentAngles (Part 3 of 3) uses xVergeRightHi * GetTrackAndMarkers uses xVergeRightHi * GetVergeAndMarkers (Part 2 of 4) uses xVergeRightHi * SetBackground uses xVergeRightHi * SetVergeBackground uses xVergeRightHi * ShuffleSectionList uses xVergeRightHi * SpinTrackSection uses xVergeRightHi
Stored as a 16-bit value (xVergeRightHi xVergeRightLo)..xVergeLeftHi SKIP 40Name: xVergeLeftHi [Show more] Type: Variable Category: Track geometry Summary: High byte of segment yaw angles along the left track verge in front of the player (i.e. along the x-axis)Context: See this variable on its own page References: This variable is used as follows: * GetTrackAndMarkers uses xVergeLeftHi * SetBackground uses xVergeLeftHi
Stored as a 16-bit value (xVergeLeftHi xVergeLeftLo)..vergeDataRight SKIP 24Name: vergeDataRight [Show more] Type: Variable Category: Track geometry Summary: Data (such as colour) for the verge marks on the right side of the trackContext: See this variable on its own page References: This variable is used as follows: * DrawVergeEdge uses vergeDataRight * GetColour (Part 3 of 3) uses vergeDataRight * GetColourSup uses vergeDataRight * GetVergeAndMarkers (Part 4 of 4) uses vergeDataRight * MapSegmentsToLines uses vergeDataRight * SetVergeBackground uses vergeDataRight * SpinTrackSection uses vergeDataRight
* Bits 0-1: colour of the verge mark * 0 = black * 1 = red * 2 = white * Bit 7 gets set in MapSegmentsToLines when this segment is hidden behind a hill.scaledScaffold SKIP 16Name: scaledScaffold [Show more] Type: Variable Category: 3D objects Summary: Storage for an object's scaled scaffold Deep dive: Scaling objects with scaffoldsContext: See this variable on its own page References: This variable is used as follows: * DrawObjectEdges uses scaledScaffold * ScaleObject uses scaledScaffold.vergeDataLeft SKIP 24Name: vergeDataLeft [Show more] Type: Variable Category: Track geometry Summary: Data (such as colour) for the verge marks on the left side of the trackContext: See this variable on its own page References: No direct references to this variable in this source file
* Bits 0-1: colour of the verge mark * 0 = black * 1 = red * 2 = white * Bit 7: gets set in MapSegmentsToLines.yVergeRight SKIP 24Name: yVergeRight [Show more] Type: Variable Category: Track geometry Summary: Segment pitch angles along the right track verge in front of the player (i.e. along the up-down y-axis)Context: See this variable on its own page References: This variable is used as follows: * DrawCornerMarkers uses yVergeRight * DrawSegmentEdge (Part 1 of 7) uses yVergeRight * GetSectionAngles (Part 3 of 3) uses yVergeRight * GetTrackAndMarkers uses yVergeRight * GetVergeAndMarkers (Part 4 of 4) uses yVergeRight * MapSegmentsToLines uses yVergeRight * SetMarker uses yVergeRight * SetVergeBackground uses yVergeRight * ShuffleSectionList uses yVergeRight * SpinTrackSection uses yVergeRight.numberOfPlayers SKIP 1Name: numberOfPlayers [Show more] Type: Variable Category: Drivers Summary: The number of playersContext: See this variable on its own page References: This variable is used as follows: * AwardRacePoints uses numberOfPlayers * MainLoop (Part 5 of 6) uses numberOfPlayers.lowestPlayerNumber SKIP 1 \ Contains 20 minus the number of players, so that's: \ \ * 19 if there is one player \ * 18 if there are two players \ \ and so on, down to 0 if there are 20 players \ \ Human players take the place of drivers with higher \ numbers, so the first player takes the place of driver \ 19 (the aptly called Dummy Driver, as they never get \ to race), and the second player takes the place of \ driver 18 (Peter Out), the third player replaces \ driver 17 (Rick Shaw) and so on \ \ So this not only represents the lowest player number, \ but also the highest non-human driver number (which is \ lowestPlayerNumber - 1)Name: lowestPlayerNumber [Show more] Type: Variable Category: Drivers Summary: The number of the player with the lowest player numberContext: See this variable on its own page References: This variable is used as follows: * AwardRacePoints uses lowestPlayerNumber * MainLoop (Part 3 of 6) uses lowestPlayerNumber * MainLoop (Part 4 of 6) uses lowestPlayerNumber * MainLoop (Part 5 of 6) uses lowestPlayerNumber * MainLoop (Part 6 of 6) uses lowestPlayerNumber.raceClass SKIP 1 \ The class of race: \ \ * 0 = Novice \ \ * 1 = Amateur \ \ * 2 = ProfessionalName: raceClass [Show more] Type: Variable Category: Drivers Summary: The class of the current raceContext: See this variable on its own page References: This variable is used as follows: * InitialiseDrivers uses raceClass * MainDrivingLoop (Part 3 of 5) uses raceClass * MainLoop (Part 2 of 6) uses raceClass * MainLoop (Part 4 of 6) uses raceClass * MainLoop (Part 5 of 6) uses raceClass * PrintRaceClass uses raceClass * SetDriverSpeed uses raceClass.qualifyingTime SKIP 1 \ The number of minutes of qualifying lap time, minus \ one, as follows: \ \ * 4 gives us 5 minutes of qualifying time \ \ * 9 gives us 10 minutes of qualifying time \ \ * 25 gives us 26 minutes of qualifying time \ \ * 255 gives us infinite time (for practice) \ \ Note that the third value should be 19 to match the \ menu option of 20 minutes, but the value in the \ timeFromOption table is incorrectName: qualifyingTime [Show more] Type: Variable Category: Drivers Summary: The number of minutes of qualifying lap timeContext: See this variable on its own page References: This variable is used as follows: * MainDrivingLoop (Part 3 of 5) uses qualifyingTime * MainDrivingLoop (Part 4 of 5) uses qualifyingTime * MainLoop (Part 1 of 6) uses qualifyingTime * MainLoop (Part 2 of 6) uses qualifyingTime * MoveAndDrawCars uses qualifyingTime * UpdateLapTimers uses qualifyingTime.competitionStarted SKIP 1 \ Flag to indicate whether the competition has started: \ \ * 0 = the competition has not started \ \ * Non-zero = the competition has startedName: competitionStarted [Show more] Type: Variable Category: Drivers Summary: A flag to indicate whether or not the competition has startedContext: See this variable on its own page References: This variable is used as follows: * MainLoop (Part 2 of 6) uses competitionStarted * MainLoop (Part 3 of 6) uses competitionStarted * MainLoop (Part 5 of 6) uses competitionStarted * MainLoop (Part 6 of 6) uses competitionStarted.frontWingSetting SKIP 1Name: frontWingSetting [Show more] Type: Variable Category: Driving model Summary: The front wing setting, as entered by the playerContext: See this variable on its own page References: This variable is used as follows: * GetWingSettings uses frontWingSetting * ScaleWingSettings uses frontWingSetting.rearWingSetting SKIP 1Name: rearWingSetting [Show more] Type: Variable Category: Driving model Summary: The rear wing setting, as entered by the playerContext: See this variable on its own page References: This variable is used as follows: * GetWingSettings uses rearWingSetting * ScaleWingSettings uses rearWingSetting.lapsMenuOption SKIP 1Name: lapsMenuOption [Show more] Type: Variable Category: Drivers Summary: The menu option chosen from the laps menu (0 to 2)Context: See this variable on its own page References: This variable is used as follows: * MainLoop (Part 5 of 6) uses lapsMenuOption * PrintDriverTable uses lapsMenuOption.baseSpeed SKIP 1 \ The base speed for each car, which is faster with a \ higher class of race (this value is taken from the \ track data at trackBaseSpeed): \ \ * 134 = Novice \ \ * 146 = Amateur \ \ * 152 = Professional SKIP 7Name: baseSpeed [Show more] Type: Variable Category: Drivers Summary: The base speed for each car, copied from the track dataContext: See this variable on its own page References: This variable is used as follows: * GetSectionSteering uses baseSpeed * SetDriverSpeed uses baseSpeed.yVergeLeft SKIP 24Name: yVergeLeft [Show more] Type: Variable Category: Track geometry Summary: Segment pitch angles along the left track verge in front of the player (i.e. along the up-down y-axis)Context: See this variable on its own page References: This variable is used as follows: * GetSectionAngles (Part 3 of 3) uses yVergeLeft * GetTrackAndMarkers uses yVergeLeft.backgroundColour SKIP 80Name: backgroundColour [Show more] Type: Variable Category: Screen buffer Summary: The background colour for each track line Deep dive: Drawing the track viewContext: See this variable on its own page References: This variable is used as follows: * DrawTrackLine (Part 2 of 2) uses backgroundColour * GetColour (Part 1 of 3) uses backgroundColour * GetColourSup uses backgroundColour * ResetTrackLines uses backgroundColour * SetBackground uses backgroundColour * SetVergeBackground uses backgroundColour * UpdateBackground uses backgroundColour
This table contains colour information for each of the 80 track lines. It stores the colour, the verge type and details of the routine in which the colour data was written, as follows: * Bits 0-1: background colour of track line (this value is a logical colour and the physical colour is looked up from the colourPalette table) %00 = logical colour 0 %01 = logical colour 1 %10 = logical colour 2 %11 = logical colour 3 * Bit 2: records which routine set this colour, along with bits 5-7 %0 = not set by SetVergeBackground %1 = set by SetVergeBackground * Bits 3-4: the verge type that was being drawn when this colour was set (taken from vergeType) %00 = leftVergeStart %01 = leftTrackStart %10 = rightVergeStart %11 = rightGrassStart * Bits 5-7: records which routine set this colour, along with bit 2 %000 = colour not set yet %001 = set by SetBackground %010 = set by UpdateBackground to the value in backgroundRight %100 = set by UpdateBackground to the value in backgroundLeft The contents of bits 2-7 are only used by the GetColour routine in the Acornsoft version (though their being non-zero is used to differentiate black from an unset colour by SetBackground). In the Superior Software release, GetColour was recoded to be smaller, and the recoded version only uses bits 0-1, with bits 2-7 being unused..sectionSteering SKIP 26 \ The carSteering value to steer round the corner for a \ track section \ \ The various bits are as for carSteering: \ \ * Bits 0-5 = the amount of steering as a positive \ value (0 to 31) \ \ * Bit 6 = controls whether to apply steering in the \ MoveCars routine \ \ * Clear = always apply steering \ \ * Set = only apply steering if there is enough \ room on the track \ \ * Bit 7 = the direction of the steering \ \ * Clear = steer left \ \ * Set = steer right EQUB &00, &00 \ These bytes appear to be unused EQUB &00, &00 EQUB &00, &00Name: sectionSteering [Show more] Type: Variable Category: Tactics Summary: The optimum steering for each section Deep dive: Tactics of the non-player driversContext: See this variable on its own page References: This variable is used as follows: * GetSectionSteering uses sectionSteering * GetSegmentSteering uses sectionSteering.vergePixelMask EQUB %00000000 \ Colour 3 then 0 (green then black) bbbb bbbb EQUB %10001000 \ gbbb bbbb EQUB %11001100 \ * pixelMaskVerge for leftVergeStart ggbb bbbb EQUB %11101110 \ * pixelMaskNoVerge for leftTrackStart gggb bbbb EQUB %00001111 \ Colour 3 then 1 (green then red) rrrr rrrr EQUB %10001111 \ grrr rrrr EQUB %11001111 \ ggrr rrrr EQUB %11101111 \ gggr rrrr EQUB %11110000 \ Colour 3 then 2 (green then white) wwww wwww EQUB %11111000 \ gwww wwww EQUB %11111100 \ * pixelMaskVerge for leftTrackStart ggww wwww EQUB %11111110 \ gggw wwww EQUB %00000000 \ Colour 1 then 0 (red then black) bbbb bbbb EQUB %00001000 \ rbbb bbbb EQUB %00001100 \ rrbb bbbb EQUB %00001110 \ rrrb bbbb EQUB %00000000 \ Colour 2 then 0 (white then black) bbbb bbbb EQUB %10000000 \ wbbb bbbb EQUB %11000000 \ * pixelMaskVerge for rightVergeStart wwbb bbbb EQUB %11100000 \ wwwb bbbb EQUB %00001111 \ Colour 0 then 1 (black then red) rrrr rrrr EQUB %00000111 \ brrr rrrr EQUB %00000011 \ bbrr rrrr EQUB %00000001 \ bbbr rrrr EQUB %11110000 \ Colour 0 then 2 (black then white) wwww wwww EQUB %01110000 \ bwww wwww EQUB %00110000 \ bbww wwww EQUB %00010000 \ bbbw wwww EQUB %11111111 \ Colour 0 then 3 (black then green) gggg gggg EQUB %01110111 \ bggg gggg EQUB %00110011 \ * pixelMaskVerge for rightGrassStart bbgg gggg EQUB %00010001 \ * pixelMaskNoVerge for rightVergeStart bbbg gggg \ * pixelMaskNoVerge for rightGrassStart EQUB %11111111 \ Colour 1 then 3 (red then green) gggg gggg EQUB %01111111 \ rggg gggg EQUB %00111111 \ rrgg gggg EQUB %00011111 \ rrrg gggg EQUB %11111111 \ Colour 2 then 3 (white then green) gggg gggg EQUB %11110111 \ wggg gggg EQUB %11110011 \ wwgg gggg EQUB %11110001 \ wwwg gggg EQUB &03, &60 \ These bytes appear to be unusedName: vergePixelMask [Show more] Type: Variable Category: Drawing the track Summary: Pixel bytes for drawing track verge edgesContext: See this variable on its own page References: This variable is used as follows: * DrawSegmentEdge (Part 3 of 7) uses vergePixelMask
This table contains four bytes for each of the different colour schemes for the track verges. The first byte contains four pixels of the fill colour, which gets poked into the byte to the right of the edge byte we are drawing. The other three bytes contain 1, 2 and 3 pixels of the foreground colour, with the pixels coming in from the left. So each batch looks like this if all four pixels are drawn: .... .... x... .... xx.. .... xxx. .... In the comments, this would be denoted as "Colour x then ." as colour x is on the left, then colour . is on the right..scaleRange IF _ACORNSOFT OR _4TRACKS EQUB &6F, &6E \ These values are workspace noise and have no meaning EQUB &32, &00 EQUB &8D, &2B ELIF _SUPERIOR OR _REVSPLUS EQUB &30, &18 \ These values are workspace noise and have no meaning EQUB &0C, &06 EQUB &03, &01 ENDIFName: scaleRange [Show more] Type: Variable Category: 3D objects Summary: Storage for scale factors when scaling objectsContext: See this variable on its own page References: This variable is used as follows: * ScaleObject uses scaleRange.zeroIfYIs55 FOR I%, 0, 255 IF I% = &55 B% = 0 ELSE B% = I% ENDIF EQUB B% NEXTName: zeroIfYIs55 [Show more] Type: Variable Category: Screen buffer Summary: A lookup table for zeroing Y if and only if it is &55Context: See this variable on its own page References: This variable is used as follows: * DRAW_BYTE uses zeroIfYIs55.arctanY FOR I%, 0, 255 EQUB INT(0.5 + ATN(I% / 256) * 256 / ATN(1)) NEXTName: arctanY [Show more] Type: Variable Category: Maths (Geometry) Summary: Table for arctan values when calculating yaw angles Deep dive: TrigonometryContext: See this variable on its own page References: This variable is used as follows: * GetObjYawAngle (Part 2 of 4) uses arctanY * GetObjYawAngle (Part 4 of 4) uses arctanY.divideX FOR I%, 0, 127 IF I% = 0 B% = 255 ELSE B% = INT(0.5 + 256 / (1 + I% / 128)) ENDIF EQUB B% NEXTName: divideX [Show more] Type: Variable Category: Maths (Arithmetic) Summary: Division table for calculating scale factors using 1 / |x-delta| Deep dive: TrigonometryContext: See this variable on its own page References: This variable is used as follows: * GetObjPitchAngle uses divideX.xPlayerCoordHi EQUB 0Name: xPlayerCoordHi [Show more] Type: Variable Category: Car geometry Summary: The high byte of the x-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * AddScaledVector uses xPlayerCoordHi * ApplyDeltas uses xPlayerCoordHi * BuildPlayerCar uses xPlayerCoordHi * GetObjYawAngle (Part 1 of 4) uses xPlayerCoordHi * ResetVariables uses xPlayerCoordHi
The coordinate is stored as a 24-bit number in (xPlayerCoordTop xPlayerCoordHi xPlayerCoordLo)..yPlayerCoordHi EQUB 0Name: yPlayerCoordHi [Show more] Type: Variable Category: Car geometry Summary: The high byte of the y-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * ApplyElevation (Part 5 of 5) uses yPlayerCoordHi * GetObjPitchAngle uses yPlayerCoordHi
The coordinate is stored as a 24-bit number in (yPlayerCoordTop yPlayerCoordHi yPlayerCoordLo)..zPlayerCoordHi EQUB 0Name: zPlayerCoordHi [Show more] Type: Variable Category: Car geometry Summary: The high byte of the z-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * GetObjYawAngle (Part 1 of 4) uses zPlayerCoordHi
The coordinate is stored as a 24-bit number in (zPlayerCoordTop zPlayerCoordHi zPlayerCoordLo)..xPlayerCoordTop EQUB 0Name: xPlayerCoordTop [Show more] Type: Variable Category: Car geometry Summary: The top byte of the x-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * AddScaledVector uses xPlayerCoordTop * ApplyDeltas uses xPlayerCoordTop * BuildPlayerCar uses xPlayerCoordTop * GetObjYawAngle (Part 1 of 4) uses xPlayerCoordTop
The coordinate is stored as a 24-bit number in (xPlayerCoordTop xPlayerCoordHi xPlayerCoordLo)..yPlayerCoordTop EQUB 0Name: yPlayerCoordTop [Show more] Type: Variable Category: Car geometry Summary: The top byte of the y-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * ApplyElevation (Part 5 of 5) uses yPlayerCoordTop * GetObjPitchAngle uses yPlayerCoordTop
The coordinate is stored as a 24-bit number in (yPlayerCoordTop yPlayerCoordHi yPlayerCoordLo)..zPlayerCoordTop EQUB 0Name: zPlayerCoordTop [Show more] Type: Variable Category: Car geometry Summary: The top byte of the z-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * GetObjYawAngle (Part 1 of 4) uses zPlayerCoordTop
The coordinate is stored as a 24-bit number in (zPlayerCoordTop zPlayerCoordHi zPlayerCoordLo)..xRoadSignCoordLo EQUB 0Name: xRoadSignCoordLo [Show more] Type: Variable Category: 3D objects Summary: The low byte of the x-coordinate of the road sign's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * AddScaledVector uses xRoadSignCoordLo
Stored as a 16-bit value (xRoadSignCoordHi xRoadSignCoordLo)..yRoadSignCoordLo EQUB 0Name: yRoadSignCoordLo [Show more] Type: Variable Category: 3D objects Summary: The low byte of the y-coordinate of the road sign's 3D coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (yRoadSignCoordHi yRoadSignCoordLo)..zRoadSignCoordLo EQUB 0Name: zRoadSignCoordLo [Show more] Type: Variable Category: 3D objects Summary: The low byte of the z-coordinate of the road sign's 3D coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zRoadSignCoordHi zRoadSignCoordLo)..xRoadSignCoordHi EQUB 0Name: xRoadSignCoordHi [Show more] Type: Variable Category: 3D objects Summary: The high byte of the x-coordinate of the road sign's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * AddScaledVector uses xRoadSignCoordHi
Stored as a 16-bit value (xRoadSignCoordHi xRoadSignCoordLo)..yRoadSignCoordHi EQUB 0Name: yRoadSignCoordHi [Show more] Type: Variable Category: 3D objects Summary: The high byte of the y-coordinate of the road sign's 3D coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (yRoadSignCoordHi yRoadSignCoordLo)..zRoadSignCoordHi EQUB 0 EQUB &00, &00 \ These bytes appear to be unused EQUB &00Name: zRoadSignCoordHi [Show more] Type: Variable Category: 3D objects Summary: The high byte of the z-coordinate of the road sign's 3D coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zRoadSignCoordHi zRoadSignCoordLo)..objectPalette EQUB 0 EQUB 0 EQUB 0 EQUB 0Name: objectPalette [Show more] Type: Variable Category: 3D objects Summary: The object colour palette that maps logical colours 0 to 3 to physical coloursContext: See this variable on its own page References: This variable is used as follows: * DrawObject uses objectPalette * DrawObjectEdge (Part 1 of 5) uses objectPalette * DrawObjectEdge (Part 3 of 5) uses objectPalette * DrawSegmentEdge (Part 3 of 7) uses objectPalette * DrawSegmentEdge (Part 4 of 7) uses objectPalette * DrawSegmentEdge (Part 6 of 7) uses objectPalette * DrawVergeByteLeft uses objectPalette * DrawVergeByteRight uses objectPalette
This table is also used for storing pixel bytes when drawing edges of the track verges..mirrorContents EQUB 0 \ Mirror segment 0 (left mirror, outer segment) EQUB 0 \ Mirror segment 1 (left mirror, middle segment) EQUB 0 \ Mirror segment 2 (left mirror, inner segment) EQUB 0 \ Mirror segment 3 (right mirror, inner segment) EQUB 0 \ Mirror segment 4 (right mirror, middle segment) EQUB 0 \ Mirror segment 5 (right mirror, outer segment)Name: mirrorContents [Show more] Type: Variable Category: Dashboard Summary: Contains the size of the car in each mirror segment Deep dive: Wing mirrorsContext: See this variable on its own page References: This variable is used as follows: * ResetVariables uses mirrorContents * UpdateMirrors uses mirrorContents.markerData EQUB 0 EQUB 0 EQUB 0Name: markerData [Show more] Type: Variable Category: Track geometry Summary: The segment flags for each of the three corner markersContext: See this variable on its own page References: This variable is used as follows: * DrawCornerMarkers uses markerData * GetVergeAndMarkers (Part 3 of 4) uses markerData.vergeEdgeRight EQUB 0 \ Includes all four pixels xxxx EQUB 0 \ Includes pixels 1, 2, 3 .xxx EQUB 0 \ Includes pixels 2, 3 ..xx EQUB 0 \ Includes pixel 3 ...xName: vergeEdgeRight [Show more] Type: Variable Category: Drawing the track Summary: Contain the four pixel bytes for the verge edge we are drawing, masked to only include the rightmost 4, 3, 2 and 1 pixelsContext: See this variable on its own page References: This variable is used as follows: * DrawSegmentEdge (Part 3 of 7) uses vergeEdgeRight * DrawVergeByteLeft uses vergeEdgeRight * DrawVergeByteRight uses vergeEdgeRight.sinYawAngleLo EQUB 0Name: sinYawAngleLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the sine of the player's yaw angleContext: See this variable on its own page References: This variable is used as follows: * GetRotationMatrix (Part 2 of 5) uses sinYawAngleLo * GetRotationMatrix (Part 3 of 5) uses sinYawAngleLo * GetRotationMatrix (Part 5 of 5) uses sinYawAngleLo * MultiplyCoords uses sinYawAngleLo
Stored as a 16-bit value (sinYawAngleHi sinYawAngleLo)..cosYawAngleLo EQUB 0Name: cosYawAngleLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the cosine of the player's yaw angleContext: See this variable on its own page References: This variable is used as follows: * GetRotationMatrix (Part 5 of 5) uses cosYawAngleLo
Stored as a 16-bit value (cosYawAngleHi cosYawAngleLo)..steeringLo EQUB 0Name: steeringLo [Show more] Type: Variable Category: Dashboard Summary: The low byte of the steering wheel position Deep dive: Computer assisted steering (CAS)Context: See this variable on its own page References: This variable is used as follows: * AssistSteering uses steeringLo * ProcessDrivingKeys (Part 2 of 6) uses steeringLo * SetSteeringLimit uses steeringLo * UpdateDashboard uses steeringLo
The steering wheel position is stored as (steeringHi steeringLo), with the sign bit in bit 0 of steeringLo, so it's a sign-magnitude number. Negative (bit 0 set) means we are steering left, positive (bit 0 clear) means we are steering right..sinYawAngleHi EQUB 0Name: sinYawAngleHi [Show more] Type: Variable Category: Driving model Summary: High byte of the sine of the player's yaw angleContext: See this variable on its own page References: This variable is used as follows: * GetRotationMatrix (Part 2 of 5) uses sinYawAngleHi * GetRotationMatrix (Part 3 of 5) uses sinYawAngleHi * MultiplyCoords uses sinYawAngleHi
Stored as a 16-bit value (sinYawAngleHi sinYawAngleLo)..cosYawAngleHi EQUB 0Name: cosYawAngleHi [Show more] Type: Variable Category: Driving model Summary: High byte of the cosine of the player's yaw angleContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (cosYawAngleHi cosYawAngleLo)..steeringHi EQUB 0Name: steeringHi [Show more] Type: Variable Category: Dashboard Summary: The high byte of the steering wheel position Deep dive: Computer assisted steering (CAS)Context: See this variable on its own page References: This variable is used as follows: * AssistSteering uses steeringHi * ProcessDrivingKeys (Part 2 of 6) uses steeringHi * SetSteeringLimit uses steeringHi * UpdateDashboard uses steeringHi
The steering wheel position is stored as (steeringHi steeringLo), with the sign bit in bit 0 of steeringLo, so it's a sign-magnitude number. Negative (bit 0 set) means we are steering left, positive (bit 0 clear) means we are steering right..tyreSqueal EQUB 0 \ Front tyres EQUB 0 \ Rear tyresName: tyreSqueal [Show more] Type: Variable Category: Driving model Summary: A flag to determine whether the front or rear tyres are squealingContext: See this variable on its own page References: This variable is used as follows: * ApplyTyreForces uses tyreSqueal * ApplyTyresAndSkids uses tyreSqueal * MakeDrivingSounds uses tyreSqueal * SquealTyres uses tyreSqueal
If bit 7 is set in either of these, we make the sound of squealing tyres..wingSetting EQUB 0 \ Front wing setting, scaled to the range 90 to 218 EQUB 0 \ Rear wing setting, scaled to the range 90 to 218Name: wingSetting [Show more] Type: Variable Category: Driving model Summary: Contains the scaled wing settingsContext: See this variable on its own page References: This variable is used as follows: * ApplyGrassOrTrack uses wingSetting * ScaleWingSettings uses wingSetting.wingForce EQUB 0 \ Front wing EQUB 0 \ Rear wingName: wingForce [Show more] Type: Variable Category: Driving model Summary: The downward force from the front and rear wingsContext: See this variable on its own page References: This variable is used as follows: * ApplyGrassOrTrack uses wingForce * ApplyTyreForces uses wingForce * GetTyreForces uses wingForce.wingForce95 EQUB 0 \ Front wing EQUB 0 \ Rear wingName: wingForce95 [Show more] Type: Variable Category: Driving model Summary: 95% of the downward force from the front and rear wingsContext: See this variable on its own page References: This variable is used as follows: * ApplyGrassOrTrack uses wingForce95 * ApplySkidForces uses wingForce95.xPlayerSpeedLo EQUB 0Name: xPlayerSpeedLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the x-coordinate of the velocity vector (i.e. x-axis speed) for the player's car during this main loop iterationContext: See this variable on its own page References: This variable is used as follows: * UpdateVelocity uses xPlayerSpeedLo
The speed is stored as a 24-bit number in (xPlayerSpeedTop xPlayerSpeedHi xPlayerSpeedLo)..zPlayerSpeedLo EQUB 0Name: zPlayerSpeedLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the z-coordinate of the velocity vector (i.e. z-axis speed) for the player's car during this main loop iterationContext: See this variable on its own page References: No direct references to this variable in this source file
The speed is stored as a 24-bit number in (zPlayerSpeedTop zPlayerSpeedHi zPlayerSpeedLo)..spinYawAngleLo EQUB 0Name: spinYawAngleLo [Show more] Type: Variable Category: Car geometry Summary: Low byte of the amount of yaw angle spin that is being applied to the player's carContext: See this variable on its own page References: No direct references to this variable in this source file
The spin is stored as a 24-bit number in (spinYawAngleTop spinYawAngleHi spinYawAngleLo)..xPlayerCoordLo EQUB 0Name: xPlayerCoordLo [Show more] Type: Variable Category: Car geometry Summary: The low byte of the x-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: This variable is used as follows: * ApplyDeltas uses xPlayerCoordLo
The coordinate is stored as a 24-bit number in (xPlayerCoordTop xPlayerCoordHi xPlayerCoordLo)..yPlayerCoordLo EQUB 0Name: yPlayerCoordLo [Show more] Type: Variable Category: Car geometry Summary: The low byte of the y-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
The coordinate is stored as a 24-bit number in (yPlayerCoordTop yPlayerCoordHi yPlayerCoordLo)..zPlayerCoordLo EQUB 0Name: zPlayerCoordLo [Show more] Type: Variable Category: Car geometry Summary: The low byte of the z-coordinate of the player's 3D coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
The coordinate is stored as a 24-bit number in (zPlayerCoordTop zPlayerCoordHi zPlayerCoordLo)..markerListIndex EQUB 0 EQUB 0 EQUB 0Name: markerListIndex [Show more] Type: Variable Category: Track geometry Summary: The index of the corresponding entry in the track segment list for each of the three corner markersContext: See this variable on its own page References: This variable is used as follows: * DrawCornerMarkers uses markerListIndex * GetVergeAndMarkers (Part 3 of 4) uses markerListIndex.xMarkerLo EQUB 0 EQUB 0 EQUB 0Name: xMarkerLo [Show more] Type: Variable Category: Track geometry Summary: Low byte of the x-axis distance between the track edge and the three corner markersContext: See this variable on its own page References: This variable is used as follows: * DrawCornerMarkers uses xMarkerLo * GetVergeAndMarkers (Part 3 of 4) uses xMarkerLo
Stored as a 16-bit value (xMarkerHi xMarkerLo)..xMarkerHi EQUB 0 EQUB 0 EQUB 0Name: xMarkerHi [Show more] Type: Variable Category: Track geometry Summary: High byte of the x-axis distance between the track edge and the three corner markersContext: See this variable on its own page References: This variable is used as follows: * DrawCornerMarkers uses xMarkerHi * GetVergeAndMarkers (Part 3 of 4) uses xMarkerHi
Stored as a 16-bit value (xMarkerHi xMarkerLo)..soundBuffer EQUB 0 EQUB 0 EQUB 0 EQUB 0 EQUB 0 EQUB 0Name: soundBuffer [Show more] Type: Variable Category: Sound Summary: Details of each sound channel's buffer status Deep dive: The engine soundsContext: See this variable on its own page References: This variable is used as follows: * ApplyTyresAndSkids uses soundBuffer * FlushSoundBuffer uses soundBuffer * MakeSound uses soundBuffer.characterDef EQUB 0 \ The character number EQUB 0, 0, 0, 0 \ The eight bytes that make up the character definition, EQUB 0, 0, 0, 0 \ which gets populated by an OSWORD callName: characterDef [Show more] Type: Variable Category: Text Summary: Storage for a character definition when printing charactersContext: See this variable on its own page References: This variable is used as follows: * PrintCharacter uses characterDef.xCursor EQUB 0Name: xCursor [Show more] Type: Variable Category: Text Summary: The cursor's x-coordinate, which can either be a pixel coordinate or a character rowContext: See this variable on its own page References: This variable is used as follows: * Print2DigitBCD uses xCursor * PrintBestLapTime uses xCursor * PrintCharacter uses xCursor * PrintFirstLine uses xCursor * PrintGearNumber uses xCursor * PrintLapTime uses xCursor * PrintNearestDriver uses xCursor.yCursor EQUB 0 EQUB &00, &00 \ These bytes appear to be unusedName: yCursor [Show more] Type: Variable Category: Text Summary: The cursor's pixel y-coordinateContext: See this variable on its own page References: This variable is used as follows: * Print2DigitBCD uses yCursor * PrintBestLapTime uses yCursor * PrintCharacter uses yCursor * PrintFirstLine uses yCursor * PrintGearNumber uses yCursor * PrintLapTime uses yCursor * PrintNearestDriver uses yCursor
In terms of printing text on-screen, we need to set: * yCursor = 24 for the first line of text * yCursor = 33 for the second line of text See the notes on the yLookupHi variable for information about the values of yCursor and how they relate to the custom screen..xPlayerSpeedHi EQUB 0Name: xPlayerSpeedHi [Show more] Type: Variable Category: Driving model Summary: High byte of the x-coordinate of the velocity vector (i.e. x-axis speed) for the player's car during this main loop iterationContext: See this variable on its own page References: This variable is used as follows: * AddCoords uses xPlayerSpeedHi * AddSteeringForce uses xPlayerSpeedHi * ApplyDeltas uses xPlayerSpeedHi * CheckForCrash uses xPlayerSpeedHi * MultiplyCoords uses xPlayerSpeedHi * Scale16Bit uses xPlayerSpeedHi * UpdateVelocity uses xPlayerSpeedHi
The speed is stored as a 24-bit number in (xPlayerSpeedTop xPlayerSpeedHi xPlayerSpeedLo)..zPlayerSpeedHi EQUB 0Name: zPlayerSpeedHi [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the velocity vector (i.e. z-axis speed) for the player's car during this main loop iterationContext: See this variable on its own page References: No direct references to this variable in this source file
The speed is stored as a 24-bit number in (zPlayerSpeedTop zPlayerSpeedHi zPlayerSpeedLo)..spinYawAngleHi EQUB 0Name: spinYawAngleHi [Show more] Type: Variable Category: Car geometry Summary: High byte of the amount of yaw angle spin that is being applied to the player's carContext: See this variable on its own page References: This variable is used as follows: * ApplyBounce uses spinYawAngleHi * ApplyDeltas uses spinYawAngleHi * ApplySpinYaw uses spinYawAngleHi * SpinTrackSection uses spinYawAngleHi
The spin is stored as a 24-bit number in (spinYawAngleTop spinYawAngleHi spinYawAngleLo)..xAccelerationLo EQUB 0Name: xAccelerationLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the x-coordinate of the change in velocity of the player's car in terms of 3D world coordinatesContext: See this variable on its own page References: This variable is used as follows: * UpdateVelocity uses xAccelerationLo
Stored as a 16-bit value (xAccelerationHi xAccelerationLo)..zAccelerationLo EQUB 0Name: zAccelerationLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the z-coordinate of the change in velocity of the player's car in terms of 3D world coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zAccelerationHi zAccelerationLo)..spinYawDeltaLo EQUB 0Name: spinYawDeltaLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the change in the spin yaw angle for the player's carContext: See this variable on its own page References: This variable is used as follows: * ApplyDrivingModel uses spinYawDeltaLo * ScaleTyreForces uses spinYawDeltaLo
Stored as a 16-bit value (spinYawDeltaHi spinYawDeltaLo)..xPlayerAccelLo EQUB 0Name: xPlayerAccelLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the x-coordinate of the change in velocity of the player's car in the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ScaleTyreForces uses xPlayerAccelLo
Stored as a 16-bit value (xPlayerAccelHi xPlayerAccelLo)..zPlayerAccelLo EQUB 0Name: zPlayerAccelLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the z-coordinate of the change in velocity of the player's car in the player's frame of referenceContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zPlayerAccelHi zPlayerAccelLo)..xVelocityLo EQUB 0Name: xVelocityLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the x-coordinate of the player's velocity vector, from the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ApplyDrivingModel uses xVelocityLo * ApplySpinYaw uses xVelocityLo * ApplyTyreForces uses xVelocityLo
Stored as a 16-bit value (xVelocityHi xVelocityLo)..zVelocityLo EQUB 0Name: zVelocityLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the z-coordinate of the player's velocity vector, from the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ApplyDrivingModel uses zVelocityLo
Stored as a 16-bit value (zVelocityHi zVelocityLo)..xTyreForceNoseLo EQUB 0Name: xTyreForceNoseLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the x-coordinate of the force vector produced by the front tyres in the nose of the carContext: See this variable on its own page References: This variable is used as follows: * ApplyLimitAndSign uses xTyreForceNoseLo * ApplySkidForces uses xTyreForceNoseLo * ApplyTyreForces uses xTyreForceNoseLo * ProcessDrivingKeys (Part 2 of 6) uses xTyreForceNoseLo * ScaleTyreForces uses xTyreForceNoseLo
Stored as a 16-bit value (xTyreForceNoseHi xTyreForceNoseLo)..xTyreForceRearLo EQUB 0Name: xTyreForceRearLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the x-coordinate of the force vector produced by the rear tyres of the carContext: See this variable on its own page References: This variable is used as follows: * ScaleTyreForces uses xTyreForceRearLo
Stored as a 16-bit value (xTyreForceRearHi xTyreForceRearLo)..zTyreForceNoseLo EQUB 0Name: zTyreForceNoseLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the z-coordinate of the force vector produced by the front tyres in the nose of the carContext: See this variable on its own page References: This variable is used as follows: * ApplySkidForces uses zTyreForceNoseLo * ApplyTyreForces uses zTyreForceNoseLo
Stored as a 16-bit value (zTyreForceNoseHi zTyreForceNoseLo)..zTyreForceRearLo EQUB 0Name: zTyreForceRearLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the z-coordinate of the force vector produced by the rear tyresContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zTyreForceRearHi zTyreForceRearLo)..xSteeringForceLo EQUB 0Name: xSteeringForceLo [Show more] Type: Variable Category: Driving model Summary: Low byte of the sideways force applied by steeringContext: See this variable on its own page References: This variable is used as follows: * AddSteeringForce uses xSteeringForceLo
Stored as a 16-bit value (xSteeringForceHi xSteeringForceLo)..mainLoopCounterHi EQUB 0Name: mainLoopCounterHi [Show more] Type: Variable Category: Main loop Summary: High byte of the main loop counter, which increments on each iteration of the main driving loop Deep dive: Scheduling tasks in the main loopContext: See this variable on its own page References: This variable is used as follows: * FinishRace uses mainLoopCounterHi * ProcessTime uses mainLoopCounterHi
Stored as a 16-bit value (mainLoopCounterHi mainLoopCounterLo)..xPlayerSpeedTop EQUB 0Name: xPlayerSpeedTop [Show more] Type: Variable Category: Driving model Summary: Top byte of the x-coordinate of the velocity vector (i.e. x-axis speed) for the player's car during this main loop iterationContext: See this variable on its own page References: This variable is used as follows: * AddCoords uses xPlayerSpeedTop * AddSteeringForce uses xPlayerSpeedTop * ApplyDeltas uses xPlayerSpeedTop * MultiplyCoords uses xPlayerSpeedTop * Scale16Bit uses xPlayerSpeedTop * UpdateVelocity uses xPlayerSpeedTop
The speed is stored as a 24-bit number in (xPlayerSpeedTop xPlayerSpeedHi xPlayerSpeedLo)..zPlayerSpeedTop EQUB 0Name: zPlayerSpeedTop [Show more] Type: Variable Category: Driving model Summary: Top byte of the z-coordinate of the velocity vector (i.e. z-axis speed) for the player's car during this main loop iterationContext: See this variable on its own page References: No direct references to this variable in this source file
The speed is stored as a 24-bit number in (zPlayerSpeedTop zPlayerSpeedHi zPlayerSpeedLo)..spinYawAngleTop EQUB 0Name: spinYawAngleTop [Show more] Type: Variable Category: Car geometry Summary: Top byte of the amount of yaw angle spin that is being applied to the player's carContext: See this variable on its own page References: This variable is used as follows: * ApplyDeltas uses spinYawAngleTop * ApplySpinYaw uses spinYawAngleTop * CheckForCrash uses spinYawAngleTop * MovePlayerSegment uses spinYawAngleTop * SpinTrackSection uses spinYawAngleTop * SquealTyres uses spinYawAngleTop
The spin is stored as a 24-bit number in (spinYawAngleTop spinYawAngleHi spinYawAngleLo)..xAccelerationHi EQUB 0Name: xAccelerationHi [Show more] Type: Variable Category: Driving model Summary: High byte of the x-coordinate of the change in velocity of the player's car in terms of 3D world coordinatesContext: See this variable on its own page References: This variable is used as follows: * UpdateVelocity uses xAccelerationHi
Stored as a 16-bit value (xAccelerationHi xAccelerationLo)..zAccelerationHi EQUB 0Name: zAccelerationHi [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the change in velocity of the player's car in terms of 3D world coordinatesContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zAccelerationHi zAccelerationLo)..spinYawDeltaHi EQUB 0Name: spinYawDeltaHi [Show more] Type: Variable Category: Driving model Summary: High byte of the change in the spin yaw angle for the player's carContext: See this variable on its own page References: This variable is used as follows: * ApplyDrivingModel uses spinYawDeltaHi * ScaleTyreForces uses spinYawDeltaHi
Stored as a 16-bit value (spinYawDeltaHi spinYawDeltaLo)..xPlayerAccelHi EQUB 0Name: xPlayerAccelHi [Show more] Type: Variable Category: Driving model Summary: High byte of the x-coordinate of the change in velocity of the player's car in the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ScaleTyreForces uses xPlayerAccelHi
Stored as a 16-bit value (xPlayerAccelHi xPlayerAccelLo)..zPlayerAccelHi EQUB 0Name: zPlayerAccelHi [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the change in velocity of the player's car in the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ScaleTyreForces uses zPlayerAccelHi
Stored as a 16-bit value (zPlayerAccelHi zPlayerAccelLo)..xVelocityHi EQUB 0Name: xVelocityHi [Show more] Type: Variable Category: Driving model Summary: High byte of the x-coordinate of the player's velocity vector, from the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ApplyDrivingModel uses xVelocityHi * ApplySkidForces uses xVelocityHi * ApplySpinYaw uses xVelocityHi * ApplyTyreForces uses xVelocityHi
Stored as a 16-bit value (xVelocityHi xVelocityLo)..zVelocityHi EQUB 0Name: zVelocityHi [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the player's velocity vector, from the player's frame of referenceContext: See this variable on its own page References: This variable is used as follows: * ApplyDrivingModel uses zVelocityHi * ApplyGrassOrTrack uses zVelocityHi * ApplyWingBalance uses zVelocityHi * GetTyreForces uses zVelocityHi
Stored as a 16-bit value (zVelocityHi zVelocityLo)..xTyreForceNoseHi EQUB 0Name: xTyreForceNoseHi [Show more] Type: Variable Category: Driving model Summary: High byte of the x-coordinate of the force vector produced by the front tyres in the nose of the carContext: See this variable on its own page References: This variable is used as follows: * ApplyLimitAndSign uses xTyreForceNoseHi * ApplySkidForces uses xTyreForceNoseHi * ApplyTyreForces uses xTyreForceNoseHi * ProcessDrivingKeys (Part 2 of 6) uses xTyreForceNoseHi * ScaleTyreForces uses xTyreForceNoseHi
Stored as a 16-bit value (xTyreForceNoseHi xTyreForceNoseLo)..xTyreForceRearHi EQUB 0Name: xTyreForceRearHi [Show more] Type: Variable Category: Driving model Summary: High byte of the x-coordinate of the force vector produced by the rear tyres of the carContext: See this variable on its own page References: This variable is used as follows: * ScaleTyreForces uses xTyreForceRearHi
Stored as a 16-bit value (xTyreForceRearHi xTyreForceRearLo)..zTyreForceNoseHi EQUB 0Name: zTyreForceNoseHi [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the force vector produced by the front tyres in the nose of the carContext: See this variable on its own page References: This variable is used as follows: * ApplySkidForces uses zTyreForceNoseHi * ApplyTyreForces uses zTyreForceNoseHi
Stored as a 16-bit value (zTyreForceNoseHi zTyreForceNoseLo)..zTyreForceRearHi EQUB 0Name: zTyreForceRearHi [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the force vector produced by the rear tyresContext: See this variable on its own page References: No direct references to this variable in this source file
Stored as a 16-bit value (zTyreForceRearHi zTyreForceRearLo)..xSteeringForceHi EQUB 0Name: xSteeringForceHi [Show more] Type: Variable Category: Driving model Summary: High byte of the sideways force applied by steeringContext: See this variable on its own page References: This variable is used as follows: * AddSteeringForce uses xSteeringForceHi
Stored as a 16-bit value (xSteeringForceHi xSteeringForceLo)..firstLapStarted EQUB 0Name: firstLapStarted [Show more] Type: Variable Category: Drivers Summary: Flag to keep track of whether we have started the first lap of practice or qualifyingContext: See this variable on its own page References: This variable is used as follows: * ResetVariables uses firstLapStarted * UpdateLapTimers uses firstLapStarted
For practice and qualifying laps, firstLapStarted keeps track of whether we have started the first lap (at which point the lap timer starts). Before we reach the starting line, firstLapStarted is -33, which is the value it gets in ResetVariables for practice or qualifying laps. This is then incremented to 0 when we start the first lap. The value of firstLapStarted is decremented with each call to UpdateLapTimers for practice or qualifying, but only if bit 6 of updateDrivingInfo is set and firstLapStarted is non-zero. I am not sure why..liftFromTorque EQUB 0Name: liftFromTorque [Show more] Type: Variable Category: Driving model Summary: The lift of the front of the car caused by acceleration or brakingContext: See this variable on its own page References: This variable is used as follows: * ApplyElevation (Part 1 of 5) uses liftFromTorque * ApplyElevation (Part 3 of 5) uses liftFromTorque.wingBalance EQUB 0Name: wingBalance [Show more] Type: Variable Category: Driving model Summary: Value used in the driving model when calculating the effect of the two wing settingsContext: See this variable on its own page References: This variable is used as follows: * ApplyWingBalance uses wingBalance * ScaleWingSettings uses wingBalance
The wing balance is calculated as: 60 + (rearWingSetting * 3 + frontWingSetting) / 2.playerSideways EQUB 0Name: playerSideways [Show more] Type: Variable Category: Car geometry Summary: Contains the player's heading, for testing whether the car is pointing sidewaysContext: See this variable on its own page References: This variable is used as follows: * ApplyElevation (Part 2 of 5) uses playerSideways * SetVergeBackground uses playerSideways * UpdateBackground uses playerSideways
If playerSideways < 40, then the player's car is facing forwards or backwards along the track. If playerSideways >= 40, then the player's car is facing sideways, relative to the direction of the track..thisObjectType EQUB 0Name: thisObjectType [Show more] Type: Variable Category: 3D objects Summary: The type of object we are currently drawingContext: See this variable on its own page References: This variable is used as follows: * DrawObject uses thisObjectType.thisDriverNumber EQUB 0Name: thisDriverNumber [Show more] Type: Variable Category: Drawing objects Summary: The number of the current driver when drawing carsContext: See this variable on its own page References: This variable is used as follows: * MoveAndDrawCars uses thisDriverNumber.newSectionFetched EQUB 0 \ Track section status: \ \ * 0 = no new section \ \ * Non-zero = the player's car has entered a new \ track sectionName: newSectionFetched [Show more] Type: Variable Category: Track geometry Summary: Flag that determines whether a new track section has been fetchedContext: See this variable on its own page References: This variable is used as follows: * GetFirstSegment uses newSectionFetched * GetSectionAngles (Part 1 of 3) uses newSectionFetched.crashedIntoFence EQUB 0 \ Crash status \ \ * 0 = we have not crashed into the fence \ \ * &FF = we have crashed into the fenceName: crashedIntoFence [Show more] Type: Variable Category: Car geometry Summary: Flag that records whether we have crashed into the fenceContext: See this variable on its own page References: This variable is used as follows: * CheckForCrash uses crashedIntoFence * MainDrivingLoop (Part 3 of 5) uses crashedIntoFence.irqCounter EQUB 0Name: irqCounter [Show more] Type: Variable Category: Screen mode Summary: Counter that gets incremented every time the IRQ routine reaches section 4 of the custom screenContext: See this variable on its own page References: This variable is used as follows: * AnimateTyres uses irqCounter * MainDrivingLoop (Part 3 of 5) uses irqCounter.updateLapTimes EQUB 0Name: updateLapTimes [Show more] Type: Variable Category: Drivers Summary: Controls whether moving the car forward updates the lap number and lap timesContext: See this variable on its own page References: This variable is used as follows: * PlaceCarsOnTrack uses updateLapTimes * UpdateLaps uses updateLapTimes.previousSignNumber EQUB 0Name: previousSignNumber [Show more] Type: Variable Category: Track geometry Summary: Stores the number of the sign from the previous call to the BuildRoadSign routineContext: See this variable on its own page References: This variable is used as follows: * BuildRoadSign uses previousSignNumber * ResetVariables uses previousSignNumber
Set to 23 in ResetVariables..tyreTravel EQUB 0Name: tyreTravel [Show more] Type: Variable Category: Dashboard Summary: Keeps track of how far we have travelled so we know when to animate the tyresContext: See this variable on its own page References: This variable is used as follows: * AnimateTyres uses tyreTravel.playerDrift EQUB 0 \ If bit 7 is set, then the player's car is moving \ sideways by more than 22 in this iteration around the \ main driving loop (where the track width is 256)Name: playerDrift [Show more] Type: Variable Category: Driving model Summary: Records whether the player's car is moving sideways by a significant amountContext: See this variable on its own page References: This variable is used as follows: * ApplyGrassOrTrack uses playerDrift * MovePlayerOnTrack uses playerDrift * SetPlayerDriftSup uses playerDrift.horizonTrackWidth EQUB 0Name: horizonTrackWidth [Show more] Type: Variable Category: Track geometry Summary: The arc of the track at the horizon (i.e. the track width at the horizon), halvedContext: See this variable on its own page References: This variable is used as follows: * DrawObject uses horizonTrackWidth * GetTrackAndMarkers uses horizonTrackWidth.lowestTrackLine EQUB 0Name: lowestTrackLine [Show more] Type: Variable Category: Screen buffer Summary: Used to prevent objects from being drawn below the horizon lineContext: See this variable on its own page References: This variable is used as follows: * DrawObject uses lowestTrackLine * DrawObjectEdges uses lowestTrackLine.updateDriverInfo EQUB 0Name: updateDriverInfo [Show more] Type: Variable Category: Text Summary: Flag that controls whether the driver names are updated in the information block at the top of the screenContext: See this variable on its own page References: This variable is used as follows: * ProcessOvertaking (Part 1 of 3) uses updateDriverInfo * ResetVariables uses updateDriverInfo * UpdatePositionInfo uses updateDriverInfo
If bit 7 is set, then we update the driver names in the "In front" and "Behind" sections at the top of the screen. Bit 7 gets set in ResetVariables, for race laps only..zTyreForceBoth EQUB 0Name: zTyreForceBoth [Show more] Type: Variable Category: Driving model Summary: High byte of the z-coordinate of the force vector produced by the front and tyres combinedContext: See this variable on its own page References: This variable is used as follows: * ApplyGrassOrTrack uses zTyreForceBoth * ScaleTyreForces uses zTyreForceBoth