Prev: FBA5 Up: Map Next: FBDC
FBA9: Game Start
Used by the routine at Jump_GameStart.
Copy the default state into working memory, open the starting exits, and enter the game loop.
GameStart FBA9 LD HL,$FBDC Copy 0186 bytes from DefaultGameState to the item-location table.
FBAC LD DE,$AD76
FBAF LD BC,$0186
FBB2 LDIR
Remove a bunch of room exits (as actions in the game will open them back up).
FBB4 LD IX,$E972 Point IX at the configurable exits.
FBB8 LD A,($AEFA) Count the configurable exits to close.
FBBB LD B,A
FBBC XOR A Set A to 00 which "removes" the exit.
GameStart_Loop FBBD LD L,(IX+$00) Close this configurable exit.
FBC0 LD H,(IX+$01)
FBC3 LD (HL),A
FBC4 INC IX
FBC6 INC IX
FBC8 DJNZ GameStart_Loop
FBCA LD A,$24 Open the east exit from the Hall of Infinity into the Lair of the Hydra.
FBCC LD ($E8BA),A
FBCF LD A,$3F Open the south exit from the Hall of the Phoenix into the Hall of Black Magic.
FBD1 LD ($E931),A
FBD4 LD A,$03 Begin in the Field.
FBD6 CALL Handler_ChangeRoom
FBD9 JP GameLoop Continue at GameLoop.
View the equivalent code in;
Prev: FBA5 Up: Map Next: FBDC