.CopyPointToWork LDA xPointLo,Y \ Copy the Y-th point coordinate to the X-th coordinate STA xTurnHi,X \ in the variable workspace, starting with the low bytes LDA yPointLo,Y STA yTurnHi,X LDA zPointLo,Y STA zTurnHi,X LDA xPointHi,Y \ And then the high bytes STA xTurnTop,X LDA yPointHi,Y STA yTurnTop,X LDA zPointHi,Y STA zTurnTop,X RTS \ Return from the subroutineName: CopyPointToWork [Show more] Type: Subroutine Category: Utility routines Summary: Copy a point from the point tables to the variable workspace Deep dive: Multi-byte variablesContext: See this subroutine in context in the source code References: This subroutine is called as follows: * ApplyFlightModel (Part 2 of 7) calls CopyPointToWork * ApplyFlightModel (Part 6 of 7) calls CopyPointToWork * ExplodeAlien calls CopyPointToWork * ProcessRunwayLine (Part 4 of 5) calls CopyPointToWork
Arguments: Y The ID of the point to copy from the point tables X The low byte of the x-coordinate of the 16-bit workspace point to update: * LO(xVelocityPLo) = (xVelocityP, yVelocityP, zVelocityP) * LO(dxVelocityLo) = (dxVelocity, dyVelocity, dzVelocity) * LO(dxRotationLo) = (dxRotation, dyRotation, dzRotation) * LO(xTemp2Lo) = (xTemp2, yTemp2, zTemp2)
[X]
Variable xPointHi (category: 3D geometry)
High byte of the x-coordinate for a point
[X]
Variable xPointLo in workspace Main variable workspace
The low byte of the x-coordinate for the point with ID X is at xPointLo,X
[X]
Variable xTurnHi in workspace Main variable workspace
Turn rate around the x-axis (high byte)
[X]
Variable xTurnTop in workspace Main variable workspace
Turn rate around the x-axis (top byte)
[X]
Variable yPointHi in workspace Main variable workspace
The high byte of the y-coordinate for the point with ID X is at yPointHi,X
[X]
Variable yPointLo in workspace Main variable workspace
The low byte of the y-coordinate for the point with ID X is at yPointLo,X
[X]
Variable yTurnHi in workspace Main variable workspace
Turn rate around the y-axis (high byte)
[X]
Variable yTurnTop in workspace Main variable workspace
Turn rate around the y-axis (top byte)
[X]
Variable zPointHi (category: 3D geometry)
High byte of the z-coordinate for a point
[X]
Variable zPointLo in workspace Main variable workspace
The low byte of the z-coordinate for the point with ID X is at zPointLo,X
[X]
Variable zTurnHi in workspace Main variable workspace
Turn rate around the z-axis (high byte)
[X]
Variable zTurnTop in workspace Main variable workspace
Turn rate around the z-axis (top byte)