Prev: 62788 Up: Map Next: 62916
62826: Initialise Display
Used by the routine at JumpTable_InitialiseDisplay.
Opens the upper screen, builds the line-address table and fills the IM 2 vector page at 64768 with 254.
Initialise_Display 62826 LD A,0 Write 0 to *DF_SZ.
62828 LD (23659),A
62831 LD A,2 Open channel 2 via CHAN_OPEN.
62833 CALL 5633
Build 25 display-file addresses from CL_SET.
62836 LD HL,65284 HL=65284.
62839 LD BC,289 BC=289.
62842 PUSH HL Stash the table pointer on the stack.
Initialise_Display_Continue 62843 PUSH BC Stash the position on the stack.
62844 CALL 3545 Call CL_SET.
62847 POP BC Fetch *DF_CC and add 33.
62848 LD DE,(23684)
62852 LD HL,33
62855 ADD HL,DE
62856 EX DE,HL
62857 POP HL Store that address in the table.
62858 LD (HL),E
62859 INC HL
62860 LD (HL),D
62861 INC HL
62862 PUSH HL
62863 INC B Increase the row and jump to Initialise_Display_Continue until 25 rows are stored.
62864 LD A,B
62865 CP 25
62867 JR NZ,Initialise_Display_Continue
62869 POP HL Drop the leftover table pointer.
62870 LD BC,24 Write the default clip window to *ClipWindow.
62873 LD (25625),BC
62877 LD BC,289
62880 LD (25627),BC
62884 LD DE,23735 Clear seven bytes at UDG.
62887 LD HL,23734
62890 LD BC,7
62893 LD (HL),0
62895 LDIR
62897 LD HL,25662 Write 0 to *Sprite_ShiftBuffer.
62900 LD (HL),0
62902 LD HL,64768 Fill 256 bytes at 64768 with 254.
62905 LD DE,64769
62908 LD BC,256
62911 LD (HL),254
62913 LDIR
62915 RET Return.
View the equivalent code in Booty.
Prev: 62788 Up: Map Next: 62916