2020-05-07 23:06:00 +00:00
|
|
|
;license:MIT
|
2022-05-13 05:30:35 +00:00
|
|
|
;(c) 2020, 2022 by Frank M., qkumba
|
2020-05-07 23:06:00 +00:00
|
|
|
|
|
|
|
!cpu 6502
|
2021-10-16 01:34:39 +00:00
|
|
|
!to "build/PRELAUNCH.INDEXED/NI",plain
|
2020-05-07 23:06:00 +00:00
|
|
|
*=$106
|
|
|
|
|
|
|
|
!source "src/prelaunch/common.a"
|
|
|
|
|
|
|
|
+ENABLE_ACCEL
|
2023-04-15 17:13:03 +00:00
|
|
|
+NEW_RESET_VECTOR $BE00
|
|
|
|
|
2020-05-07 23:06:00 +00:00
|
|
|
lda #$60
|
|
|
|
sta $404B
|
|
|
|
jsr $4000 ; decompress
|
|
|
|
|
2023-04-15 17:13:03 +00:00
|
|
|
ldx #(callback_e-callback)-1
|
|
|
|
- lda callback,x
|
|
|
|
sta $BE20,x
|
|
|
|
dex
|
|
|
|
bpl -
|
|
|
|
lda #$20 ; lets fix ROM calls to WAIT/$FCA8
|
2020-05-07 23:06:00 +00:00
|
|
|
sta $16A9 ; which behave differently
|
|
|
|
sta $80EE ; on different machines
|
|
|
|
sta $8799 ; (fixes slow scream on //c+ & //gs)
|
|
|
|
sta $8C8F
|
|
|
|
sta $8CC4
|
|
|
|
sta $8CE1
|
2023-04-15 17:13:03 +00:00
|
|
|
lda #$BE
|
2020-05-07 23:06:00 +00:00
|
|
|
sta $16AA
|
|
|
|
sta $80EF
|
|
|
|
sta $879A
|
|
|
|
sta $8C90
|
|
|
|
sta $8CC5
|
|
|
|
sta $8CE2
|
|
|
|
|
2022-05-13 05:30:35 +00:00
|
|
|
+READ_RAM2_NO_WRITE
|
|
|
|
lda MachineStatus
|
|
|
|
and #CHEATS_ENABLED
|
|
|
|
beq +
|
|
|
|
lda #$AD
|
|
|
|
sta $8718 ; patch - don't decrease lives
|
|
|
|
sta $8980 ; patch - don't increase lives
|
|
|
|
+
|
|
|
|
jsr DisableAccelerator
|
|
|
|
+READ_ROM_NO_WRITE
|
2020-05-07 23:06:00 +00:00
|
|
|
jmp $1206
|
|
|
|
|
|
|
|
callback sec ; non-ROM WAIT
|
|
|
|
wait2 pha
|
|
|
|
wait3 sbc #$01
|
|
|
|
bne wait3
|
|
|
|
pla
|
|
|
|
sbc #$01
|
|
|
|
bne wait2
|
|
|
|
rts
|
2023-04-15 17:13:03 +00:00
|
|
|
callback_e
|
2020-05-07 23:06:00 +00:00
|
|
|
|
|
|
|
!if * > $1C0 {
|
|
|
|
!error "code is too large, ends at ", *
|
|
|
|
}
|