| C64 ROM | Routines |
| Prev: A613 | Up: Map | Next: A642 |
|
Used by the routine at A8C0.
returns carry set if found
|
||||
| A617 | A0 01 | LDY #$01 | set index to next line pointer high byte | |
| A619 | 85 5F | STA $5F | save low byte as current | |
| A61B | 86 60 | STX $60 | save high byte as current | |
| A61D | B1 5F | LDA ($5F),Y | get next line pointer high byte from address | |
| A61F | F0 1F | BEQ $A640 | pointer was zero so done, exit | |
| A621 | C8 | INY | increment index ... | |
| A622 | C8 | INY | ... to line # high byte | |
| A623 | A5 15 | LDA $15 | get temporary integer high byte | |
| A625 | D1 5F | CMP ($5F),Y | compare with line # high byte | |
| A627 | 90 18 | BCC $A641 | exit if temp < this line, target line passed | |
| A629 | F0 03 | BEQ $A62E | go check low byte if = | |
| A62B | 88 | DEY | else decrement index | |
| A62C | D0 09 | BNE $A637 | branch always | |
| A62E | A5 14 | LDA $14 | get temporary integer low byte | |
| A630 | 88 | DEY | decrement index to line # low byte | |
| A631 | D1 5F | CMP ($5F),Y | compare with line # low byte | |
| A633 | 90 0C | BCC $A641 | exit if temp < this line, target line passed | |
| A635 | F0 0A | BEQ $A641 | exit if temp = (found line#) | |
|
not quite there yet
|
||||
| A637 | 88 | DEY | decrement index to next line pointer high byte | |
| A638 | B1 5F | LDA ($5F),Y | get next line pointer high byte | |
| A63A | AA | TAX | copy to X | |
| A63B | 88 | DEY | decrement index to next line pointer low byte | |
| A63C | B1 5F | LDA ($5F),Y | get next line pointer low byte | |
| A63E | B0 D7 | BCS $A617 | go search for line # in temporary integer from AX, carry always set | |
| A640 | 18 | CLC | clear found flag | |
| A641 | 60 | RTS | ||
| Prev: A613 | Up: Map | Next: A642 |