second: more work on plasma

This commit is contained in:
Vince Weaver 2023-11-01 22:35:08 -04:00
parent 62d13ccc88
commit 233ba08fbb
5 changed files with 66 additions and 12 deletions

View File

@ -108,7 +108,7 @@ display_row_sin_smc:
lda hposn_high_div8,X ; 4
clc ; 2
adc PAGE ; 3
adc DRAW_PAGE ; 3
sta GBASH ; 3
; 30
lda #1 ; 2
@ -142,7 +142,7 @@ display_lookup_smc:
; ============================================================================
lda PAGE ; 3
lda DRAW_PAGE ; 3
beq was_page1 ; 2/3
was_page2:
bit PAGE2 ; 4
@ -152,8 +152,9 @@ was_page1:
bit PAGE1 ; 4
lda #$20 ; 2
done_pageflip:
sta PAGE ; 3
sta DRAW_PAGE ; 3
plasma_end_smc:
lda #52
jsr wait_for_pattern

View File

@ -74,19 +74,63 @@ div8_loop:
;=========================================
lda #0
sta PAGE
sta DRAW_PAGE
;=============================
; do blue/orange
lda #49
sta plasma_end_smc+1
jsr init_plasma_colors
jsr do_plasma
; drop
;=============================
; do purple/green
ldx #63
change_purple:
lda hires_colors_even_lookup_l0,X
and #$7f
sta hires_colors_even_lookup_l0,X
dex
bpl change_purple
jsr init_plasma_colors
; ============================================================================
; 26+( 24*(11+(40*(39+(38*2))) = 110,690 +2174 = 112,864 = 9fps
; 26+( 24*(11+(40*(39+(38*4))) = 183,650 +2174 = 185,824 = 5.5fps
; 26+( 24*(11+(40*(39+(38*8))) = 329,570 +2174 = = 3fps
lda #50
sta plasma_end_smc+1
jsr do_plasma
; drop
;=============================
; do black/white?
ldx #63
change_mono:
lda hires_colors_even_lookup_l0,X
ora #$aa
sta hires_colors_even_lookup_l0,X
dex
bpl change_mono
jsr init_plasma_colors
lda #52
sta plasma_end_smc+1
jsr do_plasma
rts
.include "init_plasma.s"

View File

@ -4,6 +4,7 @@
.include "../hardware.inc"
.include "../zp.inc"
.include "../qload.inc"
.include "../music.inc"
; =============================================================================
@ -18,6 +19,14 @@ plasma_main:
jsr pt3_set_pattern
lda #$00
sta DRAW_PAGE
sta clear_all_color+1
lda #$04
sta DRAW_PAGE
jsr clear_all
bit PAGE2 ; set page 2
; bit SET_TEXT ; set text

View File

@ -397,6 +397,8 @@ load_program_loop2:
bit KEYRESET ; clear keyboard
; clear text screen
lda #$A0
sta clear_all_color+1
jsr clear_all

View File

@ -158,8 +158,6 @@ GRLINEH = $FB
; PLASMA
PAGE = $F2
; CUBE
SAVEX = $F3
SAVEY = $F4