mirror of
https://github.com/deater/dos33fsprogs.git
synced 2024-12-27 17:29:49 +00:00
ootw: work on bg beast
This commit is contained in:
parent
af4ec50a5c
commit
e212ef45ee
@ -41,14 +41,6 @@ ootw_pool:
|
||||
jsr load_rle_gr
|
||||
|
||||
|
||||
;=================================
|
||||
; copy to both pages $400/$800
|
||||
|
||||
; jsr gr_copy_to_current
|
||||
; jsr page_flip
|
||||
; jsr gr_copy_to_current
|
||||
|
||||
|
||||
;=================================
|
||||
; setup vars
|
||||
|
||||
@ -80,6 +72,11 @@ pool_loop:
|
||||
|
||||
jsr gr_copy_to_current
|
||||
|
||||
;================================
|
||||
; draw bg beast, if needed
|
||||
|
||||
jsr draw_bg_beast
|
||||
|
||||
|
||||
;=======================
|
||||
; draw pool ripples
|
||||
@ -403,6 +400,7 @@ draw_fg_plant:
|
||||
|
||||
exit_pool:
|
||||
lda #0
|
||||
sta BG_BEAST
|
||||
sta EXIT_COUNT
|
||||
|
||||
;=============================
|
||||
@ -430,6 +428,12 @@ exit_pool_loop:
|
||||
jsr draw_ripples
|
||||
|
||||
|
||||
;================
|
||||
; draw background beast
|
||||
|
||||
jsr draw_bg_beast
|
||||
|
||||
|
||||
;===============
|
||||
; draw physicist
|
||||
|
||||
@ -449,16 +453,6 @@ exit_pool_loop:
|
||||
|
||||
jsr put_sprite
|
||||
|
||||
;================
|
||||
; handle beast
|
||||
|
||||
; jsr move_beast
|
||||
|
||||
;================
|
||||
; draw beast
|
||||
|
||||
; jsr draw_beast
|
||||
|
||||
|
||||
;=================
|
||||
; draw foreground plant
|
||||
@ -490,6 +484,18 @@ framee_no_oflo:
|
||||
|
||||
exit_count_same:
|
||||
|
||||
|
||||
; see if start bg beast going
|
||||
|
||||
lda EXIT_COUNT
|
||||
cmp #(14*2)
|
||||
bne check_done_exiting_pool
|
||||
|
||||
lda #2
|
||||
sta BG_BEAST
|
||||
|
||||
check_done_exiting_pool:
|
||||
|
||||
; check if done
|
||||
|
||||
lda EXIT_COUNT
|
||||
@ -513,31 +519,78 @@ done_exit_pool:
|
||||
|
||||
;=========================
|
||||
; draw background beast
|
||||
;=========================
|
||||
|
||||
draw_bg_beast:
|
||||
;===================================================
|
||||
; put beast in background if it hasn't been released
|
||||
|
||||
lda BEAST_OUT
|
||||
bne beast_in
|
||||
; if 0, skip altogether
|
||||
lda BG_BEAST
|
||||
beq done_draw_bg_beast
|
||||
|
||||
lda #8
|
||||
sta DRAW_PAGE
|
||||
cmp #14
|
||||
bcc bg_beast_incoming ; blt
|
||||
|
||||
lda #<background_beast
|
||||
cmp #$f4
|
||||
bcs bg_beast_outgoing ; bge
|
||||
|
||||
bg_beast_just_standing:
|
||||
|
||||
; FIXME: look at you when close
|
||||
|
||||
lda #<beast_bg7
|
||||
sta INL
|
||||
lda #>background_beast
|
||||
lda #>beast_bg7
|
||||
sta INH
|
||||
lda #33
|
||||
sta XPOS
|
||||
jmp bg_beast_callsprite
|
||||
|
||||
lda #34
|
||||
|
||||
bg_beast_incoming:
|
||||
|
||||
lda BG_BEAST
|
||||
and #$fe
|
||||
asl
|
||||
tay
|
||||
|
||||
lda beast_incoming,Y
|
||||
sta INL
|
||||
lda beast_incoming+1,Y
|
||||
sta INH
|
||||
lda beast_incoming+2,Y
|
||||
jmp bg_beast_callsprite
|
||||
|
||||
bg_beast_outgoing:
|
||||
|
||||
lda BG_BEAST
|
||||
sec
|
||||
sbc #$f4
|
||||
and #$fe
|
||||
asl
|
||||
tay
|
||||
|
||||
lda beast_outgoing,Y
|
||||
sta INL
|
||||
lda beast_outgoing+1,Y
|
||||
sta INH
|
||||
lda beast_outgoing+2,Y
|
||||
jmp bg_beast_callsprite
|
||||
|
||||
|
||||
bg_beast_callsprite:
|
||||
sta XPOS
|
||||
lda #8
|
||||
sta YPOS
|
||||
|
||||
jsr put_sprite
|
||||
|
||||
lda FRAMEL
|
||||
and #$7
|
||||
bne done_draw_bg_beast
|
||||
|
||||
inc BG_BEAST
|
||||
|
||||
done_draw_bg_beast:
|
||||
|
||||
beast_in:
|
||||
rts
|
||||
|
||||
|
||||
|
@ -1,12 +1,117 @@
|
||||
;=========================
|
||||
; Beast
|
||||
|
||||
background_beast:
|
||||
|
||||
beast_incoming:
|
||||
.word beast_bg2 ; 2
|
||||
.byte 38,0
|
||||
.word beast_bg3 ; 4
|
||||
.byte 38,0
|
||||
.word beast_bg4 ; 6
|
||||
.byte 36,0
|
||||
.word beast_bg5 ; 8
|
||||
.byte 36,0
|
||||
.word beast_bg6 ; 10
|
||||
.byte 35,0
|
||||
.word beast_bg7 ; 12
|
||||
.byte 34,0
|
||||
.word beast_bg7 ; 14
|
||||
.byte 33,0
|
||||
|
||||
beast_outgoing:
|
||||
.word beast_bg8 ; F4
|
||||
.byte 33,0
|
||||
.word beast_bg9 ; F6
|
||||
.byte 34,0
|
||||
.word beast_bg10 ; F8
|
||||
.byte 34,0
|
||||
.word beast_bg11 ; FA
|
||||
.byte 35,0
|
||||
.word beast_bg12 ; FC
|
||||
.byte 36,0
|
||||
.word beast_bg13 ; FE
|
||||
.byte 38,0
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
beast_bg2:
|
||||
.byte 5,3
|
||||
.byte $AA,$AA,$AA,$AA,$AA
|
||||
.byte $AA,$00,$AA,$AA,$AA
|
||||
.byte $AA,$A0,$AA,$AA,$AA
|
||||
|
||||
beast_bg3:
|
||||
.byte 5,3
|
||||
.byte $AA,$AA,$AA,$AA,$AA
|
||||
.byte $AA,$00,$AA,$AA,$AA
|
||||
.byte $A0,$A0,$AA,$AA,$AA
|
||||
|
||||
beast_bg4:
|
||||
.byte 5,3
|
||||
.byte $AA,$AA,$0A,$AA,$AA
|
||||
.byte $AA,$00,$00,$00,$0A
|
||||
.byte $0A,$A0,$A0,$AA,$AA
|
||||
|
||||
beast_bg5:
|
||||
.byte 5,3
|
||||
.byte $AA,$0A,$0A,$AA,$AA
|
||||
.byte $00,$00,$00,$00,$AA
|
||||
.byte $00,$A0,$A0,$A0,$0A
|
||||
|
||||
beast_bg6:
|
||||
.byte 5,3
|
||||
.byte $AA,$0A,$0A,$AA,$AA
|
||||
.byte $00,$00,$00,$00,$0A
|
||||
.byte $AA,$00,$A0,$A0,$00
|
||||
|
||||
beast_bg7: ; old bg beast
|
||||
.byte $5,$3
|
||||
.byte $1a,$00,$0a,$aa,$aa
|
||||
.byte $00,$00,$00,$00,$aa
|
||||
.byte $aa,$00,$a0,$a0,$0a
|
||||
|
||||
beast_bg8: ; looking
|
||||
.byte 5,3
|
||||
.byte $1A,$10,$0A,$AA,$AA
|
||||
.byte $00,$00,$00,$00,$AA
|
||||
.byte $AA,$00,$A0,$A0,$0A
|
||||
|
||||
beast_bg9: ; turning
|
||||
.byte 5,3
|
||||
.byte $0A,$00,$0A,$AA,$AA
|
||||
.byte $00,$00,$00,$AA,$AA
|
||||
.byte $AA,$00,$00,$AA,$AA
|
||||
|
||||
beast_bg10: ; turning
|
||||
.byte 5,3
|
||||
.byte $0A,$00,$0A,$AA,$AA
|
||||
.byte $00,$00,$00,$AA,$AA
|
||||
.byte $00,$00,$AA,$AA,$AA
|
||||
|
||||
beast_bg11: ; going left
|
||||
.byte 5,3
|
||||
.byte $AA,$0A,$0A,$00,$0A
|
||||
.byte $00,$00,$00,$00,$A0
|
||||
.byte $00,$AA,$AA,$AA,$A0
|
||||
|
||||
beast_bg12: ; going left
|
||||
.byte 5,3
|
||||
.byte $AA,$0A,$0A,$0A,$AA
|
||||
.byte $0A,$00,$00,$00,$AA
|
||||
.byte $AA,$AA,$AA,$A0,$A0
|
||||
|
||||
beast_bg13: ; going left
|
||||
.byte 5,3
|
||||
.byte $AA,$0A,$0A,$0A,$AA
|
||||
.byte $00,$00,$00,$00,$AA
|
||||
.byte $AA,$A0,$AA,$A0,$A0
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
beast_standing:
|
||||
.byte $9,$6
|
||||
|
15
ootw/zp.inc
15
ootw/zp.inc
@ -107,17 +107,20 @@ MB_FRAME = $94
|
||||
MB_PATTERN = $95
|
||||
CHUNKSIZE = $95
|
||||
LZ4_DONE = $96
|
||||
DECODE_ERROR = $97
|
||||
COPY_TIME = $98
|
||||
DECOMPRESS_TIME = $99
|
||||
TIME_TAKEN = $9A
|
||||
LYRICS_ACTIVE = $9B
|
||||
;DECODE_ERROR = $97
|
||||
;COPY_TIME = $98
|
||||
;DECOMPRESS_TIME = $99
|
||||
;TIME_TAKEN = $9A
|
||||
;LYRICS_ACTIVE = $9B
|
||||
;FORTYCOL = $9C
|
||||
CURSOR = $9D
|
||||
;CURSOR = $9D
|
||||
|
||||
; More zero-page addresses
|
||||
; we try not to conflict with anything DOS, MONITOR or BASIC related
|
||||
|
||||
|
||||
BG_BEAST = $DE ; C1
|
||||
|
||||
ON_ELEVATOR = $DF ; ALL
|
||||
|
||||
LEFT_LIMIT = $E0 ; ALL
|
||||
|
Loading…
Reference in New Issue
Block a user