4cade/src/prelaunch/hungryboy.a
2019-12-12 21:51:54 -08:00

32 lines
691 B
Plaintext

;license:MIT
;(c) 2019 by 4am
!cpu 6502
!to "build/PRELAUNCH/HUNGRYBOY",plain
*=$106
!source "src/prelaunch/common.a"
+ENABLE_ACCEL
+GET_MACHINE_STATUS
and #CHEATS_ENABLED
sta patch+2
lda #<patch
sta $0814
lda #>patch
sta $080D
jmp $0800 ; decompress
patch nop
lda #0 ; SMC (will be non-zero if cheats are enabled)
beq +
; lives in $B6
lda #$A5
sta $70F4 ; patch - don't decrease lives
+
+DISABLE_ACCEL
jmp $94E0
!if * > $1C0 {
!error "code is too large, ends at ", *
}