Prev: 59392 Up: Map Next: 59469
59406: Initialise Game
Used by the routine at Alias_InitialiseGame.
InitialiseGame 59406 LD HL,65535 SP=65535.
59409 LD SP,HL
59410 CALL SetRandomNumberSeed Call SetRandomNumberSeed.
59413 LD HL,26664 Write KeyboardInput to ControlMethod.
59416 LD (30800),HL
This entry point is used by the routines at DemoModeInput and GameOver.
StartScreen 59419 LD HL,(30800) Write *ControlMethod to *ControlMethod_Pointer.
59422 LD (30764),HL
59425 CALL ClearScreen Call ClearScreen.
59428 CALL DisplayPinkFooter Call DisplayPinkFooter.
59431 XOR A A=0.
59432 DEC A Decrease A by one.
59433 LD (30752),A Write A to *CurrentLevel.
59436 CALL DisplayStartScreen Call DisplayStartScreen.
Wait for keyboard input.
StartScreen_Input 59439 CALL KeyboardInput Call KeyboardInput.
59442 AND A Jump to StartScreen_Input until any key is pressed.
59443 JR Z,StartScreen_Input
Should we start the demo mode?
59445 BIT 4,A Call InitialiseDemoMode if a key from the top row has been pressed.
59447 CALL NZ,InitialiseDemoMode
Should we display the instructions?
59450 BIT 3,A Jump to TestStartGame if a key from the second row has not been pressed.
59452 JR Z,TestStartGame
59454 CALL DisplayInstructions Call DisplayInstructions.
59457 JR StartScreen Jump to StartScreen.
Should we start a new game?
TestStartGame 59459 BIT 2,A Jump to CheckPassword if a key from the third row has not been pressed.
59461 JP Z,CheckPassword
Else a key from the third row was pressed so handle changing the controls.
59464 CALL DisplayChangeControls Call DisplayChangeControls.
59467 JR StartScreen Jump to StartScreen.
Prev: 59392 Up: Map Next: 59469