Routines |
Prev: $2D3E | Up: Map | Next: $2DAD |
$2D47 | LDA #$20 | Initialise the x-coordinate of the leftmost column of the skool on screen to 32. | ||
$2D49 | STA $58 | |||
$2D4B | LDA #$48 | Initialise the x-coordinate of the leftmost column of the skool off screen to 72. | ||
$2D4D | STA $59 | |||
$2D4F | LDA #$00 | Store the address of the play area tile back buffer ($4000) at $5E for the routine at $3326. | ||
$2D51 | STA $5E | |||
$2D53 | LDA #$40 | |||
$2D55 | STA $5F | |||
$2D57 | LDA #$00 | Store the screen bitmap start address ($E000) at $5A. This is redundant because the routines that use the address stored there will reinitialise it. | ||
$2D59 | STA $5A | |||
$2D5B | LDA #$E0 | |||
$2D5D | STA $5B | |||
$2D5F | LDA #$00 | Store the colour information start address ($CC00) at $5C. This is redundant because the routines that use the address stored there will reinitialise it. | ||
$2D61 | STA $5C | |||
$2D63 | LDA #$CC | |||
$2D65 | STA $5D | |||
$2D67 | LDA #$FF | Initialise the current character number at $60 to $FF. | ||
$2D69 | STA $60 | |||
$2D6B | STA $14 | Initialise ERIC's posture indicator at $14 to $FF: ERIC is standing up. | ||
$2D6D | LDA #$0F | Initialise MSB of the lesson clock at $40 to $0F. | ||
$2D6F | STA $40 | |||
$2D71 | LDA #$00 | Initialise the LSB of the lesson clock at $FD to 0. | ||
$2D73 | STA $FD | |||
$2D75 | STA $D9 | Initialise the shield counter at $D9 to 0. | ||
$2D77 | STA $4B | Clear ERIC's midstride indicator at $4B. | ||
$2D79 | STA $2B | Clear all of ERIC's status flags at $2B. | ||
$2D7B | STA $46 | Initialise the game mode indicator at $46 to 0. | ||
$2D7D | STA $2C | Initialise the sound effect identifier at $2C to 0. | ||
$2D7F | STA $2D | Initialise the sound effect timer at $2D to 0. | ||
$2D81 | STA $D015 | Disable all sprites. | ||
$2D84 | STA $4C | Initialise the keyboard/joystick reading at $4C to 0. | ||
$2D86 | LDA #$01 | Initialise the keyboard/joystick input timer at $E5 to 1. | ||
$2D88 | STA $E5 | |||
$2D8A | LDA #$04 | Initialise ERIC's action timer at $FE to 4. | ||
$2D8C | STA $FE | |||
$2D8E | LDA $D41B | Generate a random value between $00 and $14 in A. | ||
$2D91 | CMP #$15 | |||
$2D93 | BCS $2D8E | |||
$2D95 | TAY | Transfer the random value to Y. | ||
$2D96 | LDA #$46 | Prepare to address of the table of initial lesson numbers at $4650. | ||
$2D98 | STA $4F | |||
$2D9A | LDA #$50 | |||
$2D9C | STA $4E | |||
$2D9E | LDA ($4E),Y | Pick up a randomly chosen value from this table and store it at $41; this initialises the lesson number. | ||
$2DA0 | STA $41 | |||
$2DA2 | DEC $41 | |||
$2DA4 | LDA #$05 | Initialise the keyboard delay counter at $EB to 5. | ||
$2DA6 | STA $EB | |||
$2DA8 | LDA #$44 | Initialise the value at $44 to $44 (this is never used). | ||
$2DAA | STA $44 | |||
$2DAC | RTS |
Prev: $2D3E | Up: Map | Next: $2DAD |