![]() |
Routines |
| Prev: C7E5 | Up: Map | Next: C959 |
|
Used by the routine at Init_Title_Screen.
|
||||
|
This routine is called at the start of each phase, and makes it faster than than the previous by decreasing the wait time. This starts at 0500 (slowest) and is decreased by 40 for each call, so things generally open faster.
|
||||
| C941 | PUSH AF | Remember some registers. | ||
| C942 | PUSH HL | |||
| C943 | LD HL,($CE1C) | Get the current speed. | ||
| C946 | LD BC,$0040 | Subtract 40 from it. (The AND A clears the carry flag so SBC gives the desired result). | ||
| C949 | AND A | |||
| C94A | SBC HL,BC | |||
| C94C | LD A,H | Is the speed now zero? | ||
| C94D | OR L | |||
| C94E | JR NZ,$C953 | Jump forward if not. | ||
| C950 | LD HL,$0040 | The fastest speed is 40. | ||
| C953 | LD ($CE1C),HL | Set this as the new speed. | ||
| C956 | POP HL | Restore registers. | ||
| C957 | POP AF | |||
| C958 | RET | |||
| Prev: C7E5 | Up: Map | Next: C959 |