Skip to navigation

Revs on the BBC Micro

Text: PrintPositionName

Name: PrintPositionName [Show more] Type: Subroutine Category: Text Summary: Print the name of the driver in a specific position in the driver position list
Context: See this subroutine in context in the source code References: This subroutine is called as follows: * PrintDriverTable calls PrintPositionName

Arguments: Y The position of the driver whose name we print
Returns: driverPrinted The number of the driver that we printed
.PrintPositionName LDX driversInOrder,Y \ Set X to the number of the driver in position Y STX driverPrinted \ Store the driver number in driverPrinted, so we can \ return it JSR GetDriverAddress \ Set (Y A) to the address of driver X's name JSR PrintDriverName \ Print the name of the driver at address (Y A) RTS \ Return from the subroutine