2019-12-21 18:49:23 +00:00
|
|
|
;license:MIT
|
2022-05-03 05:09:42 +00:00
|
|
|
;(c) 2019, 2022 by qkumba/Frank M.
|
2019-12-21 18:49:23 +00:00
|
|
|
|
|
|
|
!cpu 6502
|
2021-10-16 01:34:39 +00:00
|
|
|
!to "build/PRELAUNCH.INDEXED/JUNGLE.HUNT",plain
|
2019-12-21 18:49:23 +00:00
|
|
|
*=$106
|
|
|
|
|
|
|
|
!source "src/prelaunch/common.a"
|
|
|
|
|
2022-05-03 05:09:42 +00:00
|
|
|
jmp +
|
|
|
|
|
|
|
|
callback
|
|
|
|
txa
|
|
|
|
pha
|
|
|
|
jsr $BD47
|
|
|
|
|
|
|
|
+GET_MACHINE_STATUS
|
|
|
|
and #CHEATS_ENABLED
|
|
|
|
beq no_hook
|
|
|
|
|
|
|
|
lda #$60
|
|
|
|
sta $D6F ; no timer
|
|
|
|
ldx #$A5
|
|
|
|
lda $BDB1
|
|
|
|
cmp #$C1
|
|
|
|
beq hook_A
|
|
|
|
cmp #$C1
|
|
|
|
beq hook_A
|
|
|
|
cmp #$C3
|
|
|
|
beq hook_C
|
|
|
|
cmp #$C6
|
|
|
|
beq hook_F
|
|
|
|
cmp #$C8
|
|
|
|
bne no_hook
|
|
|
|
stx $775E ; no secondary timer
|
|
|
|
stx $7965 ; don't decrease lives
|
|
|
|
beq no_hook
|
|
|
|
|
|
|
|
hook_F
|
|
|
|
stx $78e0 ; don't decrease lives
|
|
|
|
beq no_hook
|
|
|
|
|
|
|
|
hook_C
|
|
|
|
stx $78dc ; don't decrease lives
|
|
|
|
beq no_hook
|
|
|
|
|
|
|
|
hook_A
|
|
|
|
stx $7bd3 ; don't decrease lives
|
|
|
|
|
|
|
|
no_hook
|
|
|
|
pla
|
|
|
|
tax
|
|
|
|
rts
|
|
|
|
|
|
|
|
+
|
2019-12-21 21:07:17 +00:00
|
|
|
+ENABLE_ACCEL
|
2019-12-21 18:49:23 +00:00
|
|
|
lda #$60
|
|
|
|
sta $81E
|
|
|
|
jsr $800
|
|
|
|
|
|
|
|
lda #$60
|
|
|
|
sta $BD44
|
|
|
|
jsr $BD00
|
|
|
|
|
|
|
|
lda #1
|
|
|
|
sta $0A6C
|
|
|
|
lda #0
|
|
|
|
sta $0A67 ; reset vector patch
|
|
|
|
|
2022-05-03 05:09:42 +00:00
|
|
|
lda #<callback
|
|
|
|
sta $1D2D
|
|
|
|
lda #>callback
|
|
|
|
sta $1D2E
|
|
|
|
|
2019-12-21 21:07:17 +00:00
|
|
|
+DISABLE_ACCEL
|
2019-12-21 18:49:23 +00:00
|
|
|
jmp $A00
|
|
|
|
|
|
|
|
!if * > $1C0 {
|
|
|
|
!error "code is too large, ends at ", *
|
|
|
|
}
|