mirror of
https://github.com/deater/dos33fsprogs.git
synced 2024-06-18 19:29:30 +00:00
d2_hgr: inline to save bytes
This commit is contained in:
parent
a9418f88fa
commit
2d44b76a59
|
@ -101,7 +101,7 @@ forever:
|
||||||
;=====================
|
;=====================
|
||||||
; orange/green effect
|
; orange/green effect
|
||||||
|
|
||||||
jsr moving
|
.include "moving.s"
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
; clear screen
|
; clear screen
|
||||||
|
@ -113,16 +113,26 @@ forever:
|
||||||
;=====================
|
;=====================
|
||||||
; wires effect
|
; wires effect
|
||||||
|
|
||||||
jsr wires
|
.include "wires.s"
|
||||||
|
|
||||||
|
; jsr wires
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
; oval effect
|
; oval effect
|
||||||
|
|
||||||
jsr oval
|
; jsr oval
|
||||||
|
|
||||||
|
.include "oval.s"
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
; repeat
|
; repeat
|
||||||
|
|
||||||
|
lda #$7f
|
||||||
|
sta color_smc+1
|
||||||
|
lda #159
|
||||||
|
sta moving_size_smc+1
|
||||||
|
sta oval_size_smc+1
|
||||||
|
|
||||||
bit TEXTGR
|
bit TEXTGR
|
||||||
|
|
||||||
jmp forever
|
jmp forever
|
||||||
|
@ -187,11 +197,28 @@ message2:
|
||||||
hiasc "MUSIC: MA2E "
|
hiasc "MUSIC: MA2E "
|
||||||
|
|
||||||
.include "dsr_shape.s"
|
.include "dsr_shape.s"
|
||||||
.include "moving.s"
|
;.include "oval.s"
|
||||||
.include "wires.s"
|
|
||||||
.include "oval.s"
|
|
||||||
.include "clear_bottom.s"
|
.include "clear_bottom.s"
|
||||||
|
|
||||||
|
colorlookup2:
|
||||||
|
.byte $11,$55,$5d,$7f,$5d,$55,$11,$00
|
||||||
|
|
||||||
|
even_lookup:
|
||||||
|
.byte $D7,$DD,$F5, $D5,$D5,$D5,$D5
|
||||||
|
odd_lookup:
|
||||||
|
.byte $AA,$AA,$AA, $AB,$AE,$BA,$EA
|
||||||
|
|
||||||
|
colorlookup:
|
||||||
|
.byte $22,$aa,$ba,$ff,$ba,$aa,$22 ; use 00 from sinetable
|
||||||
|
|
||||||
|
sinetable_base:
|
||||||
|
; this is actually (32*sin(x))
|
||||||
|
.byte $00,$03,$06,$09,$0C,$0F,$11,$14
|
||||||
|
.byte $16,$18,$1A,$1C,$1D,$1E,$1F,$1F
|
||||||
|
.byte $20
|
||||||
|
|
||||||
|
sinetable=$8000
|
||||||
|
|
||||||
; music
|
; music
|
||||||
.include "mA2E_2.s"
|
.include "mA2E_2.s"
|
||||||
.include "interrupt_handler.s"
|
.include "interrupt_handler.s"
|
||||||
|
|
|
@ -15,6 +15,7 @@ moving:
|
||||||
draw_moving:
|
draw_moving:
|
||||||
inc FRAME
|
inc FRAME
|
||||||
|
|
||||||
|
moving_size_smc:
|
||||||
lda #191 ; YY
|
lda #191 ; YY
|
||||||
|
|
||||||
create_yloop:
|
create_yloop:
|
||||||
|
@ -102,21 +103,21 @@ ror_nop_smc:
|
||||||
cmp #$1b ; NOTE: NEEDS TO BE ODD
|
cmp #$1b ; NOTE: NEEDS TO BE ODD
|
||||||
bne draw_moving ; bra
|
bne draw_moving ; bra
|
||||||
|
|
||||||
rts
|
; rts
|
||||||
|
|
||||||
colorlookup:
|
;colorlookup:
|
||||||
.byte $22,$aa,$ba,$ff,$ba,$aa,$22 ; use 00 from sinetable
|
;.byte $22,$aa,$ba,$ff,$ba,$aa,$22 ; use 00 from sinetable
|
||||||
;.byte $00
|
;;.byte $00
|
||||||
|
|
||||||
;.byte $11,$55,$5d,$7f,$5d,$55,$11 ; use 00 from sinetable
|
;;.byte $11,$55,$5d,$7f,$5d,$55,$11 ; use 00 from sinetable
|
||||||
;.byte $00
|
;;.byte $00
|
||||||
|
|
||||||
sinetable_base:
|
;sinetable_base:
|
||||||
; this is actually (32*sin(x))
|
;; this is actually (32*sin(x))
|
||||||
.byte $00,$03,$06,$09,$0C,$0F,$11,$14
|
;.byte $00,$03,$06,$09,$0C,$0F,$11,$14
|
||||||
.byte $16,$18,$1A,$1C,$1D,$1E,$1F,$1F
|
;.byte $16,$18,$1A,$1C,$1D,$1E,$1F,$1F
|
||||||
.byte $20
|
;.byte $20
|
||||||
|
|
||||||
sinetable=$8000
|
;sinetable=$8000
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -43,6 +43,7 @@ oval:
|
||||||
draw_oval:
|
draw_oval:
|
||||||
inc FRAME
|
inc FRAME
|
||||||
|
|
||||||
|
oval_size_smc:
|
||||||
lda #191 ; YY
|
lda #191 ; YY
|
||||||
|
|
||||||
oval_yloop:
|
oval_yloop:
|
||||||
|
@ -89,7 +90,9 @@ oval_row_sum_smc:
|
||||||
|
|
||||||
oval_ror_nop_smc:
|
oval_ror_nop_smc:
|
||||||
ror ; $6A/$EA ; 2
|
ror ; $6A/$EA ; 2
|
||||||
; and #$7f ; make all purple
|
|
||||||
|
color_smc:
|
||||||
|
and #$ff ; make all purple
|
||||||
sta (GBASL),Y ; 6
|
sta (GBASL),Y ; 6
|
||||||
|
|
||||||
lda oval_ror_nop_smc ; toggle ror/nop ; 4
|
lda oval_ror_nop_smc ; toggle ror/nop ; 4
|
||||||
|
@ -113,10 +116,7 @@ oval_ror_nop_smc:
|
||||||
|
|
||||||
bne draw_oval ; bra
|
bne draw_oval ; bra
|
||||||
|
|
||||||
rts
|
; rts
|
||||||
|
|
||||||
colorlookup2:
|
|
||||||
.byte $11,$55,$5d,$7f,$5d,$55,$11,$00
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
;colorlookup2:
|
||||||
|
;.byte $11,$55,$5d,$7f,$5d,$55,$11,$00
|
||||||
|
|
|
@ -82,13 +82,9 @@ noflo:
|
||||||
|
|
||||||
bne outer_loop
|
bne outer_loop
|
||||||
|
|
||||||
rts
|
; rts
|
||||||
|
|
||||||
even_lookup:
|
|
||||||
.byte $D7,$DD,$F5, $D5,$D5,$D5,$D5
|
|
||||||
odd_lookup:
|
|
||||||
.byte $AA,$AA,$AA, $AB,$AE,$BA,$EA
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
;even_lookup:
|
||||||
|
;.byte $D7,$DD,$F5, $D5,$D5,$D5,$D5
|
||||||
|
;odd_lookup:
|
||||||
|
;.byte $AA,$AA,$AA, $AB,$AE,$BA,$EA
|
||||||
|
|
Loading…
Reference in New Issue
Block a user