Skip to content

Commit

Permalink
final additions & tweaks (maybe)
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLX5 committed Mar 7, 2021
1 parent 71679b7 commit 3e4770c
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 4 deletions.
11 changes: 8 additions & 3 deletions pixi/asm/ExtraDefines/dynamic_spritesets_defines.asm
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
!dss_exgfx = $0D00

;# How many tiles from the queue will be uploaded per frame
!dss_queue_tiles = 6
!dss_queue_tiles = 5

;# How many frames are needed to mark a GFX as unused
!dss_time_to_unmark_gfx = 16

;# Main RAM defines
;# Requires at least 1541 (0x605) bytes of consecutive free RAM
;# Requires at least 1751 (0x6D7) bytes of consecutive free RAM
;# or you could edit the defines below to make some of them not consecutive
!dss_ram = $40C000

Expand Down Expand Up @@ -174,7 +174,12 @@

;# Copy of the bounce sprite table ($1699)
;# 4 bytes
!dss_bounce_sprite_copy = !dss_cluster_sprite_copy+4
!dss_bounce_sprite_copy = !dss_cluster_sprite_copy+20

;# Page of ExGFX that will be used for decompressing graphics.
;# The default value is !dss_exgfx
;# 2 bytes
!dss_exgfx_page = !dss_bounce_sprite_copy+4

;####################################################################
;# Spriteset defines
Expand Down
2 changes: 1 addition & 1 deletion pixi/asm/dss/shared_routines.asm
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ find_and_queue_gfx:
rep #$20
txa
and #$00FF
ora #!dss_exgfx ; prepare for decompression on snes side
ora.l !dss_exgfx_page ; prepare for decompression on snes side
sta $313E ; $313E = exgfx num
lda.l !dss_ram_buffer_index
and #$0007
Expand Down
14 changes: 14 additions & 0 deletions uberasm/library/dynamic_spriteset.asm
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,14 @@
;# 20 bytes
!dss_cluster_sprite_copy = !dss_extended_sprite_copy+10

;# Copy of the bounce sprite table ($1699)
;# 4 bytes
!dss_bounce_sprite_copy = !dss_cluster_sprite_copy+20

;# Page of ExGFX that will be used for decompressing graphics.
;# The default value is !dss_exgfx
;# 2 bytes
!dss_exgfx_page = !dss_bounce_sprite_copy+4

;####################################################################
;# Macros
Expand Down Expand Up @@ -197,6 +205,9 @@ init:
plb
rep #$30


lda.w #!dss_exgfx
sta.w !dss_exgfx_page
stz.w !dss_gfx_queue_index_nmi
stz.w !dss_gfx_queue_index_game
stz.w !dss_ram_buffer_index
Expand Down Expand Up @@ -250,6 +261,9 @@ init:
dex #2
bpl -

stz.w !dss_bounce_sprite_copy,x
stz.w !dss_bounce_sprite_copy+2,x

plb
sep #$30

Expand Down

0 comments on commit 3e4770c

Please sign in to comment.