DHGR transitions including fizzle, clear-to-white variations

This commit is contained in:
4am 2019-06-24 14:54:49 -04:00
parent f76262c07a
commit 4b3e8ae50a
33 changed files with 404 additions and 42 deletions

View File

@ -25,14 +25,23 @@ asm: md
$(ACME) -r build/4cade.lst -DRELBASE=`cat build/relbase.log | grep "RELBASE =" | cut -d"=" -f2 | cut -d"(" -f2 | cut -d")" -f1` src/4cade.a
$(ACME) src/fx/fx.cover.fade.a
$(ACME) src/fx/fx.dhgr.fizzle.a
$(ACME) src/fx/fx.dhgr.fizzle.white.a
$(ACME) src/fx/fx.dhgr.ripple.a
$(ACME) src/fx/fx.dhgr.ripple.white.a
$(ACME) src/fx/fx.dhgr.iris.a
$(ACME) src/fx/fx.dhgr.iris.white.a
$(ACME) src/fx/fx.dhgr.radial.a
$(ACME) src/fx/fx.dhgr.radial.white.a
$(ACME) src/fx/fx.dhgr.radial2.a
$(ACME) src/fx/fx.dhgr.radial2.white.a
$(ACME) src/fx/fx.dhgr.radial3.a
$(ACME) src/fx/fx.dhgr.radial3.white.a
$(ACME) src/fx/fx.dhgr.radial4.a
$(ACME) src/fx/fx.dhgr.radial4.white.a
$(ACME) src/fx/fx.dhgr.radial5.a
$(ACME) src/fx/fx.dhgr.radial5.white.a
$(ACME) src/fx/fx.dhgr.star.a
$(ACME) src/fx/fx.dhgr.star.white.a
$(ACME) src/fx/fx.hgr.diagonal.a
$(ACME) src/fx/fx.hgr.interlock.ud.a
$(ACME) src/fx/fx.hgr.interlock.lr.a
@ -67,6 +76,7 @@ asm: md
$(ACME) src/fx/fx.hgr.ripple.a
$(ACME) src/fx/fx.hgr.ripple2.a
$(ACME) src/fx/fx.hgr.star.a
$(ACME) src/fx/fx.hgr.star.white.a
$(ACME) src/fx/fx.shr.fizzle.a
dsk: md asm

View File

@ -1 +1 @@
# # transition effects for DHGR slideshows # # Each Mega-Attract Module that is a DHGR slideshow (see attract.conf) # will use a single transition effect for the length of the module. # Transition effects are loaded in the order listed in this file. Each line # of this file is a filename (not including comments, like this one). The # name of the next transition effect is stored in the global prefs, so this # file should not contain duplicates. # # Transition effects are binary files loaded at $6000 and called with DHGR # page 1 showing and the next DHGR graphic already loaded at $4000/main and # $4000/aux. A transition effect has full use of main and auxiliary memory, # including zero pages and text pages if needed. LC RAM banks 1 and 2 are # reserved for the launcher. # # Important: LC RAM bank 1 will be read/write on entry and must be read/write # on exit. If you need ROM routines, you are responsible for switching to ROM # then switching back to RAM bank 1 (read/write) before returning. # DHGR.FIZZLE DHGR.RIPPLE DHGR.RADIAL DHGR.STAR DHGR.RADIAL3 DHGR.IRIS DHGR.RADIAL2 DHGR.RADIAL4 DHGR.RADIAL5 [eof]
# # transition effects for DHGR slideshows # # Each Mega-Attract Module that is a DHGR slideshow (see attract.conf) # will use a single transition effect for the length of the module. # Transition effects are loaded in the order listed in this file. Each line # of this file is a filename (not including comments, like this one). The # name of the next transition effect is stored in the global prefs, so this # file should not contain duplicates. # # Transition effects are binary files loaded at $6000 and called with DHGR # page 1 showing and the next DHGR graphic already loaded at $4000/main and # $4000/aux. A transition effect has full use of main and auxiliary memory, # including zero pages and text pages if needed. LC RAM banks 1 and 2 are # reserved for the launcher. # # Important: LC RAM bank 1 will be read/write on entry and must be read/write # on exit. If you need ROM routines, you are responsible for switching to ROM # then switching back to RAM bank 1 (read/write) before returning. # DHGR.FIZZLE DHGR.FIZZLE DHGR.RADIAL DHGR.STAR DHGR.RADIAL3 DHGR.IRIS DHGR.RADIAL2 DHGR.RADIAL4 FIZZLE DHGR.RIPPLE FIZZLE DHGR.RADIAL FIZZLE DHGR.STAR FIZZLE DHGR.RADIAL3 FIZZLE DHGR.IRIS FIZZLE DHGR.RADIAL2 FIZZLE DHGR.RADIAL4 FIZZLE DHGR.RADIAL5DHGR.RADIAL4WH DHGR.RADIAL5WH [eof]

View File

@ -1 +1 @@
# # transition effects for HGR slideshows # # Each Mega-Attract Module that is an HGR slideshow (see attract.conf) # will use a single transition effect for the length of the module. # Transition effects are loaded in the order listed in this file. Each line # of this file is a filename (not including comments, like this one). The # name of the next transition effect is stored in the global prefs, so this # file should not contain duplicates. # # Transition effects are binary files loaded at $6000 and called with # hi-res page 1 showing and the next HGR graphic already loaded at $4000. # A transition effect has full use of main memory, including zero page and # text page if needed. LC RAM banks 1 and 2 are reserved for the launcher. # # Important: LC RAM bank 1 will be read/write on entry and must be read/write # on exit. If you need ROM routines, you are responsible for switching to ROM # then switching back to RAM bank 1 (read/write) before returning. # RIPPLE DIAGONAL STAGGERWHITE.UD STAR RADIAL FIZZLE CRYSTAL SUNRISE SUNSET CORNER.CIRCLE RIPPLE2 RADIAL2 RADIAL3 RADIAL4 RADIAL5 FOURSPIRAL IRIS SPLIT.UD.INTRO CHECKERBOARD HALF.FIZZLE BAR.DISSOLVE STAGGERWHITE.LR DIAMOND ONESQUARE TWOPASS.LR HALF.MOSAIC STAGGER.LR FOURSQUARE STAGGER.UD INTERLOCK.LR BLOCK.MOSAIC INTERLOCK.UD BLOCK.FIZZLE SPIRAL [eof]
# # transition effects for HGR slideshows # # Each Mega-Attract Module that is an HGR slideshow (see attract.conf) # will use a single transition effect for the length of the module. # Transition effects are loaded in the order listed in this file. Each line # of this file is a filename (not including comments, like this one). The # name of the next transition effect is stored in the global prefs, so this # file should not contain duplicates. # # Transition effects are binary files loaded at $6000 and called with # hi-res page 1 showing and the next HGR graphic already loaded at $4000. # A transition effect has full use of main memory, including zero page and # text page if needed. LC RAM banks 1 and 2 are reserved for the launcher. # # Important: LC RAM bank 1 will be read/write on entry and must be read/write # on exit. If you need ROM routines, you are responsible for switching to ROM # then switching back to RAM bank 1 (read/write) before returning. # STARWHITE RIPPLE DIAGONAL STAGGERWHITE.UD STAR RADIAL FIZZLE CRYSTAL SUNRISE SUNSET CORNER.CIRCLE RIPPLE2 RADIAL2 RADIAL3 RADIAL4 RADIAL5 FOURSPIRAL IRIS SPLIT.UD.INTRO CHECKERBOARD HALF.FIZZLE BAR.DISSOLVE STAGGERWHITE.LR DIAMOND ONESQUARE TWOPASS.LR HALF.MOSAIC STAGGER.LR FOURSQUARE STAGGER.UD INTERLOCK.LR BLOCK.MOSAIC INTERLOCK.UD BLOCK.FIZZLE SPIRAL [eof]

View File

@ -31,16 +31,25 @@ RADIAL5=Type(06),AuxType(6000),Access(C3)
SPLIT.UD.INTRO=Type(06),AuxType(6000),Access(C3)
IRIS=Type(06),AuxType(6000),Access(C3)
STAR=Type(06),AuxType(6000),Access(C3)
STARWHITE=Type(06),AuxType(6000),Access(C3)
RIPPLE=Type(06),AuxType(6000),Access(C3)
RIPPLE2=Type(06),AuxType(6000),Access(C3)
DHGR.FIZZLE=Type(06),AuxType(6000),Access(C3)
DHGR.FIZZLEWH=Type(06),AuxType(6000),Access(C3)
DHGR.IRIS=Type(06),AuxType(6000),Access(C3)
DHGR.IRISWH=Type(06),AuxType(6000),Access(C3)
DHGR.RIPPLE=Type(06),AuxType(6000),Access(C3)
DHGR.RIPPLEWH=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL=Type(06),AuxType(6000),Access(C3)
DHGR.RADIALWH=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL2=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL2WH=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL3=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL3WH=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL4=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL4WH=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL5=Type(06),AuxType(6000),Access(C3)
DHGR.RADIAL5WH=Type(06),AuxType(6000),Access(C3)
DHGR.STAR=Type(06),AuxType(6000),Access(C3)
DHGR.CORNER=Type(06),AuxType(6000),Access(C3)
DHGR.STARWH=Type(06),AuxType(6000),Access(C3)
SHR.FIZZLE=Type(06),AuxType(A000),Access(C3)

View File

@ -0,0 +1,150 @@
;license:MIT
;(c) 2017-2018 by qkumba
;
!cpu 6502
!to "build/FX/DHGR.FIZZLEWH",plain
*=$6000
jsr CopySelfToAuxmem
jsr FizzleToWhite
jmp FizzleCopy
FizzleToWhite
;init RNG
ldx #1
stx @rnd1+1
dex
stx @rnd2+1
;iterate
@loop
ldy @rnd1+1
ldx @rnd2+1
lsr @rnd2+1
ror @rnd1+1
bcc +
;feedback polynomial forms #$2015 for period of 16383
lda @rnd1+1
eor #$15
sta @rnd1+1
lda @rnd2+1
eor #$20
sta @rnd2+1
;little hack to avoid missing offset zero
;screen hole at $xxFF is missed instead
+ tya
eor #$ff
sta $26
sta $3c
txa
and #$1f
;target page 1
ora #$20
sta $27
eor #$60
sta $3d
;set pixel to white
ldy #0
cpx #$20
bcc +
sta $c003
sta $c005
+ lda #$FF
sta ($26),y
sta $c002
sta $c004
;check for keypress
lda $c000
bmi @exit
;and exit condition
@rnd2 lda #0
bne @loop
@rnd1 lda #0
cmp #1
bne @loop
@exit rts
FizzleCopy
;init RNG
ldx #1
stx @rnd1+1
dex
stx @rnd2+1
;iterate
@loop
ldy @rnd1+1
ldx @rnd2+1
lsr @rnd2+1
ror @rnd1+1
bcc +
;feedback polynomial forms #$2015 for period of 16383
lda @rnd1+1
eor #$15
sta @rnd1+1
lda @rnd2+1
eor #$20
sta @rnd2+1
;little hack to avoid missing offset zero
;screen hole at $xxFF is missed instead
+ tya
eor #$ff
sta $26
sta $3c
txa
and #$1f
;target page 1
ora #$20
sta $27
eor #$60
sta $3d
;copy pixel from other page to this page
ldy #0
cpx #$20
bcc +
sta $c003
sta $c005
+ lda ($3c),y
sta ($26),y
sta $c002
sta $c004
;check for keypress
lda $c000
bmi @exit
;and exit condition
@rnd2 lda #0
bne @loop
@rnd1 lda #0
cmp #1
bne @loop
@exit rts
!source "src/fx/fx.dhgr.common.a"

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.iris.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.IRISWH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.iris.data.a"
!byte $80

View File

@ -12,17 +12,19 @@ coord = $FE
Start
jsr CopySelfToAuxmem
!macro FX_PRECOMPUTED_DHGR .wait {
lda #<@coords
!macro FX_PRECOMPUTED_DHGR .copy, .coords, .wait {
lda #<.coords
sta coord
lda #>@coords
lda #>.coords
sta coord+1
ldy #0
@loop
lda (coord),y
bpl +
lda #.wait
beq @nowait
jsr WaitForKeyWithTimeout
@nowait bit $C000
bmi @exit
bpl @next
+ tax
@ -38,7 +40,7 @@ Start
+
tay
txa
jsr HGRHalfBlockCopy
jsr .copy
@next
inc coord
bne +
@ -52,7 +54,4 @@ Start
bne @loop
@exit sta $c002
sta $c004
rts
@coords
}

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.radial.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.RADIALWH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.radial.data.a"
!byte $80

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.radial2.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.RADIAL2WH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.radial2.data.a"
!byte $80

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.radial3.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.RADIAL3WH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.radial3.data.a"
!byte $80

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.radial4.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.RADIAL4WH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.radial4.data.a"
!byte $80

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.radial5.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.RADIAL5WH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.radial5.data.a"
!byte $80

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.ripple.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.RIPPLEWH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.ripple.data.a"
!byte $80

View File

@ -7,8 +7,10 @@
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR $1
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@coords
rts
Coordinates
!source "src/fx/fx.dhgr.star.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/DHGR.STARWH",plain
*=$6000
!source "src/fx/fx.dhgr.precomputed.a"
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $0
rts
Coordinates
!source "src/fx/fx.dhgr.star.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $28
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $28
rts
Coordinates
!source "src/fx/fx.hgr.corner.circle.data.a"
!byte $80

View File

@ -10,10 +10,10 @@ coord = $FE
Start
!macro FX_PRECOMPUTED .wait {
lda #<@coords
!macro FX_PRECOMPUTED .copy, .coords, .wait {
lda #<.coords
sta coord
lda #>@coords
lda #>.coords
sta coord+1
ldy #0
@loop
@ -28,7 +28,7 @@ Start
lda (coord),y
tay
txa
jsr HGRHalfBlockCopy
jsr .copy
@next
inc coord
bne +
@ -40,7 +40,5 @@ Start
lda ($FE),y
cmp #$80
bne @loop
@exit rts
@coords
@exit
}

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $06
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $06
rts
Coordinates
!source "src/fx/fx.hgr.radial.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $06
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $06
rts
Coordinates
!source "src/fx/fx.hgr.radial2.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $06
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $06
rts
Coordinates
!source "src/fx/fx.hgr.radial3.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $06
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $06
rts
Coordinates
!source "src/fx/fx.hgr.radial4.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $06
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $06
rts
Coordinates
!source "src/fx/fx.hgr.radial5.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $30
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $30
rts
Coordinates
!source "src/fx/fx.hgr.ripple.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $08
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $08
rts
Coordinates
!source "src/fx/fx.hgr.ripple2.data.a"
!byte $80

View File

@ -7,7 +7,10 @@
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED $10
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $10
rts
Coordinates
!source "src/fx/fx.hgr.star.data.a"
!byte $80

View File

@ -0,0 +1,17 @@
;license:MIT
;(c) 2018 by 4am
;
!cpu 6502
!to "build/FX/STARWHITE",plain
*=$6000
!source "src/fx/fx.hgr.precomputed.a"
+FX_PRECOMPUTED HGRHalfBlockToWhite, Coordinates, $08
+FX_PRECOMPUTED HGRHalfBlockCopy, Coordinates, $08
rts
Coordinates
!source "src/fx/fx.hgr.star.data.a"
!byte $80