Skip to navigation

Elite on the BBC Micro

Flight: wW [Elite-A, Flight]

Name: wW [Show more] Type: Subroutine Category: Flight Summary: Start a hyperspace countdown
Context: See this subroutine in context in the source code References: This subroutine is called as follows: * Ghy calls wW

Start the hyperspace countdown (for both inter-system hyperspace and the galactic hyperdrive).
.wW LDA #15 \ The hyperspace countdown starts from 15, so set A to \ to 15 so we can set the two hyperspace counters STA QQ22+1 \ Set the number in QQ22+1 to 15, which is the number \ that's shown on-screen during the hyperspace countdown STA QQ22 \ Set the number in QQ22 to 15, which is the internal \ counter that counts down by 1 each iteration of the \ main game loop, and each time it reaches zero, the \ on-screen counter gets decremented, and QQ22 gets set \ to 5, so setting QQ22 to 15 here makes the first tick \ of the hyperspace counter longer than subsequent ticks \ --- Mod: Original Acornsoft code removed: -----------> \ TAX \ Print the 8-bit number in X (i.e. 15) at text location \ JMP ee3 \ (0, 1), padded to 5 digits, so it appears in the top \ \ left corner of the screen, and return from the \ \ subroutine using a tail call \ --- And replaced by: --------------------------------> TAX \ Print the 8-bit number in X (i.e. 15) at text location BNE ee3 \ (0, 1), padded to 5 digits, so it appears in the top \ left corner of the screen, and return from the \ subroutine using a tail call (the BNE is effectively a \ JMP as A is never zero) \ --- End of replacement ------------------------------>