![]() |
Routines |
| Prev: 8690 | Up: Map | Next: 86E4 |
|
Used by the routine at RunTitleMenu.
Reads the keys that choose the number of players ("A" and "B") and the control methods of each player ("1" and "2").
|
||||
| ReadMenuKeys | 86B9 | LD A,$FD | Read the keyboard row "A" to "G". | |
| 86BB | OUT ($FD),A | |||
| 86BD | IN A,($FE) | Test the "A" key. | ||
| 86BF | AND $01 | |||
| 86C1 | JR NZ,ReadMenuKeys_B | Jump to ReadMenuKeys_B if it is not pressed. | ||
| 86C3 | LD ($F2E2),A | Select option zero in TwoPlayerFlag. | ||
| ReadMenuKeys_B | 86C6 | LD A,$7F | Read the keyboard row "B" to "SPACE". | |
| 86C8 | OUT ($FD),A | |||
| 86CA | IN A,($FE) | Test the "B" key. | ||
| 86CC | BIT 4,A | |||
| 86CE | JR NZ,ReadMenuKeys_Icons | Jump to ReadMenuKeys_Icons if it is not pressed. | ||
| 86D0 | LD A,$01 | Select option one in TwoPlayerFlag. | ||
| 86D2 | LD ($F2E2),A | |||
| ReadMenuKeys_Icons | 86D5 | LD IX,$8708 | Use the control icon data for player one. | |
| 86D9 | LD B,$01 | Use the "1" key. | ||
| 86DB | CALL ChangeControlMethod | Check for a change of control method. | ||
| 86DE | LD IX,$870B | Use the control icon data for player two. | ||
| 86E2 | LD B,$02 | Use the "2" key. | ||
|
Continue on to ChangeControlMethod.
|
||||
| Prev: 8690 | Up: Map | Next: 86E4 |