Prev: BB40 Up: Map Next: BC1B
BB56: Main Menu
Used by the routines at Main_routine, 9E27, Game_Save, Game_Load and IO_Abandoned.
Game_MainMenu BB56 XOR A Clear demo mode.
BB57 LD (Flag_Demo),A
BB5A LD HL,$C542
BB5D LD DE,_bd0c_central_
BB60 AND A
BB61 SBC HL,DE
BB63 LD (_bb42),HL
BB66 LD (IY+$31),$03 Number of lines in the lower part of screen
BB6A LD HL,$4000 Clear screen, colour screen and border.
BB6D LD DE,$4001
BB70 LD BC,$1800
BB73 LD (HL),$00
BB75 LDIR
BB77 LD (HL),$45
BB79 LD BC,$02FF
BB7C LDIR
BB7E LD (IY+$0E),$07 Attribute for lower part of screen
BB82 XOR A
BB83 OUT ($FE),A
BB85 LD A,$42
BB87 CALL Game_ColourMarsport
BB8A LD L,$BA Blit the marsport bitmap to screen
BB8C LD DE,$4073
BB8F CALL Bitmap_SimpleBlit
BB92 CALL Menu_DisplayProgess
BB95 LD A,$02
BB97 CALL $1601
BB9A LD A,(Game_State)
BB9D AND A
BB9E JP NZ,Game_WinScreen Player has won...
Game still in play, display the menu.
BBA1 CALL Print_StringOnStack
BBA4 DEFM $10,$05,$11,$00,$16,$00,$06
BBAB DEFM "options",$16,$03,$00
BBB5 DEFM "1. enter marsport",$16,$05,$00
BBC9 DEFM "2. save game",$16,$07,$00
BBD8 DEFM "3. restore game",$16,$09,$00
BBEA DEFM "4. demo mode",$5E
Game_MainMenu_0 BBF7 LD (IY-$32),$00
Game_MainMenu_1 BBFB LD A,(IY-$32) Wait for key press.
BBFE AND A
BBFF JR Z,Game_MainMenu_1
BC01 CP $31 Return to game.
BC03 JR Z,Game_MainMenu_2
BC05 CP $32 Select save.
BC07 JR Z,Game_Save
BC09 CP $33 Select load.
BC0B JR Z,Game_Load
BC0D CP $34
BC0F JR NZ,Game_MainMenu_0
BC11 LD A,$01 Select demo mode.
BC13 LD (Flag_Demo),A
Game_MainMenu_2 BC16 LD (IY+$31),$0E Play game.
BC1A RET
Prev: BB40 Up: Map Next: BC1B