mirror of
https://github.com/mi57730/a2d.git
synced 2025-01-07 15:30:24 +00:00
Run Basic Here DA: Use orig DT prefix if copied to ramcard. Issue #95
This commit is contained in:
parent
51ef098738
commit
cf2d51c50a
@ -102,9 +102,20 @@ quit: MLI_CALL QUIT, quit_params
|
||||
DEFINE_GET_PREFIX_PARAMS get_prefix_params, bs_path
|
||||
|
||||
.proc check_basic_system
|
||||
;; Was DeskTop copied to a RAM Card?
|
||||
jsr get_copied_to_ramcard_flag
|
||||
bpl get_current_prefix ; nope
|
||||
|
||||
;; Use original location, since BASIC.SYSTEM was unlikely
|
||||
;; to be copied.
|
||||
addr_call copy_desktop_orig_prefix, bs_path
|
||||
jmp got_prefix
|
||||
|
||||
get_current_prefix:
|
||||
axy_call JUMP_TABLE_MLI, GET_PREFIX, get_prefix_params
|
||||
bne no_bs
|
||||
|
||||
got_prefix:
|
||||
lda bs_path
|
||||
sta path_length
|
||||
|
||||
@ -176,3 +187,37 @@ fail: return #1
|
||||
.endproc
|
||||
|
||||
;;; ============================================================
|
||||
|
||||
.proc get_copied_to_ramcard_flag
|
||||
sta ALTZPOFF
|
||||
lda LCBANK2
|
||||
lda LCBANK2
|
||||
lda copied_to_ramcard_flag
|
||||
tax
|
||||
sta ALTZPON
|
||||
lda LCBANK1
|
||||
lda LCBANK1
|
||||
txa
|
||||
rts
|
||||
.endproc
|
||||
|
||||
.proc copy_desktop_orig_prefix
|
||||
stax @destptr
|
||||
sta ALTZPOFF
|
||||
lda LCBANK2
|
||||
lda LCBANK2
|
||||
|
||||
ldx desktop_orig_prefix
|
||||
: lda desktop_orig_prefix,x
|
||||
@destptr := *+1
|
||||
sta $1234,x
|
||||
dex
|
||||
bpl :-
|
||||
|
||||
sta ALTZPON
|
||||
lda LCBANK1
|
||||
lda LCBANK1
|
||||
rts
|
||||
.endproc
|
||||
|
||||
;;; ============================================================
|
||||
|
Loading…
Reference in New Issue
Block a user