mirror of
https://github.com/blondie7575/GSCats.git
synced 2024-09-25 06:55:08 +00:00
Compare commits
No commits in common. "4813eb4af564034855e7133a834151bae7666630" and "703edd47dda6ee83085c2d7bde87de848f2142a1" have entirely different histories.
4813eb4af5
...
703edd47dd
51
fan.s
51
fan.s
@ -164,57 +164,6 @@ renderFanDone:
|
||||
rts
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; unrenderFan
|
||||
;
|
||||
; Y = Offset to projectile structure
|
||||
;
|
||||
unrenderFan:
|
||||
SAVE_AXY
|
||||
|
||||
; Unrender the stand under the fan
|
||||
lda projectileData+JD_SCRATCH,y
|
||||
sta PARAML0
|
||||
clc
|
||||
lda #gameObjectPool
|
||||
adc PARAML0
|
||||
sta PARAML0
|
||||
jsr unrenderGameObject
|
||||
|
||||
RESTORE_AXY
|
||||
rts
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; protectFan
|
||||
;
|
||||
; Y = Offset to projectile structure
|
||||
;
|
||||
protectFan:
|
||||
SAVE_AXY
|
||||
|
||||
; Protect the stand under the fan
|
||||
lda projectileData+JD_SCRATCH,y
|
||||
sta PARAML0
|
||||
clc
|
||||
lda #gameObjectPool
|
||||
adc PARAML0
|
||||
sta PARAML0
|
||||
jsr vramPtr
|
||||
cpx #$ffff
|
||||
beq protectFanDone
|
||||
|
||||
lda PARAML0
|
||||
clc
|
||||
adc #GO_BACKGROUND
|
||||
sta PARAML0
|
||||
jsr protectGameObject
|
||||
|
||||
protectFanDone:
|
||||
RESTORE_AXY
|
||||
rts
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; deleteFan
|
||||
;
|
||||
|
@ -192,9 +192,7 @@ gameplayLoopProjectiles:
|
||||
|
||||
jsr unrenderProjectiles
|
||||
jsr updateProjectilesPhysics
|
||||
jsr unrenderPlayers ; This extra unrender...
|
||||
jsr protectProjectiles
|
||||
jsr renderPlayers ; ... rerender cycle makes fan stands overlapping cats render properly. Messy, but the engine doesn't handle overlapping sprites well
|
||||
jsr renderProjectiles
|
||||
|
||||
gameplayLoopProjectilesSkip:
|
||||
|
43
projectile.s
43
projectile.s
@ -102,13 +102,11 @@ projectileTypes:
|
||||
.addr 0 ; Deploy
|
||||
.addr 0 ; Update
|
||||
.addr 0 ; Render
|
||||
.addr 0 ; Unrender
|
||||
.addr 0 ; Protect
|
||||
.addr 0 ; Cleanup
|
||||
.word 1 ; Directional
|
||||
.word 1 ; Mining
|
||||
|
||||
.repeat 6
|
||||
.repeat 10
|
||||
.byte 0 ; Padding to 32-byte boundary
|
||||
.endrepeat
|
||||
|
||||
@ -121,13 +119,11 @@ projectileTypes:
|
||||
.addr 0 ; Deploy
|
||||
.addr 0 ; Update
|
||||
.addr 0 ; Render
|
||||
.addr 0 ; Unrender
|
||||
.addr 0 ; Protect
|
||||
.addr 0 ; Cleanup
|
||||
.word 0 ; Directional
|
||||
.word 0 ; Mining
|
||||
|
||||
.repeat 6
|
||||
.repeat 10
|
||||
.byte 0 ; Padding to 32-byte boundary
|
||||
.endrepeat
|
||||
|
||||
@ -140,13 +136,11 @@ projectileTypes:
|
||||
.addr deployFan ; Deploy
|
||||
.addr updateFan ; Update
|
||||
.addr renderFan ; Render
|
||||
.addr unrenderFan ; Unrender
|
||||
.addr protectFan ; Protect
|
||||
.addr deleteFan ; Cleanup
|
||||
.word 1 ; Directional
|
||||
.word 0 ; Mining
|
||||
|
||||
.repeat 6
|
||||
.repeat 10
|
||||
|
||||
.byte 0 ; Padding to 32-byte boundary
|
||||
.endrepeat
|
||||
@ -160,11 +154,9 @@ PT_FRAME2 = 8
|
||||
PT_DEPLOY = 10
|
||||
PT_UPDATE = 12
|
||||
PT_RENDER = 14
|
||||
PT_UNRENDER = 16
|
||||
PT_PROTECT = 18
|
||||
PT_CLEANUP = 20
|
||||
PT_DIRECTIONAL = 22
|
||||
PT_MINING = 24
|
||||
PT_CLEANUP = 16
|
||||
PT_DIRECTIONAL = 18
|
||||
PT_MINING = 20
|
||||
|
||||
.macro PROJECTILEPTR_Y
|
||||
tya ; Pointer to projectile structure from index
|
||||
@ -716,16 +708,6 @@ protectProjectilesGotOne:
|
||||
adc PARAML0
|
||||
sta PARAML0
|
||||
jsr protectGameObject
|
||||
|
||||
; Check for special deployment code
|
||||
lda projectileData+JD_TYPE,y
|
||||
tax
|
||||
PROJECTILETYPEPTR_X
|
||||
lda projectileTypes+PT_PROTECT,x
|
||||
beq protectProjectilesNotSpecial
|
||||
JSRA
|
||||
|
||||
protectProjectilesNotSpecial:
|
||||
plx
|
||||
bra protectProjectilesContinue
|
||||
|
||||
@ -864,8 +846,7 @@ unrenderProjectilesSkip:
|
||||
; Y = Offset to projectile structure
|
||||
;
|
||||
unrenderProjectile:
|
||||
SAVE_AX
|
||||
|
||||
pha
|
||||
lda projectileData+GO_POSX,y
|
||||
bpl unrenderProjectileActive
|
||||
jmp unrenderProjectileDone
|
||||
@ -886,16 +867,8 @@ unrenderProjectileDoIt:
|
||||
sta PARAML0
|
||||
jsr unrenderGameObject
|
||||
|
||||
; Check for special deployment code
|
||||
lda projectileData+JD_TYPE,y
|
||||
tax
|
||||
PROJECTILETYPEPTR_X
|
||||
lda projectileTypes+PT_UNRENDER,x
|
||||
beq unrenderProjectileDone
|
||||
JSRA
|
||||
|
||||
unrenderProjectileDone:
|
||||
RESTORE_AX
|
||||
pla
|
||||
rts
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user