set $2B/$2C pointers when inserting a line of BASIC text

This commit is contained in:
Paul Gardner-Stephen committed 2019-04-28 01:08:56 +09:30
1 parent 64dbdcdefb
commit 08b1327044
1 file changed
+11
+11
View File
@@ -26,10 +26,21 @@ basic_insert_line:
;; Add on the four bytes space we need
clc
adc #5
pha
tax
;; Make the space
jsr basic_shift_mem_up_and_relink
;; Now increase top of BASIC mem
pla
clc
adc basic_end_of_text_ptr+0
sta basic_end_of_text_ptr+0
lda basic_end_of_text_ptr+1
adc #0
sta basic_end_of_text_ptr+1
;; Get pointer back
pla
sta basic_current_line_ptr+1