Added wipe
This commit is contained in:
parent
39057dc2c7
commit
ee9d4e1efb
79
cpbg.s
79
cpbg.s
|
@ -294,6 +294,7 @@ initsprites
|
||||||
rts
|
rts
|
||||||
|
|
||||||
initbackground
|
initbackground
|
||||||
|
jsr show_page1
|
||||||
jsr filltext
|
jsr filltext
|
||||||
.if DEBUG_BACKGROUND
|
.if DEBUG_BACKGROUND
|
||||||
jsr pageflip
|
jsr pageflip
|
||||||
|
@ -303,10 +304,14 @@ initbackground
|
||||||
jsr copytexthgr
|
jsr copytexthgr
|
||||||
jsr copytexthgrslow
|
jsr copytexthgrslow
|
||||||
.endif
|
.endif
|
||||||
jsr pageflip
|
jsr copytexthgr ; page2 becomes the source
|
||||||
jsr copytexthgr
|
jsr wipeclear1
|
||||||
jsr pageflip
|
jsr wipe2to1
|
||||||
jsr copytexthgr
|
|
||||||
|
; jsr pageflip
|
||||||
|
; jsr copytexthgr
|
||||||
|
; jsr pageflip
|
||||||
|
; jsr copytexthgr
|
||||||
rts
|
rts
|
||||||
|
|
||||||
|
|
||||||
|
@ -337,6 +342,63 @@ ib_inner
|
||||||
rts
|
rts
|
||||||
|
|
||||||
|
|
||||||
|
wipeclear1 ldy #0
|
||||||
|
sty param_y
|
||||||
|
wipeclear1_loop lda HGRROWS_L,y
|
||||||
|
sta wipeclear1_save_smc+1
|
||||||
|
lda HGRROWS_H1,y
|
||||||
|
sta wipeclear1_save_smc+2
|
||||||
|
ldx #39
|
||||||
|
lda #$ff
|
||||||
|
wipeclear1_save_smc sta $ffff,x
|
||||||
|
dex
|
||||||
|
bpl wipeclear1_save_smc
|
||||||
|
ldx #0
|
||||||
|
wipeclear1_wait nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
dex
|
||||||
|
bne wipeclear1_wait
|
||||||
|
inc param_y
|
||||||
|
ldy param_y
|
||||||
|
cpy #192
|
||||||
|
bcc wipeclear1_loop
|
||||||
|
rts
|
||||||
|
|
||||||
|
wipe2to1 ldy #0
|
||||||
|
sty param_y
|
||||||
|
wipe2to1_loop lda HGRROWS_H2,y
|
||||||
|
sta wipe2to1_load_smc+2
|
||||||
|
lda HGRROWS_L,y
|
||||||
|
sta wipe2to1_load_smc+1
|
||||||
|
sta wipe2to1_save_smc+1
|
||||||
|
lda HGRROWS_H1,y
|
||||||
|
sta wipe2to1_save_smc+2
|
||||||
|
ldx #39
|
||||||
|
wipe2to1_load_smc lda $ffff,x
|
||||||
|
wipe2to1_save_smc sta $ffff,x
|
||||||
|
dex
|
||||||
|
bpl wipe2to1_load_smc
|
||||||
|
ldx #0
|
||||||
|
wipe2to1_wait nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
dex
|
||||||
|
bne wipe2to1_wait
|
||||||
|
inc param_y
|
||||||
|
ldy param_y
|
||||||
|
cpy #192
|
||||||
|
bcc wipe2to1_loop
|
||||||
|
rts
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
copytexthgr
|
copytexthgr
|
||||||
ldy #0 ; y is rows
|
ldy #0 ; y is rows
|
||||||
copytexthgr_outer
|
copytexthgr_outer
|
||||||
|
@ -361,10 +423,11 @@ copytexthgr_dest_smc
|
||||||
pageflip
|
pageflip
|
||||||
lda drawpage
|
lda drawpage
|
||||||
eor #$80
|
eor #$80
|
||||||
sta drawpage
|
|
||||||
bpl show_page1 ; pos = show 1, draw 2; neg = show 1, draw 1
|
bpl show_page1 ; pos = show 1, draw 2; neg = show 1, draw 1
|
||||||
|
|
||||||
show_page2 bit TXTPAGE2 ; show page 2, work on page 1
|
show_page2 lda #$80
|
||||||
|
sta drawpage
|
||||||
|
bit TXTPAGE2 ; show page 2, work on page 1
|
||||||
draw_to_page1 lda #$00
|
draw_to_page1 lda #$00
|
||||||
sta hgrselect
|
sta hgrselect
|
||||||
lda #$20
|
lda #$20
|
||||||
|
@ -386,7 +449,9 @@ draw_to_page1 lda #$00
|
||||||
sta copytexthgr_dest_smc+2
|
sta copytexthgr_dest_smc+2
|
||||||
rts
|
rts
|
||||||
|
|
||||||
show_page1 bit TXTPAGE1 ; show page 1, work on page 2
|
show_page1 lda #0
|
||||||
|
sta drawpage
|
||||||
|
bit TXTPAGE1 ; show page 1, work on page 2
|
||||||
draw_to_page2 lda #$60
|
draw_to_page2 lda #$60
|
||||||
sta hgrselect
|
sta hgrselect
|
||||||
lda #$40
|
lda #$40
|
||||||
|
|
Loading…
Reference in New Issue