Adds remaining NROM as _wip Update gitignore to not keep object files Adds AGENTS.md as this is an AI helped project
9151 lines
478 KiB
ArmAsm
9151 lines
478 KiB
ArmAsm
.include "symbols.inc"
|
|
.include "locals.inc"
|
|
|
|
.segment "PRG"
|
|
|
|
;------------------------------------------------------------
|
|
; Initial PRG data
|
|
; CPU $C000-$C195
|
|
; PRG $0000-$0195
|
|
;
|
|
; Pointer tables, title/credit text, resource descriptors, and
|
|
; startup lookup data. Boundaries below are conservative Pass-1
|
|
; classifications; uncertain structures remain explicit bytes.
|
|
;------------------------------------------------------------
|
|
|
|
; Embedded developer credit: "T.SAWANO".
|
|
DeveloperCreditText:
|
|
.byte $54, $2E, $53, $41, $57, $41, $4E, $4F ; PRG:$0000 Bytes:54 2E 53 41 57 41 4E 4F
|
|
|
|
; Pointers into the upper-PRG resource/script area.
|
|
ResourceScriptPointerTable:
|
|
.word $E75D, $E79A, $E7E1, $E826 ; PRG:$0008 Bytes:5D E7 9A E7 E1 E7 26 E8
|
|
.word $E869, $E8A6, $E8DF, $E916 ; PRG:$0010 Bytes:69 E8 A6 E8 DF E8 16 E9
|
|
.word $E949, $E988, $E9CD, $EA10 ; PRG:$0018 Bytes:49 E9 88 E9 CD E9 10 EA
|
|
.word $EA4F, $EA96, $EAE7, $EB32 ; PRG:$0020 Bytes:4F EA 96 EA E7 EA 32 EB
|
|
.word $EB7B, $EBB0, $EBE7, $EC1E ; PRG:$0028 Bytes:7B EB B0 EB E7 EB 1E EC
|
|
.word $EC56, $ECF3, $ED1E, $ED5E ; PRG:$0030 Bytes:56 EC F3 EC 1E ED 5E ED
|
|
.word $EDAF, $EE27, $EE90, $EF91 ; PRG:$0038 Bytes:AF ED 27 EE 90 EE 91 EF
|
|
.word $F117, $F11D ; PRG:$0040 Bytes:17 F1 1D F1
|
|
|
|
; Encoded title/message tile values; not ASCII text at runtime.
|
|
TitleOrMessageTileString:
|
|
.byte $28, $32, $33, $31, $34, $32, $30, $30, $29, $32, $29, $29, $31, $34, $34, $32 ; PRG:$0044 Bytes:28 32 33 31 34 32 30 30 29 32 29 29 31 34 34 32
|
|
.byte $22, $24, $23, $24 ; PRG:$0054 Bytes:22 24 23 24
|
|
|
|
; Variable-length resource descriptor records.
|
|
ResourceDescriptorData_C058:
|
|
.byte $66, $00, $01, $20, $00, $07, $29, $F2, $06, $00, $28, $EF, $06, $00, $2A, $AF ; PRG:$0058 Bytes:66 00 01 20 00 07 29 F2 06 00 28 EF 06 00 2A AF
|
|
.byte $06, $00, $20, $54, $03, $00, $29, $B6, $02, $00, $29, $49, $03, $01, $2B, $09 ; PRG:$0068 Bytes:06 00 20 54 03 00 29 B6 02 00 29 49 03 01 2B 09
|
|
.byte $03, $01, $20, $4D, $02, $00, $00, $01, $04, $0C, $07, $22, $10, $03, $00, $00 ; PRG:$0078 Bytes:03 01 20 4D 02 00 00 01 04 0C 07 22 10 03 00 00
|
|
.byte $01, $04, $0C, $07, $29, $E8, $03, $00, $00, $01, $0C, $00, $07, $22, $CE, $06 ; PRG:$0088 Bytes:01 04 0C 07 29 E8 03 00 00 01 0C 00 07 22 CE 06
|
|
.byte $00, $23, $06, $06, $00, $23, $13, $06, $00, $0F, $E4, $00, $18, $0F, $E5, $00 ; PRG:$0098 Bytes:00 23 06 06 00 23 13 06 00 0F E4 00 18 0F E5 00
|
|
.byte $28, $0F, $E4, $01, $D0, $0F, $E5, $01, $E0, $FF, $FF, $FF ; PRG:$00A8 Bytes:28 0F E4 01 D0 0F E5 01 E0 FF FF FF
|
|
|
|
; Small direction, coordinate, and signed-offset lookup tables.
|
|
DirectionAndCoordinateTables_C0B4:
|
|
.byte $FF, $00, $00, $00, $01, $A0, $80, $40, $00, $60, $80, $C0, $00, $64, $3C, $2C ; PRG:$00B4 Bytes:FF 00 00 00 01 A0 80 40 00 60 80 C0 00 64 3C 2C
|
|
.byte $1C, $44, $3C, $34, $2C, $80, $50, $30, $10, $40, $30, $20, $10, $02, $02, $04 ; PRG:$00C4 Bytes:1C 44 3C 34 2C 80 50 30 10 40 30 20 10 02 02 04
|
|
.byte $04, $01, $01, $01, $01, $01, $02, $02, $02, $00, $80, $B8, $D8, $F4, $14, $34 ; PRG:$00D4 Bytes:04 01 01 01 01 01 02 02 02 00 80 B8 D8 F4 14 34
|
|
.byte $54, $40, $02, $10, $00 ; PRG:$00E4 Bytes:54 40 02 10 00
|
|
|
|
; Startup object/template records and compact lookup data.
|
|
StartupObjectTemplateData_C0E9:
|
|
.byte $04, $01, $00, $00, $00, $00, $00, $04, $00, $00, $00, $22, $00, $05, $05, $0B ; PRG:$00E9 Bytes:04 01 00 00 00 00 00 04 00 00 00 22 00 05 05 0B
|
|
.byte $0B, $10, $06, $0C, $20, $04, $01, $00, $00, $00, $00, $00, $01, $EE, $00, $00 ; PRG:$00F9 Bytes:0B 10 06 0C 20 04 01 00 00 00 00 00 01 EE 00 00
|
|
.byte $11, $10, $20, $08, $11, $00, $05, $01, $00, $00, $00, $00, $00, $02, $A0, $00 ; PRG:$0109 Bytes:11 10 20 08 11 00 05 01 00 00 00 00 00 02 A0 00
|
|
.byte $03, $00, $68, $00, $00, $00, $00, $00, $20, $04, $11, $80, $04, $01, $00, $00 ; PRG:$0119 Bytes:03 00 68 00 00 00 00 00 20 04 11 80 04 01 00 00
|
|
.byte $00, $00, $00, $04, $7C, $00, $03, $22, $28, $02, $02, $0E, $0E, $00, $00, $01 ; PRG:$0129 Bytes:00 00 00 04 7C 00 03 22 28 02 02 0E 0E 00 00 01
|
|
.byte $06, $F6, $03, $08, $E6, $00, $02, $24, $E0, $20, $08, $11, $00, $06, $80, $00 ; PRG:$0139 Bytes:06 F6 03 08 E6 00 02 24 E0 20 08 11 00 06 80 00
|
|
.byte $00, $00, $00, $00, $02, $D0, $00, $00, $21, $A8, $04, $00, $0C, $08, $00, $10 ; PRG:$0149 Bytes:00 00 00 00 02 D0 00 00 21 A8 04 00 0C 08 00 10
|
|
.byte $04, $0D, $C0, $03, $01, $00, $00, $00, $00, $00, $02, $C8, $00, $03, $12, $C0 ; PRG:$0159 Bytes:04 0D C0 03 01 00 00 00 00 00 02 C8 00 03 12 C0
|
|
.byte $00, $40, $02, $0C, $00, $04, $00, $30, $00, $2C, $00, $00, $06, $70, $00, $00 ; PRG:$0169 Bytes:00 40 02 0C 00 04 00 30 00 2C 00 00 06 70 00 00
|
|
.byte $23, $68, $20, $02, $0A, $80, $04, $00, $4A, $00, $30, $00, $00, $04, $7C, $00 ; PRG:$0179 Bytes:23 68 20 02 0A 80 04 00 4A 00 30 00 00 04 7C 00
|
|
.byte $03, $00, $01, $07, $E7, $00, $13, $2E, $24, $2F, $14, $0F, $30 ; PRG:$0189 Bytes:03 00 01 07 E7 00 13 2E 24 2F 14 0F 30
|
|
|
|
;------------------------------------------------------------
|
|
; ResetEntry / IRQHandler
|
|
;
|
|
; Global:
|
|
; RESET and IRQ/BRK vector target. Initializes CPU, RAM, PPU,
|
|
; APU, startup resources, and enables NMI before entering the
|
|
; permanent main-program loop at $C1EB.
|
|
;
|
|
; Parameters:
|
|
; None.
|
|
;
|
|
; Returns:
|
|
; Never returns.
|
|
;------------------------------------------------------------
|
|
ResetEntry:
|
|
CLD ; PRG:$0196 Bytes:D8
|
|
LDA #$00 ; PRG:$0197 Bytes:A9 00
|
|
STA PPUCTRL ; PRG:$0199 Bytes:8D 00 20
|
|
SEI ; PRG:$019C Bytes:78
|
|
LDX #$FF ; PRG:$019D Bytes:A2 FF
|
|
TXS ; PRG:$019F Bytes:9A
|
|
LDX #$02 ; PRG:$01A0 Bytes:A2 02
|
|
InterruptPathLoop_C1A2:
|
|
LDA PPUSTATUS ; PRG:$01A2 Bytes:AD 02 20
|
|
BPL InterruptPathLoop_C1A2 ; PRG:$01A5 Bytes:10 FB
|
|
DEX ; PRG:$01A7 Bytes:CA
|
|
BNE InterruptPathLoop_C1A2 ; PRG:$01A8 Bytes:D0 F8
|
|
LDY #$24 ; PRG:$01AA Bytes:A0 24
|
|
LDA StartupPreserveFlag0 ; PRG:$01AC Bytes:A5 48
|
|
BNE InterruptPathOnNonZero_C1B4 ; PRG:$01AE Bytes:D0 04
|
|
LDA StartupPreserveFlag1 ; PRG:$01B0 Bytes:A5 49
|
|
BEQ InterruptPathOnZero_C1B6 ; PRG:$01B2 Bytes:F0 02
|
|
InterruptPathOnNonZero_C1B4:
|
|
LDY #$18 ; PRG:$01B4 Bytes:A0 18
|
|
InterruptPathOnZero_C1B6:
|
|
LDA #$00 ; PRG:$01B6 Bytes:A9 00
|
|
InterruptPathLoop_C1B8:
|
|
STA $0000,Y ; PRG:$01B8 Bytes:99 00 00
|
|
INY ; PRG:$01BB Bytes:C8
|
|
BNE InterruptPathLoop_C1B8 ; PRG:$01BC Bytes:D0 FA
|
|
LDY #$07 ; PRG:$01BE Bytes:A0 07
|
|
LDX #$06 ; PRG:$01C0 Bytes:A2 06
|
|
JSR RunGameTaskRoutine_CBA6 ; PRG:$01C2 Bytes:20 A6 CB
|
|
LDA #$55 ; PRG:$01C5 Bytes:A9 55
|
|
STA FrameShiftRegister0 ; PRG:$01C7 Bytes:85 10
|
|
LDA #$12 ; PRG:$01C9 Bytes:A9 12
|
|
STA PPUCTRL ; PRG:$01CB Bytes:8D 00 20
|
|
STA ShadowPPUCTRL ; PRG:$01CE Bytes:85 40
|
|
LDA #$06 ; PRG:$01D0 Bytes:A9 06
|
|
STA PPUMASK ; PRG:$01D2 Bytes:8D 01 20
|
|
STA ShadowPPUMASK ; PRG:$01D5 Bytes:85 41
|
|
LDA #$0F ; PRG:$01D7 Bytes:A9 0F
|
|
STA APUSTATUS ; PRG:$01D9 Bytes:8D 15 40
|
|
STA $0100 ; PRG:$01DC Bytes:8D 00 01
|
|
JSR RunGameTaskRoutine_C3E4 ; PRG:$01DF Bytes:20 E4 C3
|
|
LDA ShadowPPUCTRL ; PRG:$01E2 Bytes:A5 40
|
|
ORA #$80 ; PRG:$01E4 Bytes:09 80
|
|
STA ShadowPPUCTRL ; PRG:$01E6 Bytes:85 40
|
|
STA PPUCTRL ; PRG:$01E8 Bytes:8D 00 20
|
|
InterruptPathDispatch_C1EB:
|
|
JSR EnginePath_F58D ; PRG:$01EB Bytes:20 8D F5
|
|
JMP InterruptPathDispatch_C1EB ; PRG:$01EE Bytes:4C EB C1
|
|
;------------------------------------------------------------
|
|
; NMIHandler
|
|
;
|
|
; Global:
|
|
; Saves A and $00, performs OAM DMA and frame services,
|
|
; restores PPU state, then returns with RTI.
|
|
;
|
|
; Parameters:
|
|
; None.
|
|
;
|
|
; Returns:
|
|
; RTI.
|
|
;------------------------------------------------------------
|
|
NMIHandler:
|
|
PHA ; PRG:$01F1 Bytes:48
|
|
LDA WorkPtr0Lo ; PRG:$01F2 Bytes:A5 00
|
|
PHA ; PRG:$01F4 Bytes:48
|
|
LDA ShadowPPUCTRL ; PRG:$01F5 Bytes:A5 40
|
|
AND #$7F ; PRG:$01F7 Bytes:29 7F
|
|
STA ShadowPPUCTRL ; PRG:$01F9 Bytes:85 40
|
|
STA PPUCTRL ; PRG:$01FB Bytes:8D 00 20
|
|
LDA ShadowPPUMASK ; PRG:$01FE Bytes:A5 41
|
|
AND #$E7 ; PRG:$0200 Bytes:29 E7
|
|
STA ShadowPPUMASK ; PRG:$0202 Bytes:85 41
|
|
STA PPUMASK ; PRG:$0204 Bytes:8D 01 20
|
|
JSR UpdateGameStateRoutine_C996 ; PRG:$0207 Bytes:20 96 C9
|
|
LDA #$00 ; PRG:$020A Bytes:A9 00
|
|
STA OAMADDR ; PRG:$020C Bytes:8D 03 20
|
|
LDA #$02 ; PRG:$020F Bytes:A9 02
|
|
STA OAMDMA ; PRG:$0211 Bytes:8D 14 40
|
|
JSR ResourceAndLevelData ; PRG:$0214 Bytes:20 0B F2
|
|
JSR ObjectPath_E113 ; PRG:$0217 Bytes:20 13 E1
|
|
LDA ShadowPPUCTRL ; PRG:$021A Bytes:A5 40
|
|
STA PPUCTRL ; PRG:$021C Bytes:8D 00 20
|
|
LDA ShadowPPUMASK ; PRG:$021F Bytes:A5 41
|
|
ORA #$18 ; PRG:$0221 Bytes:09 18
|
|
STA ShadowPPUMASK ; PRG:$0223 Bytes:85 41
|
|
STA PPUMASK ; PRG:$0225 Bytes:8D 01 20
|
|
JSR AudioDriverCode ; PRG:$0228 Bytes:20 C1 F7
|
|
JSR EnginePath_F5AE ; PRG:$022B Bytes:20 AE F5
|
|
JSR ObjectPath_DDC1 ; PRG:$022E Bytes:20 C1 DD
|
|
JSR RunGameTaskRoutine_C368 ; PRG:$0231 Bytes:20 68 C3
|
|
NMIReadPPUStatus_C234:
|
|
LDA PPUSTATUS ; PRG:$0234 Bytes:AD 02 20
|
|
LDA ShadowPPUCTRL ; PRG:$0237 Bytes:A5 40
|
|
ORA #$80 ; PRG:$0239 Bytes:09 80
|
|
STA ShadowPPUCTRL ; PRG:$023B Bytes:85 40
|
|
STA PPUCTRL ; PRG:$023D Bytes:8D 00 20
|
|
PLA ; PRG:$0240 Bytes:68
|
|
STA WorkPtr0Lo ; PRG:$0241 Bytes:85 00
|
|
PLA ; PRG:$0243 Bytes:68
|
|
RTI ; PRG:$0244 Bytes:40
|
|
|
|
;------------------------------------------------------------
|
|
; CoreGameCode
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
CoreGameCode:
|
|
JSR RunGameTaskRoutine_CBB9 ; PRG:$0245 Bytes:20 B9 CB
|
|
JSR ObjectPath_D34E ; PRG:$0248 Bytes:20 4E D3
|
|
BCS ProcessCurrentObjectContinue_C264 ; PRG:$024B Bytes:B0 17
|
|
JSR UpdateObjectRecord_D27D ; PRG:$024D Bytes:20 7D D2
|
|
BCS ProcessCurrentObjectContinue_C264 ; PRG:$0250 Bytes:B0 12
|
|
LDY #$00 ; PRG:$0252 Bytes:A0 00
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0254 Bytes:B1 08
|
|
BNE ProcessCurrentObjectContinue_C264 ; PRG:$0256 Bytes:D0 0C
|
|
JSR ProcessCurrentObjectRoutine_CBE3 ; PRG:$0258 Bytes:20 E3 CB
|
|
JSR ReadObjectRecord_DADA ; PRG:$025B Bytes:20 DA DA
|
|
JSR ReadObjectRecord_CD7B ; PRG:$025E Bytes:20 7B CD
|
|
JSR ReadObjectRecord_D11E ; PRG:$0261 Bytes:20 1E D1
|
|
ProcessCurrentObjectContinue_C264:
|
|
JSR ObjectPath_D06D ; PRG:$0264 Bytes:20 6D D0
|
|
JSR RunGameTaskRoutine_CBC6 ; PRG:$0267 Bytes:20 C6 CB
|
|
JSR ObjectPath_D34E ; PRG:$026A Bytes:20 4E D3
|
|
BCS CorePathContinue_C286 ; PRG:$026D Bytes:B0 17
|
|
JSR UpdateObjectRecord_D27D ; PRG:$026F Bytes:20 7D D2
|
|
BCS CorePathContinue_C286 ; PRG:$0272 Bytes:B0 12
|
|
LDY #$00 ; PRG:$0274 Bytes:A0 00
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0276 Bytes:B1 08
|
|
BNE CorePathContinue_C286 ; PRG:$0278 Bytes:D0 0C
|
|
JSR ProcessCurrentObjectRoutine_CBE3 ; PRG:$027A Bytes:20 E3 CB
|
|
JSR ReadObjectRecord_DADA ; PRG:$027D Bytes:20 DA DA
|
|
JSR ReadObjectRecord_CD7B ; PRG:$0280 Bytes:20 7B CD
|
|
JSR ReadObjectRecord_D11E ; PRG:$0283 Bytes:20 1E D1
|
|
CorePathContinue_C286:
|
|
JSR ObjectPath_D08F ; PRG:$0286 Bytes:20 8F D0
|
|
JSR ObjectPath_DD10 ; PRG:$0289 Bytes:20 10 DD
|
|
JSR ObjectPath_DC5A ; PRG:$028C Bytes:20 5A DC
|
|
JSR UpdateObjectBuffer_DB52 ; PRG:$028F Bytes:20 52 DB
|
|
JSR ObjectPath_D856 ; PRG:$0292 Bytes:20 56 D8
|
|
JSR ObjectPath_D8BA ; PRG:$0295 Bytes:20 BA D8
|
|
JSR UpdateObjectBuffer_D64F ; PRG:$0298 Bytes:20 4F D6
|
|
JSR ObjectPath_D97B ; PRG:$029B Bytes:20 7B D9
|
|
JSR UpdateObjectBuffer_D0C8 ; PRG:$029E Bytes:20 C8 D0
|
|
JSR ObjectPath_CFA1 ; PRG:$02A1 Bytes:20 A1 CF
|
|
JSR ObjectPath_D0B1 ; PRG:$02A4 Bytes:20 B1 D0
|
|
JSR ProcessObjectStateRoutine_E6F3 ; PRG:$02A7 Bytes:20 F3 E6
|
|
JSR ObjectPath_DA91 ; PRG:$02AA Bytes:20 91 DA
|
|
JSR UpdateObjectBuffer_DBC7 ; PRG:$02AD Bytes:20 C7 DB
|
|
JSR ObjectPath_D0DF ; PRG:$02B0 Bytes:20 DF D0
|
|
JSR ObjectPath_D1D6 ; PRG:$02B3 Bytes:20 D6 D1
|
|
JSR UpdateObjectBuffer_DD8F ; PRG:$02B6 Bytes:20 8F DD
|
|
JSR UpdateObjectBuffer_D0F6 ; PRG:$02B9 Bytes:20 F6 D0
|
|
JSR UpdateGameStateRoutine_C47A ; PRG:$02BC Bytes:20 7A C4
|
|
JSR ObjectPath_D209 ; PRG:$02BF Bytes:20 09 D2
|
|
RTS ; PRG:$02C2 Bytes:60
|
|
CorePathLoop_C2C3:
|
|
JSR RunGameTaskRoutine_C84B ; PRG:$02C3 Bytes:20 4B C8
|
|
LDA #$00 ; PRG:$02C6 Bytes:A9 00
|
|
LDY #$1F ; PRG:$02C8 Bytes:A0 1F
|
|
CorePathLoop_C2CA:
|
|
STA a:$0080,Y ; PRG:$02CA Bytes:99 80 00
|
|
DEY ; PRG:$02CD Bytes:88
|
|
BPL CorePathLoop_C2CA ; PRG:$02CE Bytes:10 FA
|
|
STA RoundOrSubstate ; PRG:$02D0 Bytes:85 88
|
|
LDX ContextIndex ; PRG:$02D2 Bytes:A6 4A
|
|
InitializePlayerAndGameState:
|
|
STX PreviousContextIndex ; PRG:$02D4 Bytes:86 87
|
|
INX ; PRG:$02D6 Bytes:E8
|
|
CPX #$05 ; PRG:$02D7 Bytes:E0 05
|
|
BNE UpdateGameStateOnNonZero_C2DD ; PRG:$02D9 Bytes:D0 02
|
|
LDX #$00 ; PRG:$02DB Bytes:A2 00
|
|
UpdateGameStateOnNonZero_C2DD:
|
|
STX $4A ; PRG:$02DD Bytes:86 4A
|
|
LDA $87 ; PRG:$02DF Bytes:A5 87
|
|
ASL A ; PRG:$02E1 Bytes:0A
|
|
ASL A ; PRG:$02E2 Bytes:0A
|
|
ORA $88 ; PRG:$02E3 Bytes:05 88
|
|
STA $89 ; PRG:$02E5 Bytes:85 89
|
|
LDA #$01 ; PRG:$02E7 Bytes:A9 01
|
|
STA $4C ; PRG:$02E9 Bytes:85 4C
|
|
STA $8D ; PRG:$02EB Bytes:85 8D
|
|
STA $80 ; PRG:$02ED Bytes:85 80
|
|
STA $81 ; PRG:$02EF Bytes:85 81
|
|
UpdateGameStateDispatch_C2F1:
|
|
STA $8A ; PRG:$02F1 Bytes:85 8A
|
|
LDA #$02 ; PRG:$02F3 Bytes:A9 02
|
|
STA $8B ; PRG:$02F5 Bytes:85 8B
|
|
RTS ; PRG:$02F7 Bytes:60
|
|
CorePathLoop_C2F8:
|
|
LDA $7D ; PRG:$02F8 Bytes:A5 7D
|
|
BEQ CorePathLoop_C2C3 ; PRG:$02FA Bytes:F0 C7
|
|
LDA $44 ; PRG:$02FC Bytes:A5 44
|
|
AND #$20 ; PRG:$02FE Bytes:29 20
|
|
BEQ UpdatePlayerStateContinue_C310 ; PRG:$0300 Bytes:F0 0E
|
|
LDA $4F ; PRG:$0302 Bytes:A5 4F
|
|
BNE UpdatePlayerStateContinue_C310 ; PRG:$0304 Bytes:D0 0A
|
|
LDA $4B ; PRG:$0306 Bytes:A5 4B
|
|
EOR #$01 ; PRG:$0308 Bytes:49 01
|
|
STA $4B ; PRG:$030A Bytes:85 4B
|
|
LDA #$40 ; PRG:$030C Bytes:A9 40
|
|
STA $7D ; PRG:$030E Bytes:85 7D
|
|
UpdatePlayerStateContinue_C310:
|
|
STA $4F ; PRG:$0310 Bytes:85 4F
|
|
LDA #$90 ; PRG:$0312 Bytes:A9 90
|
|
LDX $4B ; PRG:$0314 Bytes:A6 4B
|
|
STX $4C ; PRG:$0316 Bytes:86 4C
|
|
BEQ CorePathOnZero_C31C ; PRG:$0318 Bytes:F0 02
|
|
LDA #$A0 ; PRG:$031A Bytes:A9 A0
|
|
CorePathOnZero_C31C:
|
|
STA $0200 ; PRG:$031C Bytes:8D 00 02
|
|
LDA #$E5 ; PRG:$031F Bytes:A9 E5
|
|
STA $0201 ; PRG:$0321 Bytes:8D 01 02
|
|
LDA #$00 ; PRG:$0324 Bytes:A9 00
|
|
STA $0202 ; PRG:$0326 Bytes:8D 02 02
|
|
LDA #$40 ; PRG:$0329 Bytes:A9 40
|
|
STA $0203 ; PRG:$032B Bytes:8D 03 02
|
|
LDA $44 ; PRG:$032E Bytes:A5 44
|
|
AND #$10 ; PRG:$0330 Bytes:29 10
|
|
BEQ CorePathContinue_C365 ; PRG:$0332 Bytes:F0 31
|
|
LDA $4E ; PRG:$0334 Bytes:A5 4E
|
|
BNE CorePathContinue_C365 ; PRG:$0336 Bytes:D0 2D
|
|
LDY #$1B ; PRG:$0338 Bytes:A0 1B
|
|
CorePathLoop_C33A:
|
|
STA a:$0024,Y ; PRG:$033A Bytes:99 24 00
|
|
DEY ; PRG:$033D Bytes:88
|
|
BPL CorePathLoop_C33A ; PRG:$033E Bytes:10 FA
|
|
LDY #$1F ; PRG:$0340 Bytes:A0 1F
|
|
UpdatePlayerStateLoop_C342:
|
|
STA a:$0080,Y ; PRG:$0342 Bytes:99 80 00
|
|
DEY ; PRG:$0345 Bytes:88
|
|
BPL UpdatePlayerStateLoop_C342 ; PRG:$0346 Bytes:10 FA
|
|
JSR RunGameTaskRoutine_C84B ; PRG:$0348 Bytes:20 4B C8
|
|
LDA #$05 ; PRG:$034B Bytes:A9 05
|
|
STA $80 ; PRG:$034D Bytes:85 80
|
|
LDX $4C ; PRG:$034F Bytes:A6 4C
|
|
BNE UpdateGameStateOnNonZero_C359 ; PRG:$0351 Bytes:D0 06
|
|
LDX #$01 ; PRG:$0353 Bytes:A2 01
|
|
STX $91 ; PRG:$0355 Bytes:86 91
|
|
LDA #$00 ; PRG:$0357 Bytes:A9 00
|
|
UpdateGameStateOnNonZero_C359:
|
|
STA $81 ; PRG:$0359 Bytes:85 81
|
|
LDA #$02 ; PRG:$035B Bytes:A9 02
|
|
STA $8B ; PRG:$035D Bytes:85 8B
|
|
LDA #$01 ; PRG:$035F Bytes:A9 01
|
|
STA $8A ; PRG:$0361 Bytes:85 8A
|
|
STA $33 ; PRG:$0363 Bytes:85 33
|
|
CorePathContinue_C365:
|
|
STA $4E ; PRG:$0365 Bytes:85 4E
|
|
RTS ; PRG:$0367 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C368
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C368:
|
|
LDA $92 ; PRG:$0368 Bytes:A5 92
|
|
BNE CorePathOnNonZero_C3CD ; PRG:$036A Bytes:D0 61
|
|
LDA $B0 ; PRG:$036C Bytes:A5 B0
|
|
BNE UpdateGameStateOnNonZero_C373 ; PRG:$036E Bytes:D0 03
|
|
JSR ProcessResourceStateRoutine_F577 ; PRG:$0370 Bytes:20 77 F5
|
|
UpdateGameStateOnNonZero_C373:
|
|
LDA $8A ; PRG:$0373 Bytes:A5 8A
|
|
BEQ CorePathLoop_C2F8 ; PRG:$0375 Bytes:F0 81
|
|
LDA $8D ; PRG:$0377 Bytes:A5 8D
|
|
BEQ CorePathOnZero_C38D ; PRG:$0379 Bytes:F0 12
|
|
LDA $90 ; PRG:$037B Bytes:A5 90
|
|
CMP #$01 ; PRG:$037D Bytes:C9 01
|
|
BNE CorePathOnNonZero_C387 ; PRG:$037F Bytes:D0 06
|
|
LDA $91 ; PRG:$0381 Bytes:A5 91
|
|
CMP #$01 ; PRG:$0383 Bytes:C9 01
|
|
BEQ RunGameTaskRoutine_C3E4 ; PRG:$0385 Bytes:F0 5D
|
|
CorePathOnNonZero_C387:
|
|
LDA $44 ; PRG:$0387 Bytes:A5 44
|
|
AND #$30 ; PRG:$0389 Bytes:29 30
|
|
BNE RunGameTaskRoutine_C3E4 ; PRG:$038B Bytes:D0 57
|
|
CorePathOnZero_C38D:
|
|
LDA $44 ; PRG:$038D Bytes:A5 44
|
|
AND #$10 ; PRG:$038F Bytes:29 10
|
|
BEQ UpdateGameStateContinue_C3A9 ; PRG:$0391 Bytes:F0 16
|
|
LDA $4E ; PRG:$0393 Bytes:A5 4E
|
|
BNE UpdateGameStateContinue_C3A9 ; PRG:$0395 Bytes:D0 12
|
|
LDA #$01 ; PRG:$0397 Bytes:A9 01
|
|
EOR $B0 ; PRG:$0399 Bytes:45 B0
|
|
STA $B0 ; PRG:$039B Bytes:85 B0
|
|
BNE CorePathOnNonZero_C3A3 ; PRG:$039D Bytes:D0 04
|
|
LDA #$06 ; PRG:$039F Bytes:A9 06
|
|
STA $92 ; PRG:$03A1 Bytes:85 92
|
|
CorePathOnNonZero_C3A3:
|
|
LDA #$20 ; PRG:$03A3 Bytes:A9 20
|
|
STA $FB ; PRG:$03A5 Bytes:85 FB
|
|
LDA #$01 ; PRG:$03A7 Bytes:A9 01
|
|
UpdateGameStateContinue_C3A9:
|
|
STA $4E ; PRG:$03A9 Bytes:85 4E
|
|
LDA $92 ; PRG:$03AB Bytes:A5 92
|
|
BNE CorePathLoop_C3CC ; PRG:$03AD Bytes:D0 1D
|
|
LDA $B0 ; PRG:$03AF Bytes:A5 B0
|
|
BNE CorePathLoop_C3CC ; PRG:$03B1 Bytes:D0 19
|
|
LDA $8A ; PRG:$03B3 Bytes:A5 8A
|
|
CMP #$02 ; PRG:$03B5 Bytes:C9 02
|
|
BEQ CorePathOnZero_C3E0 ; PRG:$03B7 Bytes:F0 27
|
|
JSR CoreGameCode ; PRG:$03B9 Bytes:20 45 C2
|
|
;------------------------------------------------------------
|
|
; UpdateGameStateRoutine_C3BC
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateGameStateRoutine_C3BC:
|
|
LDA $8D ; PRG:$03BC Bytes:A5 8D
|
|
BEQ CorePathLoop_C3CC ; PRG:$03BE Bytes:F0 0C
|
|
LDA #$00 ; PRG:$03C0 Bytes:A9 00
|
|
STA $FB ; PRG:$03C2 Bytes:85 FB
|
|
STA $FC ; PRG:$03C4 Bytes:85 FC
|
|
STA $FD ; PRG:$03C6 Bytes:85 FD
|
|
STA $FE ; PRG:$03C8 Bytes:85 FE
|
|
STA $FF ; PRG:$03CA Bytes:85 FF
|
|
CorePathLoop_C3CC:
|
|
RTS ; PRG:$03CC Bytes:60
|
|
CorePathOnNonZero_C3CD:
|
|
CMP #$01 ; PRG:$03CD Bytes:C9 01
|
|
BEQ CorePathOnZero_C400 ; PRG:$03CF Bytes:F0 2F
|
|
DEC $93 ; PRG:$03D1 Bytes:C6 93
|
|
BPL CorePathContinue_C3DF ; PRG:$03D3 Bytes:10 0A
|
|
LDA #$0A ; PRG:$03D5 Bytes:A9 0A
|
|
STA $93 ; PRG:$03D7 Bytes:85 93
|
|
LDA $92 ; PRG:$03D9 Bytes:A5 92
|
|
BEQ CorePathContinue_C3DF ; PRG:$03DB Bytes:F0 02
|
|
DEC $92 ; PRG:$03DD Bytes:C6 92
|
|
CorePathContinue_C3DF:
|
|
RTS ; PRG:$03DF Bytes:60
|
|
CorePathOnZero_C3E0:
|
|
JSR RunGameTaskRoutine_C6BE ; PRG:$03E0 Bytes:20 BE C6
|
|
RTS ; PRG:$03E3 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C3E4
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C3E4:
|
|
LDX $4D ; PRG:$03E4 Bytes:A6 4D
|
|
BNE CorePathOnNonZero_C3EE ; PRG:$03E6 Bytes:D0 06
|
|
LDA #$01 ; PRG:$03E8 Bytes:A9 01
|
|
STA $FB ; PRG:$03EA Bytes:85 FB
|
|
LDX #$04 ; PRG:$03EC Bytes:A2 04
|
|
CorePathOnNonZero_C3EE:
|
|
DEX ; PRG:$03EE Bytes:CA
|
|
STX $4D ; PRG:$03EF Bytes:86 4D
|
|
LDA #$40 ; PRG:$03F1 Bytes:A9 40
|
|
STA $7D ; PRG:$03F3 Bytes:85 7D
|
|
LDA #$01 ; PRG:$03F5 Bytes:A9 01
|
|
STA $4F ; PRG:$03F7 Bytes:85 4F
|
|
STA $4E ; PRG:$03F9 Bytes:85 4E
|
|
LDA #$00 ; PRG:$03FB Bytes:A9 00
|
|
JMP UpdateGameStateDispatch_C2F1 ; PRG:$03FD Bytes:4C F1 C2
|
|
CorePathOnZero_C400:
|
|
DEC $92 ; PRG:$0400 Bytes:C6 92
|
|
;------------------------------------------------------------
|
|
; UpdateGameStateRoutine_C402
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateGameStateRoutine_C402:
|
|
LDA $8A ; PRG:$0402 Bytes:A5 8A
|
|
CMP #$01 ; PRG:$0404 Bytes:C9 01
|
|
BNE CorePathLoop_C3CC ; PRG:$0406 Bytes:D0 C4
|
|
LDA $78 ; PRG:$0408 Bytes:A5 78
|
|
BNE CorePathLoop_C3CC ; PRG:$040A Bytes:D0 C0
|
|
LDX #$10 ; PRG:$040C Bytes:A2 10
|
|
LDA $8F ; PRG:$040E Bytes:A5 8F
|
|
BNE CorePathContinue_C41C ; PRG:$0410 Bytes:D0 0A
|
|
LDX #$08 ; PRG:$0412 Bytes:A2 08
|
|
LDA $2E ; PRG:$0414 Bytes:A5 2E
|
|
CMP #$02 ; PRG:$0416 Bytes:C9 02
|
|
BCC CorePathContinue_C41C ; PRG:$0418 Bytes:90 02
|
|
LDX #$04 ; PRG:$041A Bytes:A2 04
|
|
CorePathContinue_C41C:
|
|
STX $FB ; PRG:$041C Bytes:86 FB
|
|
JMP UpdateGameStateRoutine_C3BC ; PRG:$041E Bytes:4C BC C3
|
|
CorePathLoop_C421:
|
|
LDA $55 ; PRG:$0421 Bytes:A5 55
|
|
BNE CorePathOnNonZero_C437 ; PRG:$0423 Bytes:D0 12
|
|
LDA #$04 ; PRG:$0425 Bytes:A9 04
|
|
STA $55 ; PRG:$0427 Bytes:85 55
|
|
LDA #$01 ; PRG:$0429 Bytes:A9 01
|
|
EOR $A7 ; PRG:$042B Bytes:45 A7
|
|
STA $A7 ; PRG:$042D Bytes:85 A7
|
|
BEQ CorePathLoop_C432 ; PRG:$042F Bytes:F0 01
|
|
INY ; PRG:$0431 Bytes:C8
|
|
CorePathLoop_C432:
|
|
LDX #$08 ; PRG:$0432 Bytes:A2 08
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$0434 Bytes:20 AE D1
|
|
CorePathOnNonZero_C437:
|
|
RTS ; PRG:$0437 Bytes:60
|
|
CorePathLoop_C438:
|
|
LDX #$01 ; PRG:$0438 Bytes:A2 01
|
|
UpdatePlayerStateLoop_C43A:
|
|
LDA $90,X ; PRG:$043A Bytes:B5 90
|
|
CMP #$02 ; PRG:$043C Bytes:C9 02
|
|
BCS CorePathOnCarry_C475 ; PRG:$043E Bytes:B0 35
|
|
DEX ; PRG:$0440 Bytes:CA
|
|
BPL UpdatePlayerStateLoop_C43A ; PRG:$0441 Bytes:10 F7
|
|
LDX $43 ; PRG:$0443 Bytes:A6 43
|
|
LDA $40 ; PRG:$0445 Bytes:A5 40
|
|
AND #$02 ; PRG:$0447 Bytes:29 02
|
|
BEQ CorePathOnZero_C45A ; PRG:$0449 Bytes:F0 0F
|
|
LDA $40 ; PRG:$044B Bytes:A5 40
|
|
AND #$FD ; PRG:$044D Bytes:29 FD
|
|
STA $40 ; PRG:$044F Bytes:85 40
|
|
LDY #$14 ; PRG:$0451 Bytes:A0 14
|
|
LDX #$0C ; PRG:$0453 Bytes:A2 0C
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$0455 Bytes:20 AE D1
|
|
LDX #$FF ; PRG:$0458 Bytes:A2 FF
|
|
CorePathOnZero_C45A:
|
|
INX ; PRG:$045A Bytes:E8
|
|
INX ; PRG:$045B Bytes:E8
|
|
INX ; PRG:$045C Bytes:E8
|
|
CPX #$F2 ; PRG:$045D Bytes:E0 F2
|
|
BEQ RunGameTaskRoutine_C463 ; PRG:$045F Bytes:F0 02
|
|
STX $43 ; PRG:$0461 Bytes:86 43
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C463
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C463:
|
|
LDY #$1F ; PRG:$0463 Bytes:A0 1F
|
|
LDA #$F4 ; PRG:$0465 Bytes:A9 F4
|
|
CorePathLoop_C467:
|
|
STA $02E0,Y ; PRG:$0467 Bytes:99 E0 02
|
|
DEY ; PRG:$046A Bytes:88
|
|
BPL CorePathLoop_C467 ; PRG:$046B Bytes:10 FA
|
|
RTS ; PRG:$046D Bytes:60
|
|
CorePathLoop_C46E:
|
|
JSR UpdatePlayerStateRoutine_C504 ; PRG:$046E Bytes:20 04 C5
|
|
JSR ProcessObjectStateRoutine_DA26 ; PRG:$0471 Bytes:20 26 DA
|
|
RTS ; PRG:$0474 Bytes:60
|
|
CorePathOnCarry_C475:
|
|
LDA #$0A ; PRG:$0475 Bytes:A9 0A
|
|
STA $78 ; PRG:$0477 Bytes:85 78
|
|
RTS ; PRG:$0479 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateGameStateRoutine_C47A
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateGameStateRoutine_C47A:
|
|
JSR ProcessObjectStateRoutine_D1CE ; PRG:$047A Bytes:20 CE D1
|
|
LDA $78 ; PRG:$047D Bytes:A5 78
|
|
BEQ CorePathLoop_C46E ; PRG:$047F Bytes:F0 ED
|
|
CMP #$22 ; PRG:$0481 Bytes:C9 22
|
|
BCS CorePathLoop_C4B3 ; PRG:$0483 Bytes:B0 2E
|
|
CMP #$0B ; PRG:$0485 Bytes:C9 0B
|
|
BEQ CorePathLoop_C432 ; PRG:$0487 Bytes:F0 A9
|
|
BCS CorePathLoop_C421 ; PRG:$0489 Bytes:B0 96
|
|
CMP #$01 ; PRG:$048B Bytes:C9 01
|
|
BNE CorePathLoop_C438 ; PRG:$048D Bytes:D0 A9
|
|
DEC $78 ; PRG:$048F Bytes:C6 78
|
|
LDA #$02 ; PRG:$0491 Bytes:A9 02
|
|
STA $8A ; PRG:$0493 Bytes:85 8A
|
|
LDA #$00 ; PRG:$0495 Bytes:A9 00
|
|
STA $76 ; PRG:$0497 Bytes:85 76
|
|
STA $D0 ; PRG:$0499 Bytes:85 D0
|
|
STA $D1 ; PRG:$049B Bytes:85 D1
|
|
LDA $90 ; PRG:$049D Bytes:A5 90
|
|
BNE UpdatePlayerStateOnNonZero_C4A3 ; PRG:$049F Bytes:D0 02
|
|
INC $80 ; PRG:$04A1 Bytes:E6 80
|
|
UpdatePlayerStateOnNonZero_C4A3:
|
|
LDA $91 ; PRG:$04A3 Bytes:A5 91
|
|
BNE CorePathOnNonZero_C4A9 ; PRG:$04A5 Bytes:D0 02
|
|
INC $81 ; PRG:$04A7 Bytes:E6 81
|
|
CorePathOnNonZero_C4A9:
|
|
LDA #$87 ; PRG:$04A9 Bytes:A9 87
|
|
LDX #$C0 ; PRG:$04AB Bytes:A2 C0
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$04AD Bytes:20 7D F7
|
|
JMP ProcessObjectStateDispatch_DD48 ; PRG:$04B0 Bytes:4C 48 DD
|
|
CorePathLoop_C4B3:
|
|
LDA #$21 ; PRG:$04B3 Bytes:A9 21
|
|
LDX $AF ; PRG:$04B5 Bytes:A6 AF
|
|
BEQ CorePathOnZero_C4BF ; PRG:$04B7 Bytes:F0 06
|
|
LDA #$FF ; PRG:$04B9 Bytes:A9 FF
|
|
STA $55 ; PRG:$04BB Bytes:85 55
|
|
LDA #$17 ; PRG:$04BD Bytes:A9 17
|
|
CorePathOnZero_C4BF:
|
|
STA $78 ; PRG:$04BF Bytes:85 78
|
|
LDA #$F0 ; PRG:$04C1 Bytes:A9 F0
|
|
CorePathLoop_C4C3:
|
|
TAY ; PRG:$04C3 Bytes:A8
|
|
LDA #$01 ; PRG:$04C4 Bytes:A9 01
|
|
STA $03F0,Y ; PRG:$04C6 Bytes:99 F0 03
|
|
TYA ; PRG:$04C9 Bytes:98
|
|
SEC ; PRG:$04CA Bytes:38
|
|
SBC #$10 ; PRG:$04CB Bytes:E9 10
|
|
BNE CorePathLoop_C4C3 ; PRG:$04CD Bytes:D0 F4
|
|
LDA #$F0 ; PRG:$04CF Bytes:A9 F0
|
|
CorePathLoop_C4D1:
|
|
TAY ; PRG:$04D1 Bytes:A8
|
|
LDA #$00 ; PRG:$04D2 Bytes:A9 00
|
|
STA $0600,Y ; PRG:$04D4 Bytes:99 00 06
|
|
LDX $05F0,Y ; PRG:$04D7 Bytes:BE F0 05
|
|
BNE CorePathOnNonZero_C4E1 ; PRG:$04DA Bytes:D0 05
|
|
LDA #$01 ; PRG:$04DC Bytes:A9 01
|
|
STA $05F0,Y ; PRG:$04DE Bytes:99 F0 05
|
|
CorePathOnNonZero_C4E1:
|
|
TYA ; PRG:$04E1 Bytes:98
|
|
SEC ; PRG:$04E2 Bytes:38
|
|
SBC #$20 ; PRG:$04E3 Bytes:E9 20
|
|
CMP #$F0 ; PRG:$04E5 Bytes:C9 F0
|
|
BNE CorePathLoop_C4D1 ; PRG:$04E7 Bytes:D0 E8
|
|
LDA #$80 ; PRG:$04E9 Bytes:A9 80
|
|
CorePathLoop_C4EB:
|
|
TAY ; PRG:$04EB Bytes:A8
|
|
LDA #$00 ; PRG:$04EC Bytes:A9 00
|
|
STA $0470,Y ; PRG:$04EE Bytes:99 70 04
|
|
TYA ; PRG:$04F1 Bytes:98
|
|
SEC ; PRG:$04F2 Bytes:38
|
|
SBC #$20 ; PRG:$04F3 Bytes:E9 20
|
|
BNE CorePathLoop_C4EB ; PRG:$04F5 Bytes:D0 F4
|
|
LDA #$40 ; PRG:$04F7 Bytes:A9 40
|
|
STA $FB ; PRG:$04F9 Bytes:85 FB
|
|
JSR RunGameTaskRoutine_C7F3 ; PRG:$04FB Bytes:20 F3 C7
|
|
LDA #$83 ; PRG:$04FE Bytes:A9 83
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$0500 Bytes:20 1A F3
|
|
RTS ; PRG:$0503 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdatePlayerStateRoutine_C504
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdatePlayerStateRoutine_C504:
|
|
LDA $90 ; PRG:$0504 Bytes:A5 90
|
|
CMP #$01 ; PRG:$0506 Bytes:C9 01
|
|
BNE CorePathOnNonZero_C51A ; PRG:$0508 Bytes:D0 10
|
|
LDA $91 ; PRG:$050A Bytes:A5 91
|
|
CMP #$01 ; PRG:$050C Bytes:C9 01
|
|
BNE CorePathOnNonZero_C51A ; PRG:$050E Bytes:D0 0A
|
|
LDA #$01 ; PRG:$0510 Bytes:A9 01
|
|
STA $AF ; PRG:$0512 Bytes:85 AF
|
|
LDA #$23 ; PRG:$0514 Bytes:A9 23
|
|
STA $78 ; PRG:$0516 Bytes:85 78
|
|
BNE CorePathLoop_C4B3 ; PRG:$0518 Bytes:D0 99
|
|
CorePathOnNonZero_C51A:
|
|
RTS ; PRG:$051A Bytes:60
|
|
.byte $12, $F5, $F6, $1C, $0B, $18, $17, $1E, $1C, $24, $24, $02, $00, $00, $00, $AD ; PRG:$051B Bytes:12 F5 F6 1C 0B 18 17 1E 1C 24 24 02 00 00 00 AD
|
|
.byte $29, $2B, $1D, $19, $0E, $1B, $0F, $0E, $0C, $1D, $24, $03, $00, $00, $00, $AD ; PRG:$052B Bytes:29 2B 1D 19 0E 1B 0F 0E 0C 1D 24 03 00 00 00 AD
|
|
RunGameTaskDispatch_C53B:
|
|
LDA $3F ; PRG:$053B Bytes:A5 3F
|
|
BNE CorePathOnNonZero_C581 ; PRG:$053D Bytes:D0 42
|
|
LDA #$01 ; PRG:$053F Bytes:A9 01
|
|
STA $0F ; PRG:$0541 Bytes:85 0F
|
|
LDA #$2A ; PRG:$0543 Bytes:A9 2A
|
|
LDX #$EE ; PRG:$0545 Bytes:A2 EE
|
|
UpdatePlayerStateLoop_C547:
|
|
STX $00 ; PRG:$0547 Bytes:86 00
|
|
STA $01 ; PRG:$0549 Bytes:85 01
|
|
LDX $0F ; PRG:$054B Bytes:A6 0F
|
|
LDA $90,X ; PRG:$054D Bytes:B5 90
|
|
CMP #$01 ; PRG:$054F Bytes:C9 01
|
|
BEQ CorePathOnZero_C56B ; PRG:$0551 Bytes:F0 18
|
|
LDA #$2D ; PRG:$0553 Bytes:A9 2D
|
|
STA $02 ; PRG:$0555 Bytes:85 02
|
|
LDA #$C5 ; PRG:$0557 Bytes:A9 C5
|
|
STA $03 ; PRG:$0559 Bytes:85 03
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$055B Bytes:20 A1 F3
|
|
LDA $0F ; PRG:$055E Bytes:A5 0F
|
|
ORA #$80 ; PRG:$0560 Bytes:09 80
|
|
STA $01 ; PRG:$0562 Bytes:85 01
|
|
LDA #$30 ; PRG:$0564 Bytes:A9 30
|
|
STA $00 ; PRG:$0566 Bytes:85 00
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$0568 Bytes:20 0C F4
|
|
CorePathOnZero_C56B:
|
|
LDA #$29 ; PRG:$056B Bytes:A9 29
|
|
LDX #$2E ; PRG:$056D Bytes:A2 2E
|
|
DEC $0F ; PRG:$056F Bytes:C6 0F
|
|
BPL UpdatePlayerStateLoop_C547 ; PRG:$0571 Bytes:10 D4
|
|
JSR RunGameTaskRoutine_C7EF ; PRG:$0573 Bytes:20 EF C7
|
|
LDA #$02 ; PRG:$0576 Bytes:A9 02
|
|
STA $FE ; PRG:$0578 Bytes:85 FE
|
|
JSR RunGameTaskRoutine_C809 ; PRG:$057A Bytes:20 09 C8
|
|
INC $AC ; PRG:$057D Bytes:E6 AC
|
|
LDA #$18 ; PRG:$057F Bytes:A9 18
|
|
CorePathOnNonZero_C581:
|
|
JMP RunGameTaskDispatch_C7EA ; PRG:$0581 Bytes:4C EA C7
|
|
CorePathLoop_C584:
|
|
LDA $A1 ; PRG:$0584 Bytes:A5 A1
|
|
BNE CorePathContinue_C5C5 ; PRG:$0586 Bytes:D0 3D
|
|
LDA $2E ; PRG:$0588 Bytes:A5 2E
|
|
BNE CorePathOnNonZero_C590 ; PRG:$058A Bytes:D0 04
|
|
LDA $2F ; PRG:$058C Bytes:A5 2F
|
|
BEQ CorePathContinue_C5C5 ; PRG:$058E Bytes:F0 35
|
|
CorePathOnNonZero_C590:
|
|
LDA #$01 ; PRG:$0590 Bytes:A9 01
|
|
STA $0F ; PRG:$0592 Bytes:85 0F
|
|
UpdatePlayerStateLoop_C594:
|
|
LDA #$10 ; PRG:$0594 Bytes:A9 10
|
|
STA $00 ; PRG:$0596 Bytes:85 00
|
|
LDX $0F ; PRG:$0598 Bytes:A6 0F
|
|
LDA $90,X ; PRG:$059A Bytes:B5 90
|
|
CMP #$01 ; PRG:$059C Bytes:C9 01
|
|
BEQ CorePathOnZero_C5A5 ; PRG:$059E Bytes:F0 05
|
|
STX $01 ; PRG:$05A0 Bytes:86 01
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$05A2 Bytes:20 0C F4
|
|
CorePathOnZero_C5A5:
|
|
DEC $0F ; PRG:$05A5 Bytes:C6 0F
|
|
BPL UpdatePlayerStateLoop_C594 ; PRG:$05A7 Bytes:10 EB
|
|
JSR RunGameTaskRoutine_C7EF ; PRG:$05A9 Bytes:20 EF C7
|
|
LDA #$10 ; PRG:$05AC Bytes:A9 10
|
|
STA $00 ; PRG:$05AE Bytes:85 00
|
|
LDA #$02 ; PRG:$05B0 Bytes:A9 02
|
|
STA $01 ; PRG:$05B2 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F408 ; PRG:$05B4 Bytes:20 08 F4
|
|
LDA $2F ; PRG:$05B7 Bytes:A5 2F
|
|
AND #$F0 ; PRG:$05B9 Bytes:29 F0
|
|
STA $2F ; PRG:$05BB Bytes:85 2F
|
|
LDA #$82 ; PRG:$05BD Bytes:A9 82
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$05BF Bytes:20 1A F3
|
|
JMP RunGameTaskRoutine_C809 ; PRG:$05C2 Bytes:4C 09 C8
|
|
CorePathContinue_C5C5:
|
|
JMP RunGameTaskDispatch_C7E5 ; PRG:$05C5 Bytes:4C E5 C7
|
|
CorePathLoop_C5C8:
|
|
JMP RunGameTaskDispatch_C53B ; PRG:$05C8 Bytes:4C 3B C5
|
|
CorePathLoop_C5CB:
|
|
LDA $8F ; PRG:$05CB Bytes:A5 8F
|
|
BNE CorePathLoop_C5C8 ; PRG:$05CD Bytes:D0 F9
|
|
LDA #$7B ; PRG:$05CF Bytes:A9 7B
|
|
LDX #$C1 ; PRG:$05D1 Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$05D3 Bytes:20 7D F7
|
|
LDA #$BA ; PRG:$05D6 Bytes:A9 BA
|
|
STA $04A1 ; PRG:$05D8 Bytes:8D A1 04
|
|
LDX $4C ; PRG:$05DB Bytes:A6 4C
|
|
BNE CorePathOnNonZero_C5E4 ; PRG:$05DD Bytes:D0 05
|
|
LDX #$01 ; PRG:$05DF Bytes:A2 01
|
|
STX $04A0 ; PRG:$05E1 Bytes:8E A0 04
|
|
CorePathOnNonZero_C5E4:
|
|
JSR RunGameTaskRoutine_C81A ; PRG:$05E4 Bytes:20 1A C8
|
|
LDA #$20 ; PRG:$05E7 Bytes:A9 20
|
|
JMP RunGameTaskDispatch_C7EA ; PRG:$05E9 Bytes:4C EA C7
|
|
UpdatePlayerStateDispatch_C5EC:
|
|
LDA $AF ; PRG:$05EC Bytes:A5 AF
|
|
BEQ CorePathLoop_C584 ; PRG:$05EE Bytes:F0 94
|
|
LDA #$90 ; PRG:$05F0 Bytes:A9 90
|
|
RunGameTaskDispatch_C5F2:
|
|
STA $51 ; PRG:$05F2 Bytes:85 51
|
|
INC $AC ; PRG:$05F4 Bytes:E6 AC
|
|
RTS ; PRG:$05F6 Bytes:60
|
|
RunGameTaskDispatch_C5F7:
|
|
LDA $D6 ; PRG:$05F7 Bytes:A5 D6
|
|
BNE CorePathOnNonZero_C5FF ; PRG:$05F9 Bytes:D0 04
|
|
LDA $D7 ; PRG:$05FB Bytes:A5 D7
|
|
BEQ CorePathOnZero_C61E ; PRG:$05FD Bytes:F0 1F
|
|
CorePathOnNonZero_C5FF:
|
|
LDX #$01 ; PRG:$05FF Bytes:A2 01
|
|
CorePathLoop_C601:
|
|
STX $0F ; PRG:$0601 Bytes:86 0F
|
|
LDA $D6,X ; PRG:$0603 Bytes:B5 D6
|
|
BEQ CorePathOnZero_C60E ; PRG:$0605 Bytes:F0 07
|
|
DEC $D6,X ; PRG:$0607 Bytes:D6 D6
|
|
LDA #$05 ; PRG:$0609 Bytes:A9 05
|
|
JSR RunGameTaskRoutine_C830 ; PRG:$060B Bytes:20 30 C8
|
|
CorePathOnZero_C60E:
|
|
LDX $0F ; PRG:$060E Bytes:A6 0F
|
|
DEX ; PRG:$0610 Bytes:CA
|
|
BPL CorePathLoop_C601 ; PRG:$0611 Bytes:10 EE
|
|
JSR RunGameTaskRoutine_C7EF ; PRG:$0613 Bytes:20 EF C7
|
|
JSR RunGameTaskRoutine_C824 ; PRG:$0616 Bytes:20 24 C8
|
|
LDA #$18 ; PRG:$0619 Bytes:A9 18
|
|
JMP RunGameTaskDispatch_C80B ; PRG:$061B Bytes:4C 0B C8
|
|
CorePathOnZero_C61E:
|
|
JMP RunGameTaskDispatch_C7E5 ; PRG:$061E Bytes:4C E5 C7
|
|
RunGameTaskDispatch_C621:
|
|
LDA $AF ; PRG:$0621 Bytes:A5 AF
|
|
BEQ CorePathLoop_C5CB ; PRG:$0623 Bytes:F0 A6
|
|
JSR RunGameTaskRoutine_C809 ; PRG:$0625 Bytes:20 09 C8
|
|
LDA #$FF ; PRG:$0628 Bytes:A9 FF
|
|
JMP RunGameTaskDispatch_C5F2 ; PRG:$062A Bytes:4C F2 C5
|
|
RunGameTaskDispatch_C62D:
|
|
LDA #$82 ; PRG:$062D Bytes:A9 82
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$062F Bytes:20 1A F3
|
|
LDA #$6A ; PRG:$0632 Bytes:A9 6A
|
|
LDX #$C1 ; PRG:$0634 Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0636 Bytes:20 7D F7
|
|
LDA #$A0 ; PRG:$0639 Bytes:A9 A0
|
|
STA $0441 ; PRG:$063B Bytes:8D 41 04
|
|
LDA #$01 ; PRG:$063E Bytes:A9 01
|
|
STA $0449 ; PRG:$0640 Bytes:8D 49 04
|
|
LDA #$C0 ; PRG:$0643 Bytes:A9 C0
|
|
STA $044B ; PRG:$0645 Bytes:8D 4B 04
|
|
LDX #$00 ; PRG:$0648 Bytes:A2 00
|
|
JSR ProcessObjectStateRoutine_D44A ; PRG:$064A Bytes:20 4A D4
|
|
LDX $4C ; PRG:$064D Bytes:A6 4C
|
|
BEQ CorePathOnZero_C682 ; PRG:$064F Bytes:F0 31
|
|
JSR ProcessObjectStateRoutine_D44A ; PRG:$0651 Bytes:20 4A D4
|
|
CorePathLoop_C654:
|
|
LDX #$00 ; PRG:$0654 Bytes:A2 00
|
|
LDA $4C ; PRG:$0656 Bytes:A5 4C
|
|
BEQ CorePathOnZero_C670 ; PRG:$0658 Bytes:F0 16
|
|
LDA $D5 ; PRG:$065A Bytes:A5 D5
|
|
BMI CorePathLoop_C66A ; PRG:$065C Bytes:30 0C
|
|
SEC ; PRG:$065E Bytes:38
|
|
LDY $D4 ; PRG:$065F Bytes:A4 D4
|
|
BMI CorePathOnNegative_C667 ; PRG:$0661 Bytes:30 04
|
|
CMP $D4 ; PRG:$0663 Bytes:C5 D4
|
|
BEQ CorePathLoop_C66B ; PRG:$0665 Bytes:F0 04
|
|
CorePathOnNegative_C667:
|
|
INX ; PRG:$0667 Bytes:E8
|
|
BCC CorePathLoop_C66B ; PRG:$0668 Bytes:90 01
|
|
CorePathLoop_C66A:
|
|
INX ; PRG:$066A Bytes:E8
|
|
CorePathLoop_C66B:
|
|
STX $AE ; PRG:$066B Bytes:86 AE
|
|
JMP RunGameTaskDispatch_C7E8 ; PRG:$066D Bytes:4C E8 C7
|
|
CorePathOnZero_C670:
|
|
LDA $2E ; PRG:$0670 Bytes:A5 2E
|
|
CMP $A8 ; PRG:$0672 Bytes:C5 A8
|
|
BCS CorePathLoop_C66A ; PRG:$0674 Bytes:B0 F4
|
|
BCC CorePathLoop_C66B ; PRG:$0676 Bytes:90 F3
|
|
CorePathLoop_C678:
|
|
LDA $AF ; PRG:$0678 Bytes:A5 AF
|
|
BEQ CorePathOnZero_C67F ; PRG:$067A Bytes:F0 03
|
|
JMP RunGameTaskRoutine_C3E4 ; PRG:$067C Bytes:4C E4 C3
|
|
CorePathOnZero_C67F:
|
|
JMP RunGameTaskDispatch_C5F7 ; PRG:$067F Bytes:4C F7 C5
|
|
CorePathOnZero_C682:
|
|
LDA #$01 ; PRG:$0682 Bytes:A9 01
|
|
STA $0440 ; PRG:$0684 Bytes:8D 40 04
|
|
BNE CorePathLoop_C654 ; PRG:$0687 Bytes:D0 CB
|
|
CorePathLoop_C689:
|
|
LDA #$00 ; PRG:$0689 Bytes:A9 00
|
|
LDX $0405 ; PRG:$068B Bytes:AE 05 04
|
|
BNE CorePathOnNonZero_C6A2 ; PRG:$068E Bytes:D0 12
|
|
LDA $54 ; PRG:$0690 Bytes:A5 54
|
|
BNE CorePathOnNonZero_C6A8 ; PRG:$0692 Bytes:D0 14
|
|
LDA #$10 ; PRG:$0694 Bytes:A9 10
|
|
STA $54 ; PRG:$0696 Bytes:85 54
|
|
LDA #$04 ; PRG:$0698 Bytes:A9 04
|
|
STA $FC ; PRG:$069A Bytes:85 FC
|
|
LDA $AD ; PRG:$069C Bytes:A5 AD
|
|
EOR #$40 ; PRG:$069E Bytes:49 40
|
|
STA $AD ; PRG:$06A0 Bytes:85 AD
|
|
CorePathOnNonZero_C6A2:
|
|
STA $0408 ; PRG:$06A2 Bytes:8D 08 04
|
|
STA $0448 ; PRG:$06A5 Bytes:8D 48 04
|
|
CorePathOnNonZero_C6A8:
|
|
JSR ProcessObjectStateRoutine_D083 ; PRG:$06A8 Bytes:20 83 D0
|
|
JSR ProcessObjectStateRoutine_D0A5 ; PRG:$06AB Bytes:20 A5 D0
|
|
JSR UpdateObjectBuffer_D0C8 ; PRG:$06AE Bytes:20 C8 D0
|
|
JSR ObjectPath_D1D6 ; PRG:$06B1 Bytes:20 D6 D1
|
|
RTS ; PRG:$06B4 Bytes:60
|
|
CorePathLoop_C6B5:
|
|
JMP UpdatePlayerStateDispatch_C5EC ; PRG:$06B5 Bytes:4C EC C5
|
|
CorePathLoop_C6B8:
|
|
JMP RunGameTaskDispatch_C621 ; PRG:$06B8 Bytes:4C 21 C6
|
|
CorePathLoop_C6BB:
|
|
JMP RunGameTaskDispatch_C62D ; PRG:$06BB Bytes:4C 2D C6
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C6BE
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C6BE:
|
|
LDA $51 ; PRG:$06BE Bytes:A5 51
|
|
BNE CorePathLoop_C689 ; PRG:$06C0 Bytes:D0 C7
|
|
LDX $AC ; PRG:$06C2 Bytes:A6 AC
|
|
BEQ CorePathLoop_C6BB ; PRG:$06C4 Bytes:F0 F5
|
|
DEX ; PRG:$06C6 Bytes:CA
|
|
BEQ CorePathLoop_C6B5 ; PRG:$06C7 Bytes:F0 EC
|
|
DEX ; PRG:$06C9 Bytes:CA
|
|
BEQ CorePathLoop_C6B8 ; PRG:$06CA Bytes:F0 EC
|
|
DEX ; PRG:$06CC Bytes:CA
|
|
BEQ CorePathLoop_C678 ; PRG:$06CD Bytes:F0 A9
|
|
DEX ; PRG:$06CF Bytes:CA
|
|
BEQ CorePathOnZero_C740 ; PRG:$06D0 Bytes:F0 6E
|
|
DEX ; PRG:$06D2 Bytes:CA
|
|
BEQ CorePathOnZero_C73A ; PRG:$06D3 Bytes:F0 65
|
|
DEX ; PRG:$06D5 Bytes:CA
|
|
BEQ CorePathOnZero_C73D ; PRG:$06D6 Bytes:F0 65
|
|
LDA #$00 ; PRG:$06D8 Bytes:A9 00
|
|
LDX $87 ; PRG:$06DA Bytes:A6 87
|
|
INX ; PRG:$06DC Bytes:E8
|
|
STX $87 ; PRG:$06DD Bytes:86 87
|
|
CPX #$05 ; PRG:$06DF Bytes:E0 05
|
|
BNE CorePathOnNonZero_C6E5 ; PRG:$06E1 Bytes:D0 02
|
|
LDA #$01 ; PRG:$06E3 Bytes:A9 01
|
|
CorePathOnNonZero_C6E5:
|
|
STA $8F ; PRG:$06E5 Bytes:85 8F
|
|
CPX #$06 ; PRG:$06E7 Bytes:E0 06
|
|
BNE CorePathOnNonZero_C703 ; PRG:$06E9 Bytes:D0 18
|
|
LDX #$01 ; PRG:$06EB Bytes:A2 01
|
|
STX $87 ; PRG:$06ED Bytes:86 87
|
|
LDA $88 ; PRG:$06EF Bytes:A5 88
|
|
INC $88 ; PRG:$06F1 Bytes:E6 88
|
|
CMP #$03 ; PRG:$06F3 Bytes:C9 03
|
|
BNE CorePathOnNonZero_C703 ; PRG:$06F5 Bytes:D0 0C
|
|
STX $8C ; PRG:$06F7 Bytes:86 8C
|
|
STX $84 ; PRG:$06F9 Bytes:86 84
|
|
LDA #$00 ; PRG:$06FB Bytes:A9 00
|
|
STA $82 ; PRG:$06FD Bytes:85 82
|
|
STA $83 ; PRG:$06FF Bytes:85 83
|
|
STA $88 ; PRG:$0701 Bytes:85 88
|
|
CorePathOnNonZero_C703:
|
|
LDA $87 ; PRG:$0703 Bytes:A5 87
|
|
ASL A ; PRG:$0705 Bytes:0A
|
|
ASL A ; PRG:$0706 Bytes:0A
|
|
ORA $88 ; PRG:$0707 Bytes:05 88
|
|
STA $89 ; PRG:$0709 Bytes:85 89
|
|
LDX $8C ; PRG:$070B Bytes:A6 8C
|
|
LDA $8F ; PRG:$070D Bytes:A5 8F
|
|
BEQ UpdateGameStateOnZero_C713 ; PRG:$070F Bytes:F0 02
|
|
LDX #$00 ; PRG:$0711 Bytes:A2 00
|
|
UpdateGameStateOnZero_C713:
|
|
STX $8E ; PRG:$0713 Bytes:86 8E
|
|
LDA #$02 ; PRG:$0715 Bytes:A9 02
|
|
STA $8B ; PRG:$0717 Bytes:85 8B
|
|
DEC $84 ; PRG:$0719 Bytes:C6 84
|
|
BPL CorePathContinue_C72E ; PRG:$071B Bytes:10 11
|
|
LDA #$02 ; PRG:$071D Bytes:A9 02
|
|
STA $84 ; PRG:$071F Bytes:85 84
|
|
LDA $82 ; PRG:$0721 Bytes:A5 82
|
|
CMP #$07 ; PRG:$0723 Bytes:C9 07
|
|
BEQ CorePathContinue_C72E ; PRG:$0725 Bytes:F0 07
|
|
INC $82 ; PRG:$0727 Bytes:E6 82
|
|
LDA $82 ; PRG:$0729 Bytes:A5 82
|
|
LSR A ; PRG:$072B Bytes:4A
|
|
STA $83 ; PRG:$072C Bytes:85 83
|
|
CorePathContinue_C72E:
|
|
LDA #$01 ; PRG:$072E Bytes:A9 01
|
|
STA $00 ; PRG:$0730 Bytes:85 00
|
|
LDA #$03 ; PRG:$0732 Bytes:A9 03
|
|
STA $01 ; PRG:$0734 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$0736 Bytes:20 0C F4
|
|
RTS ; PRG:$0739 Bytes:60
|
|
CorePathOnZero_C73A:
|
|
JMP RunGameTaskDispatch_C772 ; PRG:$073A Bytes:4C 72 C7
|
|
CorePathOnZero_C73D:
|
|
JMP RunGameTaskDispatch_C7AD ; PRG:$073D Bytes:4C AD C7
|
|
CorePathOnZero_C740:
|
|
LDA #$01 ; PRG:$0740 Bytes:A9 01
|
|
STA $0480 ; PRG:$0742 Bytes:8D 80 04
|
|
STA $04A0 ; PRG:$0745 Bytes:8D A0 04
|
|
LDA #$46 ; PRG:$0748 Bytes:A9 46
|
|
STA $00 ; PRG:$074A Bytes:85 00
|
|
LDA #$29 ; PRG:$074C Bytes:A9 29
|
|
STA $01 ; PRG:$074E Bytes:85 01
|
|
LDA #$1B ; PRG:$0750 Bytes:A9 1B
|
|
STA $02 ; PRG:$0752 Bytes:85 02
|
|
LDA #$C5 ; PRG:$0754 Bytes:A9 C5
|
|
STA $03 ; PRG:$0756 Bytes:85 03
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$0758 Bytes:20 A1 F3
|
|
LDX $4C ; PRG:$075B Bytes:A6 4C
|
|
BEQ CorePathOnZero_C76A ; PRG:$075D Bytes:F0 0B
|
|
LDA #$06 ; PRG:$075F Bytes:A9 06
|
|
STA $00 ; PRG:$0761 Bytes:85 00
|
|
LDA #$2B ; PRG:$0763 Bytes:A9 2B
|
|
STA $01 ; PRG:$0765 Bytes:85 01
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$0767 Bytes:20 A1 F3
|
|
CorePathOnZero_C76A:
|
|
JSR RunGameTaskRoutine_C81A ; PRG:$076A Bytes:20 1A C8
|
|
LDA #$20 ; PRG:$076D Bytes:A9 20
|
|
JMP RunGameTaskDispatch_C7EA ; PRG:$076F Bytes:4C EA C7
|
|
RunGameTaskDispatch_C772:
|
|
LDA $D4 ; PRG:$0772 Bytes:A5 D4
|
|
BNE CorePathOnNonZero_C77A ; PRG:$0774 Bytes:D0 04
|
|
LDA $D5 ; PRG:$0776 Bytes:A5 D5
|
|
BEQ RunGameTaskDispatch_C7E5 ; PRG:$0778 Bytes:F0 6B
|
|
CorePathOnNonZero_C77A:
|
|
LDX #$01 ; PRG:$077A Bytes:A2 01
|
|
CorePathLoop_C77C:
|
|
STX $0F ; PRG:$077C Bytes:86 0F
|
|
LDA $D4,X ; PRG:$077E Bytes:B5 D4
|
|
BEQ RunGameTaskDispatch_C78B ; PRG:$0780 Bytes:F0 09
|
|
BMI CorePathOnNegative_C79B ; PRG:$0782 Bytes:30 17
|
|
DEC $D4,X ; PRG:$0784 Bytes:D6 D4
|
|
LDA #$01 ; PRG:$0786 Bytes:A9 01
|
|
JSR RunGameTaskRoutine_C830 ; PRG:$0788 Bytes:20 30 C8
|
|
RunGameTaskDispatch_C78B:
|
|
LDX $0F ; PRG:$078B Bytes:A6 0F
|
|
DEX ; PRG:$078D Bytes:CA
|
|
BPL CorePathLoop_C77C ; PRG:$078E Bytes:10 EC
|
|
JSR RunGameTaskRoutine_C7EF ; PRG:$0790 Bytes:20 EF C7
|
|
JSR RunGameTaskRoutine_C824 ; PRG:$0793 Bytes:20 24 C8
|
|
LDA #$05 ; PRG:$0796 Bytes:A9 05
|
|
JMP RunGameTaskDispatch_C80B ; PRG:$0798 Bytes:4C 0B C8
|
|
CorePathOnNegative_C79B:
|
|
INC $D4,X ; PRG:$079B Bytes:F6 D4
|
|
LDA #$01 ; PRG:$079D Bytes:A9 01
|
|
STA $00 ; PRG:$079F Bytes:85 00
|
|
INX ; PRG:$07A1 Bytes:E8
|
|
INX ; PRG:$07A2 Bytes:E8
|
|
INX ; PRG:$07A3 Bytes:E8
|
|
INX ; PRG:$07A4 Bytes:E8
|
|
STX $01 ; PRG:$07A5 Bytes:86 01
|
|
JSR ProcessResourceStateRoutine_F408 ; PRG:$07A7 Bytes:20 08 F4
|
|
JMP RunGameTaskDispatch_C78B ; PRG:$07AA Bytes:4C 8B C7
|
|
RunGameTaskDispatch_C7AD:
|
|
LDX $AE ; PRG:$07AD Bytes:A6 AE
|
|
BEQ CorePathOnZero_C7DD ; PRG:$07AF Bytes:F0 2C
|
|
DEX ; PRG:$07B1 Bytes:CA
|
|
LDA $FFF8,X ; PRG:$07B2 Bytes:BD F8 FF
|
|
STA $00 ; PRG:$07B5 Bytes:85 00
|
|
LDA $C52B,X ; PRG:$07B7 Bytes:BD 2B C5
|
|
STA $01 ; PRG:$07BA Bytes:85 01
|
|
LDA #$1E ; PRG:$07BC Bytes:A9 1E
|
|
STA $02 ; PRG:$07BE Bytes:85 02
|
|
LDA #$C5 ; PRG:$07C0 Bytes:A9 C5
|
|
STA $03 ; PRG:$07C2 Bytes:85 03
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$07C4 Bytes:20 A1 F3
|
|
DEC $AE ; PRG:$07C7 Bytes:C6 AE
|
|
LDA $AE ; PRG:$07C9 Bytes:A5 AE
|
|
ORA #$08 ; PRG:$07CB Bytes:09 08
|
|
STA $01 ; PRG:$07CD Bytes:85 01
|
|
LDA #$20 ; PRG:$07CF Bytes:A9 20
|
|
STA $00 ; PRG:$07D1 Bytes:85 00
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$07D3 Bytes:20 0C F4
|
|
JSR RunGameTaskRoutine_C7EF ; PRG:$07D6 Bytes:20 EF C7
|
|
LDA #$02 ; PRG:$07D9 Bytes:A9 02
|
|
STA $FE ; PRG:$07DB Bytes:85 FE
|
|
CorePathOnZero_C7DD:
|
|
JSR RunGameTaskRoutine_C809 ; PRG:$07DD Bytes:20 09 C8
|
|
LDA #$FF ; PRG:$07E0 Bytes:A9 FF
|
|
JMP RunGameTaskDispatch_C7EA ; PRG:$07E2 Bytes:4C EA C7
|
|
RunGameTaskDispatch_C7E5:
|
|
JSR RunGameTaskRoutine_C816 ; PRG:$07E5 Bytes:20 16 C8
|
|
RunGameTaskDispatch_C7E8:
|
|
LDA #$20 ; PRG:$07E8 Bytes:A9 20
|
|
RunGameTaskDispatch_C7EA:
|
|
STA $51 ; PRG:$07EA Bytes:85 51
|
|
INC $AC ; PRG:$07EC Bytes:E6 AC
|
|
RTS ; PRG:$07EE Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C7EF
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C7EF:
|
|
LDA #$01 ; PRG:$07EF Bytes:A9 01
|
|
STA $FE ; PRG:$07F1 Bytes:85 FE
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C7F3
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C7F3:
|
|
LDA #$F9 ; PRG:$07F3 Bytes:A9 F9
|
|
STA $00 ; PRG:$07F5 Bytes:85 00
|
|
JSR ProcessResourceStateRoutine_F500 ; PRG:$07F7 Bytes:20 00 F5
|
|
LDA #$0F ; PRG:$07FA Bytes:A9 0F
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$07FC Bytes:20 1A F3
|
|
LDX $4C ; PRG:$07FF Bytes:A6 4C
|
|
BEQ CorePathOnZero_C808 ; PRG:$0801 Bytes:F0 05
|
|
LDA #$81 ; PRG:$0803 Bytes:A9 81
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$0805 Bytes:20 1A F3
|
|
CorePathOnZero_C808:
|
|
RTS ; PRG:$0808 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C809
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C809:
|
|
LDA #$04 ; PRG:$0809 Bytes:A9 04
|
|
RunGameTaskDispatch_C80B:
|
|
STA $51 ; PRG:$080B Bytes:85 51
|
|
LDA #$01 ; PRG:$080D Bytes:A9 01
|
|
CorePathLoop_C80F:
|
|
STA $0405 ; PRG:$080F Bytes:8D 05 04
|
|
STA $0445 ; PRG:$0812 Bytes:8D 45 04
|
|
RTS ; PRG:$0815 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C816
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C816:
|
|
LDA #$00 ; PRG:$0816 Bytes:A9 00
|
|
BEQ CorePathLoop_C80F ; PRG:$0818 Bytes:F0 F5
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C81A
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C81A:
|
|
LDY #$07 ; PRG:$081A Bytes:A0 07
|
|
LDA #$00 ; PRG:$081C Bytes:A9 00
|
|
CorePathLoop_C81E:
|
|
STA a:$0034,Y ; PRG:$081E Bytes:99 34 00
|
|
DEY ; PRG:$0821 Bytes:88
|
|
BPL CorePathLoop_C81E ; PRG:$0822 Bytes:10 FA
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C824
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C824:
|
|
LDA #$48 ; PRG:$0824 Bytes:A9 48
|
|
LDX $4C ; PRG:$0826 Bytes:A6 4C
|
|
BEQ CorePathOnZero_C82C ; PRG:$0828 Bytes:F0 02
|
|
LDA #$45 ; PRG:$082A Bytes:A9 45
|
|
CorePathOnZero_C82C:
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$082C Bytes:20 1A F3
|
|
RTS ; PRG:$082F Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C830
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C830:
|
|
PHA ; PRG:$0830 Bytes:48
|
|
INX ; PRG:$0831 Bytes:E8
|
|
INX ; PRG:$0832 Bytes:E8
|
|
INX ; PRG:$0833 Bytes:E8
|
|
INX ; PRG:$0834 Bytes:E8
|
|
STX $01 ; PRG:$0835 Bytes:86 01
|
|
LDA #$01 ; PRG:$0837 Bytes:A9 01
|
|
STA $00 ; PRG:$0839 Bytes:85 00
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$083B Bytes:20 0C F4
|
|
PLA ; PRG:$083E Bytes:68
|
|
STA $00 ; PRG:$083F Bytes:85 00
|
|
LDA #$08 ; PRG:$0841 Bytes:A9 08
|
|
ORA $0F ; PRG:$0843 Bytes:05 0F
|
|
STA $01 ; PRG:$0845 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$0847 Bytes:20 0C F4
|
|
RTS ; PRG:$084A Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C84B
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C84B:
|
|
LDA #$05 ; PRG:$084B Bytes:A9 05
|
|
STA $01 ; PRG:$084D Bytes:85 01
|
|
LDY #$13 ; PRG:$084F Bytes:A0 13
|
|
CorePathLoop_C851:
|
|
TYA ; PRG:$0851 Bytes:98
|
|
AND #$FC ; PRG:$0852 Bytes:29 FC
|
|
STA $0720,Y ; PRG:$0854 Bytes:99 20 07
|
|
DEY ; PRG:$0857 Bytes:88
|
|
BPL CorePathLoop_C851 ; PRG:$0858 Bytes:10 F7
|
|
LDA #$20 ; PRG:$085A Bytes:A9 20
|
|
STA $04 ; PRG:$085C Bytes:85 04
|
|
LDA #$07 ; PRG:$085E Bytes:A9 07
|
|
STA $05 ; PRG:$0860 Bytes:85 05
|
|
CorePathLoop_C862:
|
|
LDA $10 ; PRG:$0862 Bytes:A5 10
|
|
AND #$03 ; PRG:$0864 Bytes:29 03
|
|
LDY #$03 ; PRG:$0866 Bytes:A0 03
|
|
ORA ($04),Y ; PRG:$0868 Bytes:11 04
|
|
CorePathLoop_C86A:
|
|
STA ($04),Y ; PRG:$086A Bytes:91 04
|
|
DEY ; PRG:$086C Bytes:88
|
|
BPL CorePathLoop_C86A ; PRG:$086D Bytes:10 FB
|
|
LDX #$02 ; PRG:$086F Bytes:A2 02
|
|
STX $03 ; PRG:$0871 Bytes:86 03
|
|
CorePathLoop_C873:
|
|
LDY $14 ; PRG:$0873 Bytes:A4 14
|
|
CorePathLoop_C875:
|
|
JSR EnginePath_F58D ; PRG:$0875 Bytes:20 8D F5
|
|
DEY ; PRG:$0878 Bytes:88
|
|
BNE CorePathLoop_C875 ; PRG:$0879 Bytes:D0 FA
|
|
LDA $11 ; PRG:$087B Bytes:A5 11
|
|
AND #$03 ; PRG:$087D Bytes:29 03
|
|
STA $02 ; PRG:$087F Bytes:85 02
|
|
LDY #$03 ; PRG:$0881 Bytes:A0 03
|
|
LDA ($04),Y ; PRG:$0883 Bytes:B1 04
|
|
AND #$FC ; PRG:$0885 Bytes:29 FC
|
|
ORA $02 ; PRG:$0887 Bytes:05 02
|
|
CorePathLoop_C889:
|
|
CMP ($04),Y ; PRG:$0889 Bytes:D1 04
|
|
BEQ CorePathLoop_C873 ; PRG:$088B Bytes:F0 E6
|
|
DEY ; PRG:$088D Bytes:88
|
|
BPL CorePathLoop_C889 ; PRG:$088E Bytes:10 F9
|
|
LDY $03 ; PRG:$0890 Bytes:A4 03
|
|
STA ($04),Y ; PRG:$0892 Bytes:91 04
|
|
DEC $03 ; PRG:$0894 Bytes:C6 03
|
|
BPL CorePathLoop_C873 ; PRG:$0896 Bytes:10 DB
|
|
CLC ; PRG:$0898 Bytes:18
|
|
LDA #$04 ; PRG:$0899 Bytes:A9 04
|
|
ADC $04 ; PRG:$089B Bytes:65 04
|
|
STA $04 ; PRG:$089D Bytes:85 04
|
|
LDA #$00 ; PRG:$089F Bytes:A9 00
|
|
ADC $05 ; PRG:$08A1 Bytes:65 05
|
|
STA $05 ; PRG:$08A3 Bytes:85 05
|
|
DEC $01 ; PRG:$08A5 Bytes:C6 01
|
|
BNE CorePathLoop_C862 ; PRG:$08A7 Bytes:D0 B9
|
|
RTS ; PRG:$08A9 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C8AA
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C8AA:
|
|
LDA $85 ; PRG:$08AA Bytes:A5 85
|
|
ASL A ; PRG:$08AC Bytes:0A
|
|
TAX ; PRG:$08AD Bytes:AA
|
|
LDA $C008,X ; PRG:$08AE Bytes:BD 08 C0
|
|
STA $04 ; PRG:$08B1 Bytes:85 04
|
|
LDA $C009,X ; PRG:$08B3 Bytes:BD 09 C0
|
|
STA $05 ; PRG:$08B6 Bytes:85 05
|
|
RTS ; PRG:$08B8 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C8B9
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C8B9:
|
|
LDY #$10 ; PRG:$08B9 Bytes:A0 10
|
|
LDX $83 ; PRG:$08BB Bytes:A6 83
|
|
LDA $C0D1,X ; PRG:$08BD Bytes:BD D1 C0
|
|
STA $0F ; PRG:$08C0 Bytes:85 0F
|
|
LDA #$80 ; PRG:$08C2 Bytes:A9 80
|
|
STA $00 ; PRG:$08C4 Bytes:85 00
|
|
LDA #$04 ; PRG:$08C6 Bytes:A9 04
|
|
STA $01 ; PRG:$08C8 Bytes:85 01
|
|
CorePathLoop_C8CA:
|
|
LDA #$01 ; PRG:$08CA Bytes:A9 01
|
|
STA ($00),Y ; PRG:$08CC Bytes:91 00
|
|
LDX #$00 ; PRG:$08CE Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$08D0 Bytes:20 D3 CB
|
|
BNE CorePathLoop_C8CA ; PRG:$08D3 Bytes:D0 F5
|
|
RTS ; PRG:$08D5 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C8D6
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C8D6:
|
|
JSR RunGameTaskRoutine_C463 ; PRG:$08D6 Bytes:20 63 C4
|
|
LDY #$0F ; PRG:$08D9 Bytes:A0 0F
|
|
LDA $4C ; PRG:$08DB Bytes:A5 4C
|
|
BNE CorePathLoop_C8E1 ; PRG:$08DD Bytes:D0 02
|
|
LDY #$07 ; PRG:$08DF Bytes:A0 07
|
|
CorePathLoop_C8E1:
|
|
LDA $C0A1,Y ; PRG:$08E1 Bytes:B9 A1 C0
|
|
STA $02E0,Y ; PRG:$08E4 Bytes:99 E0 02
|
|
DEY ; PRG:$08E7 Bytes:88
|
|
BPL CorePathLoop_C8E1 ; PRG:$08E8 Bytes:10 F7
|
|
RTS ; PRG:$08EA Bytes:60
|
|
.byte $1C, $34, $4C, $64, $94, $AC, $C4, $DC, $20, $38, $50, $68, $80, $98, $B0, $C8 ; PRG:$08EB Bytes:1C 34 4C 64 94 AC C4 DC 20 38 50 68 80 98 B0 C8
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_C8FB
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_C8FB:
|
|
LDA #$07 ; PRG:$08FB Bytes:A9 07
|
|
STA $0E ; PRG:$08FD Bytes:85 0E
|
|
LDA #$00 ; PRG:$08FF Bytes:A9 00
|
|
STA $04 ; PRG:$0901 Bytes:85 04
|
|
LDA #$06 ; PRG:$0903 Bytes:A9 06
|
|
STA $05 ; PRG:$0905 Bytes:85 05
|
|
CorePathLoop_C907:
|
|
LDA $16 ; PRG:$0907 Bytes:A5 16
|
|
AND #$07 ; PRG:$0909 Bytes:29 07
|
|
TAX ; PRG:$090B Bytes:AA
|
|
LDA $C8EB,X ; PRG:$090C Bytes:BD EB C8
|
|
STA $01 ; PRG:$090F Bytes:85 01
|
|
LDA $17 ; PRG:$0911 Bytes:A5 17
|
|
AND #$07 ; PRG:$0913 Bytes:29 07
|
|
TAX ; PRG:$0915 Bytes:AA
|
|
LDA $C8F3,X ; PRG:$0916 Bytes:BD F3 C8
|
|
STA $00 ; PRG:$0919 Bytes:85 00
|
|
JSR UpdateObjectBufferRoutine_E0DF ; PRG:$091B Bytes:20 DF E0
|
|
LDA #$00 ; PRG:$091E Bytes:A9 00
|
|
JSR ProcessObjectStateRoutine_E0B2 ; PRG:$0920 Bytes:20 B2 E0
|
|
JSR ObjectPath_E113 ; PRG:$0923 Bytes:20 13 E1
|
|
LDA #$00 ; PRG:$0926 Bytes:A9 00
|
|
JSR ProcessObjectStateRoutine_E0B2 ; PRG:$0928 Bytes:20 B2 E0
|
|
CMP #$24 ; PRG:$092B Bytes:C9 24
|
|
BEQ CorePathContinue_C941 ; PRG:$092D Bytes:F0 12
|
|
CMP #$4E ; PRG:$092F Bytes:C9 4E
|
|
BCS CorePathLoop_C937 ; PRG:$0931 Bytes:B0 04
|
|
CMP #$49 ; PRG:$0933 Bytes:C9 49
|
|
BCS CorePathContinue_C941 ; PRG:$0935 Bytes:B0 0A
|
|
CorePathLoop_C937:
|
|
LDX $10 ; PRG:$0937 Bytes:A6 10
|
|
CorePathLoop_C939:
|
|
JSR EnginePath_F58D ; PRG:$0939 Bytes:20 8D F5
|
|
DEX ; PRG:$093C Bytes:CA
|
|
BNE CorePathLoop_C939 ; PRG:$093D Bytes:D0 FA
|
|
BEQ CorePathLoop_C907 ; PRG:$093F Bytes:F0 C6
|
|
CorePathContinue_C941:
|
|
LDA #$07 ; PRG:$0941 Bytes:A9 07
|
|
STA $0F ; PRG:$0943 Bytes:85 0F
|
|
LDA #$00 ; PRG:$0945 Bytes:A9 00
|
|
STA $06 ; PRG:$0947 Bytes:85 06
|
|
LDA #$06 ; PRG:$0949 Bytes:A9 06
|
|
STA $07 ; PRG:$094B Bytes:85 07
|
|
CorePathLoop_C94D:
|
|
LDY #$01 ; PRG:$094D Bytes:A0 01
|
|
LDA ($06),Y ; PRG:$094F Bytes:B1 06
|
|
CMP $00 ; PRG:$0951 Bytes:C5 00
|
|
BNE CorePathOnNonZero_C95D ; PRG:$0953 Bytes:D0 08
|
|
LDY #$03 ; PRG:$0955 Bytes:A0 03
|
|
LDA ($06),Y ; PRG:$0957 Bytes:B1 06
|
|
CMP $01 ; PRG:$0959 Bytes:C5 01
|
|
BEQ CorePathLoop_C937 ; PRG:$095B Bytes:F0 DA
|
|
CorePathOnNonZero_C95D:
|
|
LDX #$06 ; PRG:$095D Bytes:A2 06
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$095F Bytes:20 D3 CB
|
|
BPL CorePathLoop_C94D ; PRG:$0962 Bytes:10 E9
|
|
LDY #$01 ; PRG:$0964 Bytes:A0 01
|
|
LDA #$00 ; PRG:$0966 Bytes:A9 00
|
|
LDX $8F ; PRG:$0968 Bytes:A6 8F
|
|
BNE CorePathContinue_C974 ; PRG:$096A Bytes:D0 08
|
|
LDX $11 ; PRG:$096C Bytes:A6 11
|
|
CPX #$3C ; PRG:$096E Bytes:E0 3C
|
|
BCS CorePathContinue_C974 ; PRG:$0970 Bytes:B0 02
|
|
LDA WorkPtr0Lo ; PRG:$0972 Bytes:A5 00
|
|
CorePathContinue_C974:
|
|
STA ($04),Y ; PRG:$0974 Bytes:91 04
|
|
LDA ($04),Y ; PRG:$0976 Bytes:B1 04
|
|
BEQ CorePathContinue_C986 ; PRG:$0978 Bytes:F0 0C
|
|
LDX $12 ; PRG:$097A Bytes:A6 12
|
|
CPX #$40 ; PRG:$097C Bytes:E0 40
|
|
BCS CorePathContinue_C986 ; PRG:$097E Bytes:B0 06
|
|
LDY #$10 ; PRG:$0980 Bytes:A0 10
|
|
LDA #$01 ; PRG:$0982 Bytes:A9 01
|
|
STA ($04),Y ; PRG:$0984 Bytes:91 04
|
|
CorePathContinue_C986:
|
|
LDY #$03 ; PRG:$0986 Bytes:A0 03
|
|
LDA WorkPtr0Hi ; PRG:$0988 Bytes:A5 01
|
|
STA ($04),Y ; PRG:$098A Bytes:91 04
|
|
LDX #$04 ; PRG:$098C Bytes:A2 04
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$098E Bytes:20 D3 CB
|
|
DEC $0E ; PRG:$0991 Bytes:C6 0E
|
|
BPL CorePathLoop_C937 ; PRG:$0993 Bytes:10 A2
|
|
RTS ; PRG:$0995 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateGameStateRoutine_C996
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateGameStateRoutine_C996:
|
|
LDA $8B ; PRG:$0996 Bytes:A5 8B
|
|
BNE UpdateGameStateOnNonZero_C99B ; PRG:$0998 Bytes:D0 01
|
|
RTS ; PRG:$099A Bytes:60
|
|
UpdateGameStateOnNonZero_C99B:
|
|
DEC $8B ; PRG:$099B Bytes:C6 8B
|
|
BEQ CorePathOnZero_C9DA ; PRG:$099D Bytes:F0 3B
|
|
LDA #$24 ; PRG:$099F Bytes:A9 24
|
|
STA $00 ; PRG:$09A1 Bytes:85 00
|
|
LDA #$01 ; PRG:$09A3 Bytes:A9 01
|
|
STA $01 ; PRG:$09A5 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F257 ; PRG:$09A7 Bytes:20 57 F2
|
|
LDA #$03 ; PRG:$09AA Bytes:A9 03
|
|
STA $01 ; PRG:$09AC Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F257 ; PRG:$09AE Bytes:20 57 F2
|
|
LDY #$1C ; PRG:$09B1 Bytes:A0 1C
|
|
LDA $4C ; PRG:$09B3 Bytes:A5 4C
|
|
BEQ UpdateGameStateOnZero_C9B8 ; PRG:$09B5 Bytes:F0 01
|
|
INY ; PRG:$09B7 Bytes:C8
|
|
UpdateGameStateOnZero_C9B8:
|
|
STY $85 ; PRG:$09B8 Bytes:84 85
|
|
JSR RunGameTaskRoutine_CB8C ; PRG:$09BA Bytes:20 8C CB
|
|
LDA #$1B ; PRG:$09BD Bytes:A9 1B
|
|
LDX #$14 ; PRG:$09BF Bytes:A2 14
|
|
LDY $8A ; PRG:$09C1 Bytes:A4 8A
|
|
BEQ CorePathOnZero_C9D3 ; PRG:$09C3 Bytes:F0 0E
|
|
LDA $87 ; PRG:$09C5 Bytes:A5 87
|
|
CLC ; PRG:$09C7 Bytes:18
|
|
ADC #$15 ; PRG:$09C8 Bytes:69 15
|
|
CMP #$1A ; PRG:$09CA Bytes:C9 1A
|
|
BEQ CorePathOnZero_C9D3 ; PRG:$09CC Bytes:F0 05
|
|
LDY $89 ; PRG:$09CE Bytes:A4 89
|
|
LDX $0720,Y ; PRG:$09D0 Bytes:BE 20 07
|
|
CorePathOnZero_C9D3:
|
|
STA $85 ; PRG:$09D3 Bytes:85 85
|
|
STX $86 ; PRG:$09D5 Bytes:86 86
|
|
JMP RunGameTaskDispatch_CB87 ; PRG:$09D7 Bytes:4C 87 CB
|
|
CorePathOnZero_C9DA:
|
|
JSR RunGameTaskRoutine_CB8C ; PRG:$09DA Bytes:20 8C CB
|
|
LDA $86 ; PRG:$09DD Bytes:A5 86
|
|
ASL A ; PRG:$09DF Bytes:0A
|
|
TAX ; PRG:$09E0 Bytes:AA
|
|
LDA $C008,X ; PRG:$09E1 Bytes:BD 08 C0
|
|
STA $00 ; PRG:$09E4 Bytes:85 00
|
|
LDA $C009,X ; PRG:$09E6 Bytes:BD 09 C0
|
|
STA $01 ; PRG:$09E9 Bytes:85 01
|
|
JSR ObjectPath_DF2F ; PRG:$09EB Bytes:20 2F DF
|
|
LDA $85 ; PRG:$09EE Bytes:A5 85
|
|
CMP #$1B ; PRG:$09F0 Bytes:C9 1B
|
|
BEQ CorePathOnZero_CA09 ; PRG:$09F2 Bytes:F0 15
|
|
JSR ProcessObjectStateRoutine_D211 ; PRG:$09F4 Bytes:20 11 D2
|
|
JSR ProcessObjectStateRoutine_D211 ; PRG:$09F7 Bytes:20 11 D2
|
|
JSR ProcessObjectStateRoutine_D211 ; PRG:$09FA Bytes:20 11 D2
|
|
JSR ProcessObjectStateRoutine_D211 ; PRG:$09FD Bytes:20 11 D2
|
|
JSR ResourceAndLevelData ; PRG:$0A00 Bytes:20 0B F2
|
|
JSR ObjectPath_DE15 ; PRG:$0A03 Bytes:20 15 DE
|
|
JSR UpdateObjectBuffer_DF5E ; PRG:$0A06 Bytes:20 5E DF
|
|
CorePathOnZero_CA09:
|
|
LDY #$06 ; PRG:$0A09 Bytes:A0 06
|
|
LDX #$04 ; PRG:$0A0B Bytes:A2 04
|
|
JSR RunGameTaskRoutine_CBA6 ; PRG:$0A0D Bytes:20 A6 CB
|
|
LDY #$02 ; PRG:$0A10 Bytes:A0 02
|
|
LDX #$01 ; PRG:$0A12 Bytes:A2 01
|
|
LDA #$F4 ; PRG:$0A14 Bytes:A9 F4
|
|
JSR RunGameTaskRoutine_CBA8 ; PRG:$0A16 Bytes:20 A8 CB
|
|
LDY #$50 ; PRG:$0A19 Bytes:A0 50
|
|
LDA #$00 ; PRG:$0A1B Bytes:A9 00
|
|
CorePathLoop_CA1D:
|
|
STA a:$009F,Y ; PRG:$0A1D Bytes:99 9F 00
|
|
DEY ; PRG:$0A20 Bytes:88
|
|
BNE CorePathLoop_CA1D ; PRG:$0A21 Bytes:D0 FA
|
|
LDY #$28 ; PRG:$0A23 Bytes:A0 28
|
|
UpdateGameStateLoop_CA25:
|
|
STA a:$0053,Y ; PRG:$0A25 Bytes:99 53 00
|
|
DEY ; PRG:$0A28 Bytes:88
|
|
BNE UpdateGameStateLoop_CA25 ; PRG:$0A29 Bytes:D0 FA
|
|
LDA $40 ; PRG:$0A2B Bytes:A5 40
|
|
ORA #$02 ; PRG:$0A2D Bytes:09 02
|
|
STA $40 ; PRG:$0A2F Bytes:85 40
|
|
LDA #$EF ; PRG:$0A31 Bytes:A9 EF
|
|
STA $43 ; PRG:$0A33 Bytes:85 43
|
|
LDA $8A ; PRG:$0A35 Bytes:A5 8A
|
|
BNE CorePathOnNonZero_CA4D ; PRG:$0A37 Bytes:D0 14
|
|
LDA #$90 ; PRG:$0A39 Bytes:A9 90
|
|
LDX #$C0 ; PRG:$0A3B Bytes:A2 C0
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0A3D Bytes:20 7D F7
|
|
LDA #$0F ; PRG:$0A40 Bytes:A9 0F
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$0A42 Bytes:20 1A F3
|
|
LDA #$81 ; PRG:$0A45 Bytes:A9 81
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$0A47 Bytes:20 1A F3
|
|
JMP RunGameTaskDispatch_CB87 ; PRG:$0A4A Bytes:4C 87 CB
|
|
CorePathOnNonZero_CA4D:
|
|
LDY $86 ; PRG:$0A4D Bytes:A4 86
|
|
LDA $C044,Y ; PRG:$0A4F Bytes:B9 44 C0
|
|
STA $3F ; PRG:$0A52 Bytes:85 3F
|
|
LDA #$FA ; PRG:$0A54 Bytes:A9 FA
|
|
LDX #$C0 ; PRG:$0A56 Bytes:A2 C0
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0A58 Bytes:20 7D F7
|
|
LDA #$E5 ; PRG:$0A5B Bytes:A9 E5
|
|
LDX #$C0 ; PRG:$0A5D Bytes:A2 C0
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0A5F Bytes:20 7D F7
|
|
LDA #$F2 ; PRG:$0A62 Bytes:A9 F2
|
|
STA $0437 ; PRG:$0A64 Bytes:8D 37 04
|
|
STA $0477 ; PRG:$0A67 Bytes:8D 77 04
|
|
LDA #$01 ; PRG:$0A6A Bytes:A9 01
|
|
STA $0449 ; PRG:$0A6C Bytes:8D 49 04
|
|
STA $0469 ; PRG:$0A6F Bytes:8D 69 04
|
|
STA $0479 ; PRG:$0A72 Bytes:8D 79 04
|
|
LDA #$D8 ; PRG:$0A75 Bytes:A9 D8
|
|
STA $043B ; PRG:$0A77 Bytes:8D 3B 04
|
|
LDA #$14 ; PRG:$0A7A Bytes:A9 14
|
|
STA $044B ; PRG:$0A7C Bytes:8D 4B 04
|
|
LDA #$24 ; PRG:$0A7F Bytes:A9 24
|
|
STA $046B ; PRG:$0A81 Bytes:8D 6B 04
|
|
LDA #$DC ; PRG:$0A84 Bytes:A9 DC
|
|
STA $047B ; PRG:$0A86 Bytes:8D 7B 04
|
|
LDA #$0B ; PRG:$0A89 Bytes:A9 0B
|
|
LDX #$C1 ; PRG:$0A8B Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0A8D Bytes:20 7D F7
|
|
LDA #$70 ; PRG:$0A90 Bytes:A9 70
|
|
STA $052B ; PRG:$0A92 Bytes:8D 2B 05
|
|
LDA #$78 ; PRG:$0A95 Bytes:A9 78
|
|
STA $054B ; PRG:$0A97 Bytes:8D 4B 05
|
|
LDA #$80 ; PRG:$0A9A Bytes:A9 80
|
|
STA $056B ; PRG:$0A9C Bytes:8D 6B 05
|
|
LDA #$88 ; PRG:$0A9F Bytes:A9 88
|
|
STA $058B ; PRG:$0AA1 Bytes:8D 8B 05
|
|
LDA #$90 ; PRG:$0AA4 Bytes:A9 90
|
|
STA $05AB ; PRG:$0AA6 Bytes:8D AB 05
|
|
LDA #$98 ; PRG:$0AA9 Bytes:A9 98
|
|
STA $05CB ; PRG:$0AAB Bytes:8D CB 05
|
|
LDA #$A0 ; PRG:$0AAE Bytes:A9 A0
|
|
STA $05EB ; PRG:$0AB0 Bytes:8D EB 05
|
|
LDA #$21 ; PRG:$0AB3 Bytes:A9 21
|
|
LDX #$C1 ; PRG:$0AB5 Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0AB7 Bytes:20 7D F7
|
|
LDA #$38 ; PRG:$0ABA Bytes:A9 38
|
|
STA $04AB ; PRG:$0ABC Bytes:8D AB 04
|
|
LDA #$48 ; PRG:$0ABF Bytes:A9 48
|
|
STA $04CB ; PRG:$0AC1 Bytes:8D CB 04
|
|
LDA #$58 ; PRG:$0AC4 Bytes:A9 58
|
|
STA $04EB ; PRG:$0AC6 Bytes:8D EB 04
|
|
LDA #$42 ; PRG:$0AC9 Bytes:A9 42
|
|
LDX #$C1 ; PRG:$0ACB Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0ACD Bytes:20 7D F7
|
|
LDX #$05 ; PRG:$0AD0 Bytes:A2 05
|
|
LDY #$07 ; PRG:$0AD2 Bytes:A0 07
|
|
CorePathLoop_CAD4:
|
|
TYA ; PRG:$0AD4 Bytes:98
|
|
STA $0600,X ; PRG:$0AD5 Bytes:9D 00 06
|
|
TXA ; PRG:$0AD8 Bytes:8A
|
|
CLC ; PRG:$0AD9 Bytes:18
|
|
ADC #$20 ; PRG:$0ADA Bytes:69 20
|
|
TAX ; PRG:$0ADC Bytes:AA
|
|
DEY ; PRG:$0ADD Bytes:88
|
|
BNE CorePathLoop_CAD4 ; PRG:$0ADE Bytes:D0 F4
|
|
LDA #$01 ; PRG:$0AE0 Bytes:A9 01
|
|
STA $0629 ; PRG:$0AE2 Bytes:8D 29 06
|
|
STA $0649 ; PRG:$0AE5 Bytes:8D 49 06
|
|
STA $06E9 ; PRG:$0AE8 Bytes:8D E9 06
|
|
JSR RunGameTaskRoutine_C8FB ; PRG:$0AEB Bytes:20 FB C8
|
|
LDA #$58 ; PRG:$0AEE Bytes:A9 58
|
|
LDX #$C1 ; PRG:$0AF0 Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0AF2 Bytes:20 7D F7
|
|
LDA #$C8 ; PRG:$0AF5 Bytes:A9 C8
|
|
STA $03DB ; PRG:$0AF7 Bytes:8D DB 03
|
|
LDA #$D0 ; PRG:$0AFA Bytes:A9 D0
|
|
STA $03EB ; PRG:$0AFC Bytes:8D EB 03
|
|
LDA #$37 ; PRG:$0AFF Bytes:A9 37
|
|
LDX #$C1 ; PRG:$0B01 Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0B03 Bytes:20 7D F7
|
|
LDA #$01 ; PRG:$0B06 Bytes:A9 01
|
|
STA $8A ; PRG:$0B08 Bytes:85 8A
|
|
LDA #$02 ; PRG:$0B0A Bytes:A9 02
|
|
LDY $8F ; PRG:$0B0C Bytes:A4 8F
|
|
BNE UpdateGameStateOnNonZero_CB15 ; PRG:$0B0E Bytes:D0 05
|
|
LDA #$08 ; PRG:$0B10 Bytes:A9 08
|
|
SEC ; PRG:$0B12 Bytes:38
|
|
SBC $83 ; PRG:$0B13 Bytes:E5 83
|
|
UpdateGameStateOnNonZero_CB15:
|
|
STA $2E ; PRG:$0B15 Bytes:85 2E
|
|
SEC ; PRG:$0B17 Bytes:38
|
|
SBC #$03 ; PRG:$0B18 Bytes:E9 03
|
|
STA $A8 ; PRG:$0B1A Bytes:85 A8
|
|
LDA #$00 ; PRG:$0B1C Bytes:A9 00
|
|
STA $2F ; PRG:$0B1E Bytes:85 2F
|
|
STA $2C ; PRG:$0B20 Bytes:85 2C
|
|
LDA #$8A ; PRG:$0B22 Bytes:A9 8A
|
|
LDX #$C1 ; PRG:$0B24 Bytes:A2 C1
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0B26 Bytes:20 7D F7
|
|
LDA #$59 ; PRG:$0B29 Bytes:A9 59
|
|
LDX #$C0 ; PRG:$0B2B Bytes:A2 C0
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0B2D Bytes:20 7D F7
|
|
LDA #$26 ; PRG:$0B30 Bytes:A9 26
|
|
LDY $8F ; PRG:$0B32 Bytes:A4 8F
|
|
BEQ UpdatePlayerStateOnZero_CB3F ; PRG:$0B34 Bytes:F0 09
|
|
LDA #$7E ; PRG:$0B36 Bytes:A9 7E
|
|
LDX #$C0 ; PRG:$0B38 Bytes:A2 C0
|
|
JSR ProcessResourceStateRoutine_F77D ; PRG:$0B3A Bytes:20 7D F7
|
|
LDA #$28 ; PRG:$0B3D Bytes:A9 28
|
|
UpdatePlayerStateOnZero_CB3F:
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$0B3F Bytes:20 1A F3
|
|
LDX #$00 ; PRG:$0B42 Bytes:A2 00
|
|
JSR ProcessObjectStateRoutine_D42C ; PRG:$0B44 Bytes:20 2C D4
|
|
LDX $4C ; PRG:$0B47 Bytes:A6 4C
|
|
JSR ProcessObjectStateRoutine_D42C ; PRG:$0B49 Bytes:20 2C D4
|
|
LDX #$11 ; PRG:$0B4C Bytes:A2 11
|
|
LDA $90 ; PRG:$0B4E Bytes:A5 90
|
|
CMP #$01 ; PRG:$0B50 Bytes:C9 01
|
|
BEQ UpdatePlayerStateOnZero_CB56 ; PRG:$0B52 Bytes:F0 02
|
|
STX $90 ; PRG:$0B54 Bytes:86 90
|
|
UpdatePlayerStateOnZero_CB56:
|
|
LDA $91 ; PRG:$0B56 Bytes:A5 91
|
|
CMP #$01 ; PRG:$0B58 Bytes:C9 01
|
|
BEQ UpdateGameStateOnZero_CB5E ; PRG:$0B5A Bytes:F0 02
|
|
STX $91 ; PRG:$0B5C Bytes:86 91
|
|
UpdateGameStateOnZero_CB5E:
|
|
JSR RunGameTaskRoutine_C8D6 ; PRG:$0B5E Bytes:20 D6 C8
|
|
JSR RunGameTaskRoutine_C8B9 ; PRG:$0B61 Bytes:20 B9 C8
|
|
LDA #$08 ; PRG:$0B64 Bytes:A9 08
|
|
STA $0495 ; PRG:$0B66 Bytes:8D 95 04
|
|
LDA #$18 ; PRG:$0B69 Bytes:A9 18
|
|
STA $04B5 ; PRG:$0B6B Bytes:8D B5 04
|
|
LDA #$28 ; PRG:$0B6E Bytes:A9 28
|
|
STA $04D5 ; PRG:$0B70 Bytes:8D D5 04
|
|
LDA #$38 ; PRG:$0B73 Bytes:A9 38
|
|
STA $04F5 ; PRG:$0B75 Bytes:8D F5 04
|
|
LDA #$02 ; PRG:$0B78 Bytes:A9 02
|
|
STA $FB ; PRG:$0B7A Bytes:85 FB
|
|
JSR UpdateGameStateRoutine_C3BC ; PRG:$0B7C Bytes:20 BC C3
|
|
LDA $8D ; PRG:$0B7F Bytes:A5 8D
|
|
BNE CorePathOnNonZero_CB85 ; PRG:$0B81 Bytes:D0 02
|
|
LDA #$21 ; PRG:$0B83 Bytes:A9 21
|
|
CorePathOnNonZero_CB85:
|
|
STA $92 ; PRG:$0B85 Bytes:85 92
|
|
RunGameTaskDispatch_CB87:
|
|
PLA ; PRG:$0B87 Bytes:68
|
|
PLA ; PRG:$0B88 Bytes:68
|
|
JMP NMIReadPPUStatus_C234 ; PRG:$0B89 Bytes:4C 34 C2
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_CB8C
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_CB8C:
|
|
JSR RunGameTaskRoutine_C8AA ; PRG:$0B8C Bytes:20 AA C8
|
|
LDY #$01 ; PRG:$0B8F Bytes:A0 01
|
|
LDA ($04),Y ; PRG:$0B91 Bytes:B1 04
|
|
CLC ; PRG:$0B93 Bytes:18
|
|
ADC $04 ; PRG:$0B94 Bytes:65 04
|
|
STA $00 ; PRG:$0B96 Bytes:85 00
|
|
LDA #$00 ; PRG:$0B98 Bytes:A9 00
|
|
ADC $05 ; PRG:$0B9A Bytes:65 05
|
|
STA $01 ; PRG:$0B9C Bytes:85 01
|
|
JSR ProcessResourceStateDispatch_F2EA ; PRG:$0B9E Bytes:20 EA F2
|
|
INY ; PRG:$0BA1 Bytes:C8
|
|
JSR ObjectPath_DF2F ; PRG:$0BA2 Bytes:20 2F DF
|
|
RTS ; PRG:$0BA5 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_CBA6
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_CBA6:
|
|
LDA #$00 ; PRG:$0BA6 Bytes:A9 00
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_CBA8
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_CBA8:
|
|
STY $01 ; PRG:$0BA8 Bytes:84 01
|
|
LDY #$00 ; PRG:$0BAA Bytes:A0 00
|
|
STY $00 ; PRG:$0BAC Bytes:84 00
|
|
CorePathLoop_CBAE:
|
|
STA ($00),Y ; PRG:$0BAE Bytes:91 00
|
|
DEY ; PRG:$0BB0 Bytes:88
|
|
BNE CorePathLoop_CBAE ; PRG:$0BB1 Bytes:D0 FB
|
|
DEC $01 ; PRG:$0BB3 Bytes:C6 01
|
|
DEX ; PRG:$0BB5 Bytes:CA
|
|
BNE CorePathLoop_CBAE ; PRG:$0BB6 Bytes:D0 F6
|
|
RTS ; PRG:$0BB8 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_CBB9
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_CBB9:
|
|
LDA #$00 ; PRG:$0BB9 Bytes:A9 00
|
|
STA $08 ; PRG:$0BBB Bytes:85 08
|
|
LDA #$04 ; PRG:$0BBD Bytes:A9 04
|
|
STA $09 ; PRG:$0BBF Bytes:85 09
|
|
LDA #$00 ; PRG:$0BC1 Bytes:A9 00
|
|
STA $0A ; PRG:$0BC3 Bytes:85 0A
|
|
RTS ; PRG:$0BC5 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_CBC6
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_CBC6:
|
|
LDA #$40 ; PRG:$0BC6 Bytes:A9 40
|
|
STA $08 ; PRG:$0BC8 Bytes:85 08
|
|
LDA #$04 ; PRG:$0BCA Bytes:A9 04
|
|
STA $09 ; PRG:$0BCC Bytes:85 09
|
|
LDA #$01 ; PRG:$0BCE Bytes:A9 01
|
|
STA $0A ; PRG:$0BD0 Bytes:85 0A
|
|
RTS ; PRG:$0BD2 Bytes:60
|
|
;------------------------------------------------------------
|
|
; RunGameTaskRoutine_CBD3
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
RunGameTaskRoutine_CBD3:
|
|
CLC ; PRG:$0BD3 Bytes:18
|
|
LDA #$20 ; PRG:$0BD4 Bytes:A9 20
|
|
ADC $00,X ; PRG:$0BD6 Bytes:75 00
|
|
STA $00,X ; PRG:$0BD8 Bytes:95 00
|
|
LDA #$00 ; PRG:$0BDA Bytes:A9 00
|
|
ADC $01,X ; PRG:$0BDC Bytes:75 01
|
|
STA $01,X ; PRG:$0BDE Bytes:95 01
|
|
DEC $0F ; PRG:$0BE0 Bytes:C6 0F
|
|
RTS ; PRG:$0BE2 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessCurrentObjectRoutine_CBE3
|
|
;
|
|
; Global:
|
|
; First-pass core-game entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Game state, object pointers, and frame state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessCurrentObjectRoutine_CBE3:
|
|
LDY #$10 ; PRG:$0BE3 Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0BE5 Bytes:B1 08
|
|
STA $06 ; PRG:$0BE7 Bytes:85 06
|
|
LDA $06 ; PRG:$0BE9 Bytes:A5 06
|
|
BPL CorePathOnPositive_CBFA ; PRG:$0BEB Bytes:10 0D
|
|
LDX $0A ; PRG:$0BED Bytes:A6 0A
|
|
LDA #$00 ; PRG:$0BEF Bytes:A9 00
|
|
STA $90,X ; PRG:$0BF1 Bytes:95 90
|
|
JSR UpdateObjectBufferRoutine_E468 ; PRG:$0BF3 Bytes:20 68 E4
|
|
JSR ReadObjectRecordRoutine_E539 ; PRG:$0BF6 Bytes:20 39 E5
|
|
RTS ; PRG:$0BF9 Bytes:60
|
|
CorePathOnPositive_CBFA:
|
|
CMP #$30 ; PRG:$0BFA Bytes:C9 30
|
|
BCS CorePathOnCarry_CC23 ; PRG:$0BFC Bytes:B0 25
|
|
JSR ReadObjectRecordRoutine_E06A ; PRG:$0BFE Bytes:20 6A E0
|
|
LDA $0A ; PRG:$0C01 Bytes:A5 0A
|
|
JSR ReadObjectRecordRoutine_E5AA ; PRG:$0C03 Bytes:20 AA E5
|
|
BCS CorePathContinue_CC10 ; PRG:$0C06 Bytes:B0 08
|
|
JSR ProcessObjectStateRoutine_E17F ; PRG:$0C08 Bytes:20 7F E1
|
|
BCC CorePathContinue_CC10 ; PRG:$0C0B Bytes:90 03
|
|
JSR ProcessObjectStateRoutine_E1BF ; PRG:$0C0D Bytes:20 BF E1
|
|
CorePathContinue_CC10:
|
|
JSR PrepareObjectMovementContext ; PRG:$0C10 Bytes:20 A8 CC
|
|
JSR ReadObjectRecordRoutine_E351 ; PRG:$0C13 Bytes:20 51 E3
|
|
BCC CorePathOnNoCarry_CC22 ; PRG:$0C16 Bytes:90 0A
|
|
JSR UpdateObjectRecordRoutine_E3A7 ; PRG:$0C18 Bytes:20 A7 E3
|
|
LDA #$04 ; PRG:$0C1B Bytes:A9 04
|
|
STA $FC ; PRG:$0C1D Bytes:85 FC
|
|
RunGameTaskDispatch_CC1F:
|
|
JSR PrepareObjectMovementContext ; PRG:$0C1F Bytes:20 A8 CC
|
|
CorePathOnNoCarry_CC22:
|
|
RTS ; PRG:$0C22 Bytes:60
|
|
CorePathOnCarry_CC23:
|
|
JSR ProcessObjectStateRoutine_E28F ; PRG:$0C23 Bytes:20 8F E2
|
|
JSR ReadObjectRecordRoutine_E06A ; PRG:$0C26 Bytes:20 6A E0
|
|
JMP RunGameTaskDispatch_CC1F ; PRG:$0C29 Bytes:4C 1F CC
|
|
.byte $00, $00, $02, $02, $00, $00, $00, $00, $02, $02, $02, $02, $00, $80, $40, $00 ; PRG:$0C2C Bytes:00 00 02 02 00 00 00 00 02 02 02 02 00 80 40 00
|
|
.byte $00, $40, $80, $C0 ; PRG:$0C3C Bytes:00 40 80 C0
|
|
|
|
;------------------------------------------------------------
|
|
; Movement tables and object-engine setup
|
|
; CPU $CC40-$CCB7
|
|
; PRG $0C40-$0CB7
|
|
;------------------------------------------------------------
|
|
|
|
MovementTables:
|
|
.byte $00, $80, $40, $C0, $80, $00, $00, $40, $00, $80, $40, $00, $00, $40, $80, $C0 ; PRG:$0C40 Bytes:00 80 40 C0 80 00 00 40 00 80 40 00 00 40 80 C0
|
|
.byte $00, $80, $40, $C0, $C0, $40, $80, $C0, $00, $00, $00, $00, $04, $04, $04, $04 ; PRG:$0C50 Bytes:00 80 40 C0 C0 40 80 C0 00 00 00 00 04 04 04 04
|
|
.byte $10, $F8, $10, $F8, $00, $08, $F8, $F8, $00, $00, $00, $00, $0F, $F9, $0F, $F9 ; PRG:$0C60 Bytes:10 F8 10 F8 00 08 F8 F8 00 00 00 00 0F F9 0F F9
|
|
.byte $04, $04, $04, $04, $F8, $F8, $00, $08, $00, $00, $00, $00, $00, $00, $00, $00 ; PRG:$0C70 Bytes:04 04 04 04 F8 F8 00 08 00 00 00 00 00 00 00 00
|
|
.byte $01, $01, $01, $01, $F8, $10, $04, $04, $F8, $F8, $10, $10, $04, $04, $04, $04 ; PRG:$0C80 Bytes:01 01 01 01 F8 10 04 04 F8 F8 10 10 04 04 04 04
|
|
.byte $00, $08, $10, $10, $04, $04, $F8, $10, $04, $04, $04, $04, $10, $10, $F8, $F8 ; PRG:$0C90 Bytes:00 08 10 10 04 04 F8 10 04 04 04 04 10 10 F8 F8
|
|
.byte $10, $10, $00, $08, $04, $05, $08, $09 ; PRG:$0CA0 Bytes:10 10 00 08 04 05 08 09
|
|
|
|
;------------------------------------------------------------
|
|
; PrepareObjectMovementContext
|
|
;
|
|
; Global:
|
|
; Prepares an index and object-state selector before falling
|
|
; through into ObjectEngineCodeAndTables at CPU $CCB8.
|
|
;
|
|
; Parameters:
|
|
; $06 supplies a two-bit selector.
|
|
;
|
|
; Returns:
|
|
; X = $03 normally, or $0C when the selector is at least two.
|
|
; Y = $10.
|
|
; $00 = $06 & $03.
|
|
;------------------------------------------------------------
|
|
PrepareObjectMovementContext:
|
|
LDX #$03 ; PRG:$0CA8 Bytes:A2 03
|
|
LDA $06 ; PRG:$0CAA Bytes:A5 06
|
|
AND #$03 ; PRG:$0CAC Bytes:29 03
|
|
STA $00 ; PRG:$0CAE Bytes:85 00
|
|
CMP #$02 ; PRG:$0CB0 Bytes:C9 02
|
|
BCC @SetObjectFieldOffset ; PRG:$0CB2 Bytes:90 02
|
|
LDX #$0C ; PRG:$0CB4 Bytes:A2 0C
|
|
@SetObjectFieldOffset:
|
|
LDY #$10 ; PRG:$0CB6 Bytes:A0 10
|
|
|
|
; Falls through to ObjectEngineCodeAndTables at CPU $CCB8.
|
|
|
|
;------------------------------------------------------------
|
|
; Object engine code with embedded lookup tables
|
|
; CPU $CCB8-$E77F
|
|
; PRG $0CB8-$277F
|
|
;
|
|
; Pass 1 recursively traced from verified entry roots in this region.
|
|
; Direct branches, jumps, and subroutine calls are decoded.
|
|
; Bytes not reached by that trace remain explicit .byte data.
|
|
;------------------------------------------------------------
|
|
|
|
;------------------------------------------------------------
|
|
; ObjectEngineCodeAndTables
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectEngineCodeAndTables:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0CB8 Bytes:B1 08
|
|
BMI ObjectPathContinue_CCCC ; PRG:$0CBA Bytes:30 10
|
|
LDY #$1B ; PRG:$0CBC Bytes:A0 1B
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0CBE Bytes:B1 08
|
|
CMP #$50 ; PRG:$0CC0 Bytes:C9 50
|
|
BCS ObjectPathContinue_CCE9 ; PRG:$0CC2 Bytes:B0 25
|
|
CMP #$40 ; PRG:$0CC4 Bytes:C9 40
|
|
BCS ObjectPathContinue_CCCC ; PRG:$0CC6 Bytes:B0 04
|
|
CMP #$30 ; PRG:$0CC8 Bytes:C9 30
|
|
BCS ObjectPathOnCarry_CCEF ; PRG:$0CCA Bytes:B0 23
|
|
ObjectPathContinue_CCCC:
|
|
TXA ; PRG:$0CCC Bytes:8A
|
|
LDY $0A ; PRG:$0CCD Bytes:A4 0A
|
|
AND a:$0046,Y ; PRG:$0CCF Bytes:39 46 00
|
|
BEQ ObjectPathContinue_CCE9 ; PRG:$0CD2 Bytes:F0 15
|
|
JSR ProcessObjectStateRoutine_CD54 ; PRG:$0CD4 Bytes:20 54 CD
|
|
STX $07 ; PRG:$0CD7 Bytes:86 07
|
|
ObjectPathLoop_CCD9:
|
|
JSR UpdateObjectRecordRoutine_CCF7 ; PRG:$0CD9 Bytes:20 F7 CC
|
|
LDA #$00 ; PRG:$0CDC Bytes:A9 00
|
|
UpdateObjectRecordLoop_CCDE:
|
|
LDY #$20 ; PRG:$0CDE Bytes:A0 20
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0CE0 Bytes:91 08
|
|
JSR UpdateObjectRecordRoutine_CD1E ; PRG:$0CE2 Bytes:20 1E CD
|
|
JSR UpdateObjectRecordRoutine_CD45 ; PRG:$0CE5 Bytes:20 45 CD
|
|
RTS ; PRG:$0CE8 Bytes:60
|
|
ObjectPathContinue_CCE9:
|
|
LDX $00 ; PRG:$0CE9 Bytes:A6 00
|
|
LDA #$01 ; PRG:$0CEB Bytes:A9 01
|
|
BNE UpdateObjectRecordLoop_CCDE ; PRG:$0CED Bytes:D0 EF
|
|
ObjectPathOnCarry_CCEF:
|
|
AND #$03 ; PRG:$0CEF Bytes:29 03
|
|
CLC ; PRG:$0CF1 Bytes:18
|
|
ADC #$0C ; PRG:$0CF2 Bytes:69 0C
|
|
TAX ; PRG:$0CF4 Bytes:AA
|
|
BNE ObjectPathLoop_CCD9 ; PRG:$0CF5 Bytes:D0 E2
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_CCF7
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_CCF7:
|
|
CLC ; PRG:$0CF7 Bytes:18
|
|
LDY #$01 ; PRG:$0CF8 Bytes:A0 01
|
|
LDA $CC58,X ; PRG:$0CFA Bytes:BD 58 CC
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0CFD Bytes:71 08
|
|
LDY #$21 ; PRG:$0CFF Bytes:A0 21
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D01 Bytes:91 08
|
|
CLC ; PRG:$0D03 Bytes:18
|
|
LDY #$03 ; PRG:$0D04 Bytes:A0 03
|
|
LDA $CC68,X ; PRG:$0D06 Bytes:BD 68 CC
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0D09 Bytes:71 08
|
|
LDY #$23 ; PRG:$0D0B Bytes:A0 23
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D0D Bytes:91 08
|
|
LDY #$25 ; PRG:$0D0F Bytes:A0 25
|
|
LDA $CC78,X ; PRG:$0D11 Bytes:BD 78 CC
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D14 Bytes:91 08
|
|
LDY #$28 ; PRG:$0D16 Bytes:A0 28
|
|
LDA $CC38,X ; PRG:$0D18 Bytes:BD 38 CC
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D1B Bytes:91 08
|
|
RTS ; PRG:$0D1D Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_CD1E
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_CD1E:
|
|
CLC ; PRG:$0D1E Bytes:18
|
|
LDY #$01 ; PRG:$0D1F Bytes:A0 01
|
|
LDA $CC84,X ; PRG:$0D21 Bytes:BD 84 CC
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0D24 Bytes:71 08
|
|
LDY #$31 ; PRG:$0D26 Bytes:A0 31
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D28 Bytes:91 08
|
|
CLC ; PRG:$0D2A Bytes:18
|
|
LDY #$03 ; PRG:$0D2B Bytes:A0 03
|
|
LDA $CC94,X ; PRG:$0D2D Bytes:BD 94 CC
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0D30 Bytes:71 08
|
|
LDY #$33 ; PRG:$0D32 Bytes:A0 33
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D34 Bytes:91 08
|
|
LDY #$35 ; PRG:$0D36 Bytes:A0 35
|
|
LDA $CC2C,X ; PRG:$0D38 Bytes:BD 2C CC
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D3B Bytes:91 08
|
|
LDY #$38 ; PRG:$0D3D Bytes:A0 38
|
|
LDA $CC48,X ; PRG:$0D3F Bytes:BD 48 CC
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D42 Bytes:91 08
|
|
RTS ; PRG:$0D44 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_CD45
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_CD45:
|
|
LDY #$05 ; PRG:$0D45 Bytes:A0 05
|
|
LDA $CC2C,X ; PRG:$0D47 Bytes:BD 2C CC
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D4A Bytes:91 08
|
|
LDY #$08 ; PRG:$0D4C Bytes:A0 08
|
|
LDA $CC38,X ; PRG:$0D4E Bytes:BD 38 CC
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0D51 Bytes:91 08
|
|
RTS ; PRG:$0D53 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_CD54
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_CD54:
|
|
LDX #$00 ; PRG:$0D54 Bytes:A2 00
|
|
CMP #$04 ; PRG:$0D56 Bytes:C9 04
|
|
BCC ObjectPathOnNoCarry_CD5C ; PRG:$0D58 Bytes:90 02
|
|
LDX #$03 ; PRG:$0D5A Bytes:A2 03
|
|
ObjectPathOnNoCarry_CD5C:
|
|
CPX $00 ; PRG:$0D5C Bytes:E4 00
|
|
BEQ ObjectPathOnZero_CD62 ; PRG:$0D5E Bytes:F0 02
|
|
ORA #$10 ; PRG:$0D60 Bytes:09 10
|
|
ObjectPathOnZero_CD62:
|
|
LDY #$FF ; PRG:$0D62 Bytes:A0 FF
|
|
ObjectPathLoop_CD64:
|
|
LSR A ; PRG:$0D64 Bytes:4A
|
|
INY ; PRG:$0D65 Bytes:C8
|
|
BCC ObjectPathLoop_CD64 ; PRG:$0D66 Bytes:90 FC
|
|
LDX $CCA4,Y ; PRG:$0D68 Bytes:BE A4 CC
|
|
TAY ; PRG:$0D6B Bytes:A8
|
|
BEQ ObjectPathOnZero_CD70 ; PRG:$0D6C Bytes:F0 02
|
|
INX ; PRG:$0D6E Bytes:E8
|
|
INX ; PRG:$0D6F Bytes:E8
|
|
ObjectPathOnZero_CD70:
|
|
RTS ; PRG:$0D70 Bytes:60
|
|
.byte $21, $24, $24, $12, $24, $24, $71, $74, $CD, $CD ; PRG:$0D71 Bytes:21 24 24 12 24 24 71 74 CD CD
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecord_CD7B
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecord_CD7B:
|
|
LDX $0A ; PRG:$0D7B Bytes:A6 0A
|
|
LDA $5A,X ; PRG:$0D7D Bytes:B5 5A
|
|
BNE ObjectPathContinue_CDCD ; PRG:$0D7F Bytes:D0 4C
|
|
CLC ; PRG:$0D81 Bytes:18
|
|
LDY #$01 ; PRG:$0D82 Bytes:A0 01
|
|
LDA #$06 ; PRG:$0D84 Bytes:A9 06
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0D86 Bytes:71 08
|
|
STA $00 ; PRG:$0D88 Bytes:85 00
|
|
CLC ; PRG:$0D8A Bytes:18
|
|
LDY #$03 ; PRG:$0D8B Bytes:A0 03
|
|
LDA #$06 ; PRG:$0D8D Bytes:A9 06
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0D8F Bytes:71 08
|
|
STA $01 ; PRG:$0D91 Bytes:85 01
|
|
JSR UpdateObjectBufferRoutine_E0DF ; PRG:$0D93 Bytes:20 DF E0
|
|
LDA $0A ; PRG:$0D96 Bytes:A5 0A
|
|
CLC ; PRG:$0D98 Bytes:18
|
|
ADC #$04 ; PRG:$0D99 Bytes:69 04
|
|
JSR ProcessObjectStateRoutine_E0B2 ; PRG:$0D9B Bytes:20 B2 E0
|
|
BCS ObjectPathContinue_CDCD ; PRG:$0D9E Bytes:B0 2D
|
|
LDY #$00 ; PRG:$0DA0 Bytes:A0 00
|
|
LDX #$80 ; PRG:$0DA2 Bytes:A2 80
|
|
CMP #$FB ; PRG:$0DA4 Bytes:C9 FB
|
|
BEQ ObjectPathContinue_CDCE ; PRG:$0DA6 Bytes:F0 26
|
|
INY ; PRG:$0DA8 Bytes:C8
|
|
CMP #$FA ; PRG:$0DA9 Bytes:C9 FA
|
|
BEQ ObjectPathContinue_CDCE ; PRG:$0DAB Bytes:F0 21
|
|
DEY ; PRG:$0DAD Bytes:88
|
|
LDX #$00 ; PRG:$0DAE Bytes:A2 00
|
|
CMP #$D2 ; PRG:$0DB0 Bytes:C9 D2
|
|
BCS ObjectPathOnCarry_CDBE ; PRG:$0DB2 Bytes:B0 0A
|
|
CMP #$D0 ; PRG:$0DB4 Bytes:C9 D0
|
|
BCS ObjectPathContinue_CDCE ; PRG:$0DB6 Bytes:B0 16
|
|
INY ; PRG:$0DB8 Bytes:C8
|
|
CMP #$CE ; PRG:$0DB9 Bytes:C9 CE
|
|
BCS ObjectPathContinue_CDCE ; PRG:$0DBB Bytes:B0 11
|
|
DEY ; PRG:$0DBD Bytes:88
|
|
ObjectPathOnCarry_CDBE:
|
|
LDX #$04 ; PRG:$0DBE Bytes:A2 04
|
|
CMP #$F9 ; PRG:$0DC0 Bytes:C9 F9
|
|
BCS ObjectPathContinue_CDCD ; PRG:$0DC2 Bytes:B0 09
|
|
CMP #$F7 ; PRG:$0DC4 Bytes:C9 F7
|
|
BCS ObjectPathContinue_CDCE ; PRG:$0DC6 Bytes:B0 06
|
|
INY ; PRG:$0DC8 Bytes:C8
|
|
CMP #$F5 ; PRG:$0DC9 Bytes:C9 F5
|
|
BCS ObjectPathContinue_CDCE ; PRG:$0DCB Bytes:B0 01
|
|
ObjectPathContinue_CDCD:
|
|
RTS ; PRG:$0DCD Bytes:60
|
|
ObjectPathContinue_CDCE:
|
|
STY $0D ; PRG:$0DCE Bytes:84 0D
|
|
STX $0E ; PRG:$0DD0 Bytes:86 0E
|
|
LDX $0A ; PRG:$0DD2 Bytes:A6 0A
|
|
LDA #$08 ; PRG:$0DD4 Bytes:A9 08
|
|
STA $5A,X ; PRG:$0DD6 Bytes:95 5A
|
|
LDX #$01 ; PRG:$0DD8 Bytes:A2 01
|
|
LDA $8F ; PRG:$0DDA Bytes:A5 8F
|
|
BNE UpdateObjectBufferContinue_CDE4 ; PRG:$0DDC Bytes:D0 06
|
|
LDA $0E ; PRG:$0DDE Bytes:A5 0E
|
|
BPL UpdateObjectBufferContinue_CDE4 ; PRG:$0DE0 Bytes:10 02
|
|
LDX #$28 ; PRG:$0DE2 Bytes:A2 28
|
|
UpdateObjectBufferContinue_CDE4:
|
|
STX $07 ; PRG:$0DE4 Bytes:86 07
|
|
JSR ProcessObjectStateRoutine_CE50 ; PRG:$0DE6 Bytes:20 50 CE
|
|
BCS ObjectPathContinue_CE33 ; PRG:$0DE9 Bytes:B0 48
|
|
LDA WorkPtr1Lo ; PRG:$0DEB Bytes:A5 02
|
|
STA $01 ; PRG:$0DED Bytes:85 01
|
|
LDA $03 ; PRG:$0DEF Bytes:A5 03
|
|
STA $00 ; PRG:$0DF1 Bytes:85 00
|
|
LDY $0D ; PRG:$0DF3 Bytes:A4 0D
|
|
LDA $CD77,Y ; PRG:$0DF5 Bytes:B9 77 CD
|
|
STA $02 ; PRG:$0DF8 Bytes:85 02
|
|
LDA $CD79,Y ; PRG:$0DFA Bytes:B9 79 CD
|
|
STA $03 ; PRG:$0DFD Bytes:85 03
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$0DFF Bytes:20 A1 F3
|
|
LDA #$80 ; PRG:$0E02 Bytes:A9 80
|
|
STA $FF ; PRG:$0E04 Bytes:85 FF
|
|
LDX $0A ; PRG:$0E06 Bytes:A6 0A
|
|
LDA #$01 ; PRG:$0E08 Bytes:A9 01
|
|
STA $00 ; PRG:$0E0A Bytes:85 00
|
|
LDA $0E ; PRG:$0E0C Bytes:A5 0E
|
|
CMP #$04 ; PRG:$0E0E Bytes:C9 04
|
|
BEQ ObjectPathOnZero_CE34 ; PRG:$0E10 Bytes:F0 22
|
|
INC $D4,X ; PRG:$0E12 Bytes:F6 D4
|
|
LDA #$06 ; PRG:$0E14 Bytes:A9 06
|
|
STA $01 ; PRG:$0E16 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F408 ; PRG:$0E18 Bytes:20 08 F4
|
|
LDA $3F ; PRG:$0E1B Bytes:A5 3F
|
|
BNE ProcessObjectStateDispatch_CE2A ; PRG:$0E1D Bytes:D0 0B
|
|
LDA $8D ; PRG:$0E1F Bytes:A5 8D
|
|
BEQ ObjectPathOnZero_CE26 ; PRG:$0E21 Bytes:F0 03
|
|
JMP RunGameTaskRoutine_C3E4 ; PRG:$0E23 Bytes:4C E4 C3
|
|
ObjectPathOnZero_CE26:
|
|
LDA #$23 ; PRG:$0E26 Bytes:A9 23
|
|
STA $78 ; PRG:$0E28 Bytes:85 78
|
|
ProcessObjectStateDispatch_CE2A:
|
|
LDA $8F ; PRG:$0E2A Bytes:A5 8F
|
|
BNE ObjectPathContinue_CE33 ; PRG:$0E2C Bytes:D0 05
|
|
LDA #$68 ; PRG:$0E2E Bytes:A9 68
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$0E30 Bytes:20 1A F3
|
|
ObjectPathContinue_CE33:
|
|
RTS ; PRG:$0E33 Bytes:60
|
|
ObjectPathOnZero_CE34:
|
|
LDA $8E ; PRG:$0E34 Bytes:A5 8E
|
|
BEQ ObjectPathOnZero_CE41 ; PRG:$0E36 Bytes:F0 09
|
|
DEC $D4,X ; PRG:$0E38 Bytes:D6 D4
|
|
LDA #$06 ; PRG:$0E3A Bytes:A9 06
|
|
STA $01 ; PRG:$0E3C Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$0E3E Bytes:20 0C F4
|
|
ObjectPathOnZero_CE41:
|
|
JMP ProcessObjectStateDispatch_CE2A ; PRG:$0E41 Bytes:4C 2A CE
|
|
.byte $21, $00, $00, $10, $08, $12, $00, $00, $08, $10, $40, $80 ; PRG:$0E44 Bytes:21 00 00 10 08 12 00 00 08 10 40 80
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_CE50
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_CE50:
|
|
LDA #$00 ; PRG:$0E50 Bytes:A9 00
|
|
STA $04 ; PRG:$0E52 Bytes:85 04
|
|
STA $0B ; PRG:$0E54 Bytes:85 0B
|
|
LDA #$05 ; PRG:$0E56 Bytes:A9 05
|
|
STA $05 ; PRG:$0E58 Bytes:85 05
|
|
STA $0C ; PRG:$0E5A Bytes:85 0C
|
|
LDA #$07 ; PRG:$0E5C Bytes:A9 07
|
|
STA $0F ; PRG:$0E5E Bytes:85 0F
|
|
ObjectPathLoop_CE60:
|
|
LDY #$10 ; PRG:$0E60 Bytes:A0 10
|
|
LDA ($04),Y ; PRG:$0E62 Bytes:B1 04
|
|
BEQ ObjectPathOnZero_CE6F ; PRG:$0E64 Bytes:F0 09
|
|
LDX #$04 ; PRG:$0E66 Bytes:A2 04
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$0E68 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_CE60 ; PRG:$0E6B Bytes:10 F3
|
|
ObjectPathLoop_CE6D:
|
|
SEC ; PRG:$0E6D Bytes:38
|
|
RTS ; PRG:$0E6E Bytes:60
|
|
ObjectPathOnZero_CE6F:
|
|
LDA WorkPtr1Lo ; PRG:$0E6F Bytes:A5 02
|
|
BEQ ObjectPathOnZero_CE9D ; PRG:$0E71 Bytes:F0 2A
|
|
JSR UpdateObjectBufferRoutine_E0F9 ; PRG:$0E73 Bytes:20 F9 E0
|
|
LDA #$07 ; PRG:$0E76 Bytes:A9 07
|
|
STA $0F ; PRG:$0E78 Bytes:85 0F
|
|
ObjectPathLoop_CE7A:
|
|
LDY #$10 ; PRG:$0E7A Bytes:A0 10
|
|
LDA ($0B),Y ; PRG:$0E7C Bytes:B1 0B
|
|
BEQ ObjectPathContinue_CE96 ; PRG:$0E7E Bytes:F0 16
|
|
LDY #$12 ; PRG:$0E80 Bytes:A0 12
|
|
LDA ($0B),Y ; PRG:$0E82 Bytes:B1 0B
|
|
BEQ ObjectPathContinue_CE96 ; PRG:$0E84 Bytes:F0 10
|
|
LDY #$01 ; PRG:$0E86 Bytes:A0 01
|
|
LDA ($0B),Y ; PRG:$0E88 Bytes:B1 0B
|
|
CMP $00 ; PRG:$0E8A Bytes:C5 00
|
|
BNE ObjectPathContinue_CE96 ; PRG:$0E8C Bytes:D0 08
|
|
LDY #$03 ; PRG:$0E8E Bytes:A0 03
|
|
LDA ($0B),Y ; PRG:$0E90 Bytes:B1 0B
|
|
CMP $01 ; PRG:$0E92 Bytes:C5 01
|
|
BEQ ObjectPathLoop_CE6D ; PRG:$0E94 Bytes:F0 D7
|
|
ObjectPathContinue_CE96:
|
|
LDX #$0B ; PRG:$0E96 Bytes:A2 0B
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$0E98 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_CE7A ; PRG:$0E9B Bytes:10 DD
|
|
ObjectPathOnZero_CE9D:
|
|
LDY #$00 ; PRG:$0E9D Bytes:A0 00
|
|
LDA #$00 ; PRG:$0E9F Bytes:A9 00
|
|
STA ($04),Y ; PRG:$0EA1 Bytes:91 04
|
|
INY ; PRG:$0EA3 Bytes:C8
|
|
LDA WorkPtr0Lo ; PRG:$0EA4 Bytes:A5 00
|
|
STA ($04),Y ; PRG:$0EA6 Bytes:91 04
|
|
INY ; PRG:$0EA8 Bytes:C8
|
|
LDA #$00 ; PRG:$0EA9 Bytes:A9 00
|
|
STA ($04),Y ; PRG:$0EAB Bytes:91 04
|
|
INY ; PRG:$0EAD Bytes:C8
|
|
LDA WorkPtr0Hi ; PRG:$0EAE Bytes:A5 01
|
|
STA ($04),Y ; PRG:$0EB0 Bytes:91 04
|
|
INY ; PRG:$0EB2 Bytes:C8
|
|
LDA #$00 ; PRG:$0EB3 Bytes:A9 00
|
|
STA ($04),Y ; PRG:$0EB5 Bytes:91 04
|
|
LDY #$14 ; PRG:$0EB7 Bytes:A0 14
|
|
LDA $0E ; PRG:$0EB9 Bytes:A5 0E
|
|
STA ($04),Y ; PRG:$0EBB Bytes:91 04
|
|
AND #$0F ; PRG:$0EBD Bytes:29 0F
|
|
LDX #$00 ; PRG:$0EBF Bytes:A2 00
|
|
LDY $0D ; PRG:$0EC1 Bytes:A4 0D
|
|
BEQ ObjectPathOnZero_CECA ; PRG:$0EC3 Bytes:F0 05
|
|
CLC ; PRG:$0EC5 Bytes:18
|
|
ADC #$0A ; PRG:$0EC6 Bytes:69 0A
|
|
LDX #$05 ; PRG:$0EC8 Bytes:A2 05
|
|
ObjectPathOnZero_CECA:
|
|
LDY #$05 ; PRG:$0ECA Bytes:A0 05
|
|
STA ($04),Y ; PRG:$0ECC Bytes:91 04
|
|
LDY #$0A ; PRG:$0ECE Bytes:A0 0A
|
|
LDA $CE44,X ; PRG:$0ED0 Bytes:BD 44 CE
|
|
STA ($04),Y ; PRG:$0ED3 Bytes:91 04
|
|
LDY #$0C ; PRG:$0ED5 Bytes:A0 0C
|
|
ObjectPathLoop_CED7:
|
|
INX ; PRG:$0ED7 Bytes:E8
|
|
LDA $CE44,X ; PRG:$0ED8 Bytes:BD 44 CE
|
|
STA ($04),Y ; PRG:$0EDB Bytes:91 04
|
|
INY ; PRG:$0EDD Bytes:C8
|
|
CPY #$10 ; PRG:$0EDE Bytes:C0 10
|
|
BNE ObjectPathLoop_CED7 ; PRG:$0EE0 Bytes:D0 F5
|
|
LDY #$10 ; PRG:$0EE2 Bytes:A0 10
|
|
LDA $08 ; PRG:$0EE4 Bytes:A5 08
|
|
STA $00 ; PRG:$0EE6 Bytes:85 00
|
|
LDA $09 ; PRG:$0EE8 Bytes:A5 09
|
|
STA $01 ; PRG:$0EEA Bytes:85 01
|
|
JSR ProcessObjectStateRoutine_D94D ; PRG:$0EEC Bytes:20 4D D9
|
|
ORA #$10 ; PRG:$0EEF Bytes:09 10
|
|
STA ($04),Y ; PRG:$0EF1 Bytes:91 04
|
|
AND #$01 ; PRG:$0EF3 Bytes:29 01
|
|
BEQ ObjectPathContinue_CF02 ; PRG:$0EF5 Bytes:F0 0B
|
|
LDA #$00 ; PRG:$0EF7 Bytes:A9 00
|
|
LDY $02 ; PRG:$0EF9 Bytes:A4 02
|
|
BNE ObjectPathContinue_CF02 ; PRG:$0EFB Bytes:D0 05
|
|
LDY $0D ; PRG:$0EFD Bytes:A4 0D
|
|
LDA $CE4E,Y ; PRG:$0EFF Bytes:B9 4E CE
|
|
ObjectPathContinue_CF02:
|
|
LDY #$08 ; PRG:$0F02 Bytes:A0 08
|
|
STA ($04),Y ; PRG:$0F04 Bytes:91 04
|
|
LDY #$11 ; PRG:$0F06 Bytes:A0 11
|
|
LDA $07 ; PRG:$0F08 Bytes:A5 07
|
|
STA ($04),Y ; PRG:$0F0A Bytes:91 04
|
|
LDA WorkPtr1Lo ; PRG:$0F0C Bytes:A5 02
|
|
BEQ ObjectPathContinue_CF1E ; PRG:$0F0E Bytes:F0 0E
|
|
LDA #$0D ; PRG:$0F10 Bytes:A9 0D
|
|
LDX $8E ; PRG:$0F12 Bytes:A6 8E
|
|
BNE ObjectPathContinue_CF1E ; PRG:$0F14 Bytes:D0 08
|
|
LDX $0E ; PRG:$0F16 Bytes:A6 0E
|
|
CPX #$04 ; PRG:$0F18 Bytes:E0 04
|
|
BNE ObjectPathContinue_CF1E ; PRG:$0F1A Bytes:D0 02
|
|
LDA #$09 ; PRG:$0F1C Bytes:A9 09
|
|
ObjectPathContinue_CF1E:
|
|
INY ; PRG:$0F1E Bytes:C8
|
|
STA ($04),Y ; PRG:$0F1F Bytes:91 04
|
|
INY ; PRG:$0F21 Bytes:C8
|
|
LDA #$02 ; PRG:$0F22 Bytes:A9 02
|
|
STA ($04),Y ; PRG:$0F24 Bytes:91 04
|
|
CLC ; PRG:$0F26 Bytes:18
|
|
RTS ; PRG:$0F27 Bytes:60
|
|
.byte $21, $D0, $D1, $12, $CE, $CF, $21, $F7, $F8, $12, $F5, $F6, $02, $FD, $02, $FD ; PRG:$0F28 Bytes:21 D0 D1 12 CE CF 21 F7 F8 12 F5 F6 02 FD 02 FD
|
|
.byte $60, $A0, $60, $A0 ; PRG:$0F38 Bytes:60 A0 60 A0
|
|
ReadObjectRecordDispatch_CF3C:
|
|
LDY #$01 ; PRG:$0F3C Bytes:A0 01
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0F3E Bytes:B1 08
|
|
STA WorkPtr0Lo ; PRG:$0F40 Bytes:85 00
|
|
LDY #$03 ; PRG:$0F42 Bytes:A0 03
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0F44 Bytes:B1 08
|
|
STA WorkPtr0Hi ; PRG:$0F46 Bytes:85 01
|
|
JSR UpdateObjectBufferRoutine_E0DF ; PRG:$0F48 Bytes:20 DF E0
|
|
LDY #$05 ; PRG:$0F4B Bytes:A0 05
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0F4D Bytes:B1 08
|
|
LDX #$28 ; PRG:$0F4F Bytes:A2 28
|
|
LDY #$CF ; PRG:$0F51 Bytes:A0 CF
|
|
CMP #$00 ; PRG:$0F53 Bytes:C9 00
|
|
BEQ UpdateObjectRecordOnZero_CF6B ; PRG:$0F55 Bytes:F0 14
|
|
LDX #$2B ; PRG:$0F57 Bytes:A2 2B
|
|
LDY #$CF ; PRG:$0F59 Bytes:A0 CF
|
|
CMP #$0A ; PRG:$0F5B Bytes:C9 0A
|
|
BEQ UpdateObjectRecordOnZero_CF6B ; PRG:$0F5D Bytes:F0 0C
|
|
LDX #$2E ; PRG:$0F5F Bytes:A2 2E
|
|
LDY #$CF ; PRG:$0F61 Bytes:A0 CF
|
|
CMP #$04 ; PRG:$0F63 Bytes:C9 04
|
|
BEQ UpdateObjectRecordOnZero_CF6B ; PRG:$0F65 Bytes:F0 04
|
|
LDX #$31 ; PRG:$0F67 Bytes:A2 31
|
|
LDY #$CF ; PRG:$0F69 Bytes:A0 CF
|
|
UpdateObjectRecordOnZero_CF6B:
|
|
LDA WorkPtr1Lo ; PRG:$0F6B Bytes:A5 02
|
|
STA WorkPtr0Hi ; PRG:$0F6D Bytes:85 01
|
|
LDA WorkPtr1Hi ; PRG:$0F6F Bytes:A5 03
|
|
STA WorkPtr0Lo ; PRG:$0F71 Bytes:85 00
|
|
STX WorkPtr1Lo ; PRG:$0F73 Bytes:86 02
|
|
STY WorkPtr1Hi ; PRG:$0F75 Bytes:84 03
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$0F77 Bytes:20 A1 F3
|
|
LDY #$05 ; PRG:$0F7A Bytes:A0 05
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0F7C Bytes:B1 08
|
|
CMP #$05 ; PRG:$0F7E Bytes:C9 05
|
|
LDA #$14 ; PRG:$0F80 Bytes:A9 14
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0F82 Bytes:91 08
|
|
BCS UpdateObjectRecordOnCarry_CF96 ; PRG:$0F84 Bytes:B0 10
|
|
LDY #$01 ; PRG:$0F86 Bytes:A0 01
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0F88 Bytes:B1 08
|
|
ADC #$04 ; PRG:$0F8A Bytes:69 04
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0F8C Bytes:91 08
|
|
LDY #$03 ; PRG:$0F8E Bytes:A0 03
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0F90 Bytes:B1 08
|
|
SBC #$03 ; PRG:$0F92 Bytes:E9 03
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0F94 Bytes:91 08
|
|
UpdateObjectRecordOnCarry_CF96:
|
|
LDY #$0A ; PRG:$0F96 Bytes:A0 0A
|
|
LDA #$12 ; PRG:$0F98 Bytes:A9 12
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0F9A Bytes:91 08
|
|
BNE UpdateObjectRecordLoop_CFAD ; PRG:$0F9C Bytes:D0 0F
|
|
ObjectPathLoop_CF9E:
|
|
JMP ReadObjectRecordDispatch_CF3C ; PRG:$0F9E Bytes:4C 3C CF
|
|
;------------------------------------------------------------
|
|
; ObjectPath_CFA1
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_CFA1:
|
|
LDA #$00 ; PRG:$0FA1 Bytes:A9 00
|
|
STA CurrentObjectPtrLo ; PRG:$0FA3 Bytes:85 08
|
|
LDA #$05 ; PRG:$0FA5 Bytes:A9 05
|
|
STA CurrentObjectPtrHi ; PRG:$0FA7 Bytes:85 09
|
|
LDA #$07 ; PRG:$0FA9 Bytes:A9 07
|
|
STA LoopCounter ; PRG:$0FAB Bytes:85 0F
|
|
UpdateObjectRecordLoop_CFAD:
|
|
LDY #$10 ; PRG:$0FAD Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0FAF Bytes:B1 08
|
|
BEQ ProcessObjectStateDispatch_CFFA ; PRG:$0FB1 Bytes:F0 47
|
|
STA WorkPtr0Lo ; PRG:$0FB3 Bytes:85 00
|
|
LDY #$12 ; PRG:$0FB5 Bytes:A0 12
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0FB7 Bytes:B1 08
|
|
BEQ UpdateObjectRecordOnZero_D004 ; PRG:$0FB9 Bytes:F0 49
|
|
INY ; PRG:$0FBB Bytes:C8
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0FBC Bytes:B1 08
|
|
SEC ; PRG:$0FBE Bytes:38
|
|
SBC #$01 ; PRG:$0FBF Bytes:E9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0FC1 Bytes:91 08
|
|
BNE ProcessObjectStateDispatch_CFFA ; PRG:$0FC3 Bytes:D0 35
|
|
LDA #$03 ; PRG:$0FC5 Bytes:A9 03
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0FC7 Bytes:91 08
|
|
DEY ; PRG:$0FC9 Bytes:88
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$0FCA Bytes:B1 08
|
|
SEC ; PRG:$0FCC Bytes:38
|
|
SBC #$01 ; PRG:$0FCD Bytes:E9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0FCF Bytes:91 08
|
|
BEQ ObjectPathLoop_CF9E ; PRG:$0FD1 Bytes:F0 CB
|
|
LDA WorkPtr0Lo ; PRG:$0FD3 Bytes:A5 00
|
|
AND #$01 ; PRG:$0FD5 Bytes:29 01
|
|
BNE ReadObjectRecordOnNonZero_CFDB ; PRG:$0FD7 Bytes:D0 02
|
|
LDA #$FF ; PRG:$0FD9 Bytes:A9 FF
|
|
ReadObjectRecordOnNonZero_CFDB:
|
|
LDX #$07 ; PRG:$0FDB Bytes:A2 07
|
|
LDY #$05 ; PRG:$0FDD Bytes:A0 05
|
|
CLC ; PRG:$0FDF Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$0FE0 Bytes:71 08
|
|
BMI UpdateObjectRecordContinue_CFF7 ; PRG:$0FE2 Bytes:30 13
|
|
LDX #$00 ; PRG:$0FE4 Bytes:A2 00
|
|
CMP #$08 ; PRG:$0FE6 Bytes:C9 08
|
|
BEQ UpdateObjectRecordContinue_CFF7 ; PRG:$0FE8 Bytes:F0 0D
|
|
LDX #$11 ; PRG:$0FEA Bytes:A2 11
|
|
CMP #$09 ; PRG:$0FEC Bytes:C9 09
|
|
BEQ UpdateObjectRecordContinue_CFF7 ; PRG:$0FEE Bytes:F0 07
|
|
LDX #$0A ; PRG:$0FF0 Bytes:A2 0A
|
|
CMP #$12 ; PRG:$0FF2 Bytes:C9 12
|
|
BEQ UpdateObjectRecordContinue_CFF7 ; PRG:$0FF4 Bytes:F0 01
|
|
TAX ; PRG:$0FF6 Bytes:AA
|
|
UpdateObjectRecordContinue_CFF7:
|
|
TXA ; PRG:$0FF7 Bytes:8A
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$0FF8 Bytes:91 08
|
|
ProcessObjectStateDispatch_CFFA:
|
|
LDX #$08 ; PRG:$0FFA Bytes:A2 08
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$0FFC Bytes:20 D3 CB
|
|
BPL UpdateObjectRecordLoop_CFAD ; PRG:$0FFF Bytes:10 AC
|
|
DEC $A5 ; PRG:$1001 Bytes:C6 A5
|
|
RTS ; PRG:$1003 Bytes:60
|
|
UpdateObjectRecordOnZero_D004:
|
|
DEY ; PRG:$1004 Bytes:88
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1005 Bytes:B1 08
|
|
SEC ; PRG:$1007 Bytes:38
|
|
SBC #$01 ; PRG:$1008 Bytes:E9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$100A Bytes:91 08
|
|
BEQ UpdateObjectRecordOnZero_D052 ; PRG:$100C Bytes:F0 44
|
|
CMP #$23 ; PRG:$100E Bytes:C9 23
|
|
BCS UpdateObjectRecordOnCarry_D01A ; PRG:$1010 Bytes:B0 08
|
|
LDY #$05 ; PRG:$1012 Bytes:A0 05
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1014 Bytes:B1 08
|
|
CMP #$14 ; PRG:$1016 Bytes:C9 14
|
|
BCS ProcessObjectStateDispatch_D04F ; PRG:$1018 Bytes:B0 35
|
|
UpdateObjectRecordOnCarry_D01A:
|
|
LDA WorkPtr0Lo ; PRG:$101A Bytes:A5 00
|
|
AND #$03 ; PRG:$101C Bytes:29 03
|
|
TAX ; PRG:$101E Bytes:AA
|
|
LDY $E17B,X ; PRG:$101F Bytes:BC 7B E1
|
|
INY ; PRG:$1022 Bytes:C8
|
|
CLC ; PRG:$1023 Bytes:18
|
|
LDA $CF38,X ; PRG:$1024 Bytes:BD 38 CF
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$1027 Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1029 Bytes:91 08
|
|
DEY ; PRG:$102B Bytes:88
|
|
LDA $CF34,X ; PRG:$102C Bytes:BD 34 CF
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$102F Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1031 Bytes:91 08
|
|
LDY #$05 ; PRG:$1033 Bytes:A0 05
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1035 Bytes:B1 08
|
|
CMP #$14 ; PRG:$1037 Bytes:C9 14
|
|
BCS ProcessObjectStateDispatch_D04F ; PRG:$1039 Bytes:B0 14
|
|
LDX #$08 ; PRG:$103B Bytes:A2 08
|
|
LDA WorkPtr0Lo ; PRG:$103D Bytes:A5 00
|
|
AND #$02 ; PRG:$103F Bytes:29 02
|
|
BNE ObjectPathOnNonZero_D045 ; PRG:$1041 Bytes:D0 02
|
|
LDX #$12 ; PRG:$1043 Bytes:A2 12
|
|
ObjectPathOnNonZero_D045:
|
|
LDA $A5 ; PRG:$1045 Bytes:A5 A5
|
|
AND #$01 ; PRG:$1047 Bytes:29 01
|
|
BEQ UpdateObjectRecordOnZero_D04C ; PRG:$1049 Bytes:F0 01
|
|
INX ; PRG:$104B Bytes:E8
|
|
UpdateObjectRecordOnZero_D04C:
|
|
TXA ; PRG:$104C Bytes:8A
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$104D Bytes:91 08
|
|
ProcessObjectStateDispatch_D04F:
|
|
JMP ProcessObjectStateDispatch_CFFA ; PRG:$104F Bytes:4C FA CF
|
|
UpdateObjectRecordOnZero_D052:
|
|
DEY ; PRG:$1052 Bytes:88
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1053 Bytes:91 08
|
|
LDY #$00 ; PRG:$1055 Bytes:A0 00
|
|
LDA #$01 ; PRG:$1057 Bytes:A9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1059 Bytes:91 08
|
|
LDY #$05 ; PRG:$105B Bytes:A0 05
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$105D Bytes:B1 08
|
|
CMP #$14 ; PRG:$105F Bytes:C9 14
|
|
BCS ProcessObjectStateDispatch_D04F ; PRG:$1061 Bytes:B0 EC
|
|
LDY #$15 ; PRG:$1063 Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1065 Bytes:B1 08
|
|
TAX ; PRG:$1067 Bytes:AA
|
|
DEC $DA,X ; PRG:$1068 Bytes:D6 DA
|
|
JMP ProcessObjectStateDispatch_D04F ; PRG:$106A Bytes:4C 4F D0
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D06D
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D06D:
|
|
LDA #$20 ; PRG:$106D Bytes:A9 20
|
|
STA $00 ; PRG:$106F Bytes:85 00
|
|
LDA #$04 ; PRG:$1071 Bytes:A9 04
|
|
STA $01 ; PRG:$1073 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$1075 Bytes:20 01 F6
|
|
LDA #$30 ; PRG:$1078 Bytes:A9 30
|
|
STA $00 ; PRG:$107A Bytes:85 00
|
|
LDA #$04 ; PRG:$107C Bytes:A9 04
|
|
STA $01 ; PRG:$107E Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$1080 Bytes:20 01 F6
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D083
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D083:
|
|
LDA #$00 ; PRG:$1083 Bytes:A9 00
|
|
STA $00 ; PRG:$1085 Bytes:85 00
|
|
LDA #$04 ; PRG:$1087 Bytes:A9 04
|
|
STA $01 ; PRG:$1089 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$108B Bytes:20 01 F6
|
|
RTS ; PRG:$108E Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D08F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D08F:
|
|
LDA #$60 ; PRG:$108F Bytes:A9 60
|
|
STA $00 ; PRG:$1091 Bytes:85 00
|
|
LDA #$04 ; PRG:$1093 Bytes:A9 04
|
|
STA $01 ; PRG:$1095 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$1097 Bytes:20 01 F6
|
|
LDA #$70 ; PRG:$109A Bytes:A9 70
|
|
STA $00 ; PRG:$109C Bytes:85 00
|
|
LDA #$04 ; PRG:$109E Bytes:A9 04
|
|
STA $01 ; PRG:$10A0 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$10A2 Bytes:20 01 F6
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D0A5
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D0A5:
|
|
LDA #$40 ; PRG:$10A5 Bytes:A9 40
|
|
STA $00 ; PRG:$10A7 Bytes:85 00
|
|
LDA #$04 ; PRG:$10A9 Bytes:A9 04
|
|
STA $01 ; PRG:$10AB Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$10AD Bytes:20 01 F6
|
|
RTS ; PRG:$10B0 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D0B1
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D0B1:
|
|
LDA #$00 ; PRG:$10B1 Bytes:A9 00
|
|
STA $00 ; PRG:$10B3 Bytes:85 00
|
|
LDA #$05 ; PRG:$10B5 Bytes:A9 05
|
|
STA $01 ; PRG:$10B7 Bytes:85 01
|
|
LDA #$07 ; PRG:$10B9 Bytes:A9 07
|
|
STA $0F ; PRG:$10BB Bytes:85 0F
|
|
ObjectPathLoop_D0BD:
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$10BD Bytes:20 01 F6
|
|
LDX #$00 ; PRG:$10C0 Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$10C2 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_D0BD ; PRG:$10C5 Bytes:10 F6
|
|
RTS ; PRG:$10C7 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_D0C8
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_D0C8:
|
|
LDA #$80 ; PRG:$10C8 Bytes:A9 80
|
|
STA $00 ; PRG:$10CA Bytes:85 00
|
|
LDA #$04 ; PRG:$10CC Bytes:A9 04
|
|
STA $01 ; PRG:$10CE Bytes:85 01
|
|
LDA #$03 ; PRG:$10D0 Bytes:A9 03
|
|
STA $0F ; PRG:$10D2 Bytes:85 0F
|
|
ObjectPathLoop_D0D4:
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$10D4 Bytes:20 01 F6
|
|
LDX #$00 ; PRG:$10D7 Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$10D9 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_D0D4 ; PRG:$10DC Bytes:10 F6
|
|
RTS ; PRG:$10DE Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D0DF
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D0DF:
|
|
LDA #$00 ; PRG:$10DF Bytes:A9 00
|
|
STA $00 ; PRG:$10E1 Bytes:85 00
|
|
LDA #$06 ; PRG:$10E3 Bytes:A9 06
|
|
STA $01 ; PRG:$10E5 Bytes:85 01
|
|
LDA #$07 ; PRG:$10E7 Bytes:A9 07
|
|
STA $0F ; PRG:$10E9 Bytes:85 0F
|
|
ObjectPathLoop_D0EB:
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$10EB Bytes:20 01 F6
|
|
LDX #$00 ; PRG:$10EE Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$10F0 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_D0EB ; PRG:$10F3 Bytes:10 F6
|
|
RTS ; PRG:$10F5 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_D0F6
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_D0F6:
|
|
LDA #$C0 ; PRG:$10F6 Bytes:A9 C0
|
|
STA $00 ; PRG:$10F8 Bytes:85 00
|
|
LDA #$03 ; PRG:$10FA Bytes:A9 03
|
|
STA $01 ; PRG:$10FC Bytes:85 01
|
|
LDA #$02 ; PRG:$10FE Bytes:A9 02
|
|
STA $0F ; PRG:$1100 Bytes:85 0F
|
|
ObjectPathLoop_D102:
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$1102 Bytes:20 01 F6
|
|
JSR ProcessObjectStateRoutine_DDB2 ; PRG:$1105 Bytes:20 B2 DD
|
|
DEC $0F ; PRG:$1108 Bytes:C6 0F
|
|
BPL ObjectPathLoop_D102 ; PRG:$110A Bytes:10 F6
|
|
RTS ; PRG:$110C Bytes:60
|
|
.byte $02, $03, $07, $0E, $0F, $11, $0A, $0B, $0B, $0C, $11, $0D, $0E, $0F, $0F, $10 ; PRG:$110D Bytes:02 03 07 0E 0F 11 0A 0B 0B 0C 11 0D 0E 0F 0F 10
|
|
.byte $0D ; PRG:$111D Bytes:0D
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecord_D11E
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecord_D11E:
|
|
LDY #$10 ; PRG:$111E Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1120 Bytes:B1 08
|
|
STA $06 ; PRG:$1122 Bytes:85 06
|
|
BMI ObjectPathContinue_D132 ; PRG:$1124 Bytes:30 0C
|
|
LDY #$1B ; PRG:$1126 Bytes:A0 1B
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1128 Bytes:B1 08
|
|
CMP #$10 ; PRG:$112A Bytes:C9 10
|
|
BCC ObjectPathContinue_D132 ; PRG:$112C Bytes:90 04
|
|
CMP #$40 ; PRG:$112E Bytes:C9 40
|
|
BCC ObjectPathOnNoCarry_D14F ; PRG:$1130 Bytes:90 1D
|
|
ObjectPathContinue_D132:
|
|
LDA $54 ; PRG:$1132 Bytes:A5 54
|
|
BNE UpdateObjectRecordOnNonZero_D13A ; PRG:$1134 Bytes:D0 04
|
|
LDA #$09 ; PRG:$1136 Bytes:A9 09
|
|
STA $54 ; PRG:$1138 Bytes:85 54
|
|
UpdateObjectRecordOnNonZero_D13A:
|
|
CMP #$05 ; PRG:$113A Bytes:C9 05
|
|
BCC ObjectPathOnNoCarry_D14E ; PRG:$113C Bytes:90 10
|
|
LDY #$35 ; PRG:$113E Bytes:A0 35
|
|
LDA #$01 ; PRG:$1140 Bytes:A9 01
|
|
EOR (CurrentObjectPtrLo),Y ; PRG:$1142 Bytes:51 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1144 Bytes:91 08
|
|
LDY #$05 ; PRG:$1146 Bytes:A0 05
|
|
LDA #$01 ; PRG:$1148 Bytes:A9 01
|
|
EOR (CurrentObjectPtrLo),Y ; PRG:$114A Bytes:51 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$114C Bytes:91 08
|
|
ObjectPathOnNoCarry_D14E:
|
|
RTS ; PRG:$114E Bytes:60
|
|
ObjectPathOnNoCarry_D14F:
|
|
LDX #$00 ; PRG:$114F Bytes:A2 00
|
|
LDY $0A ; PRG:$1151 Bytes:A4 0A
|
|
LDA a:$0058,Y ; PRG:$1153 Bytes:B9 58 00
|
|
LDY #$04 ; PRG:$1156 Bytes:A0 04
|
|
ObjectPathLoop_D158:
|
|
CMP $D10D,Y ; PRG:$1158 Bytes:D9 0D D1
|
|
BCS ObjectPathOnCarry_D161 ; PRG:$115B Bytes:B0 04
|
|
INX ; PRG:$115D Bytes:E8
|
|
DEY ; PRG:$115E Bytes:88
|
|
BPL ObjectPathLoop_D158 ; PRG:$115F Bytes:10 F7
|
|
ObjectPathOnCarry_D161:
|
|
LDA $06 ; PRG:$1161 Bytes:A5 06
|
|
AND #$03 ; PRG:$1163 Bytes:29 03
|
|
CMP #$02 ; PRG:$1165 Bytes:C9 02
|
|
TXA ; PRG:$1167 Bytes:8A
|
|
BCC UpdateObjectRecordOnNoCarry_D16D ; PRG:$1168 Bytes:90 03
|
|
CLC ; PRG:$116A Bytes:18
|
|
ADC #$06 ; PRG:$116B Bytes:69 06
|
|
UpdateObjectRecordOnNoCarry_D16D:
|
|
TAX ; PRG:$116D Bytes:AA
|
|
CLC ; PRG:$116E Bytes:18
|
|
ADC #$06 ; PRG:$116F Bytes:69 06
|
|
LDY #$05 ; PRG:$1171 Bytes:A0 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1173 Bytes:91 08
|
|
LDA $D112,X ; PRG:$1175 Bytes:BD 12 D1
|
|
LDY #$25 ; PRG:$1178 Bytes:A0 25
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$117A Bytes:91 08
|
|
SEC ; PRG:$117C Bytes:38
|
|
SBC #$04 ; PRG:$117D Bytes:E9 04
|
|
LDY #$35 ; PRG:$117F Bytes:A0 35
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1181 Bytes:91 08
|
|
RTS ; PRG:$1183 Bytes:60
|
|
.byte $27, $16, $27, $1A, $27, $26, $27, $2A, $27, $17, $17, $17, $25, $05, $05, $25 ; PRG:$1184 Bytes:27 16 27 1A 27 26 27 2A 27 17 17 17 25 05 05 25
|
|
.byte $2A, $0A, $0A, $2A, $21, $01, $01, $21, $23, $03, $03, $23, $27, $07, $07, $27 ; PRG:$1194 Bytes:2A 0A 0A 2A 21 01 01 21 23 03 03 23 27 07 07 27
|
|
.byte $25, $05, $05, $25, $21, $11, $11, $11, $21, $0F ; PRG:$11A4 Bytes:25 05 05 25 21 11 11 11 21 0F
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_D1AE
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_D1AE:
|
|
STX $00 ; PRG:$11AE Bytes:86 00
|
|
LDX #$3F ; PRG:$11B0 Bytes:A2 3F
|
|
STX $01 ; PRG:$11B2 Bytes:86 01
|
|
TYA ; PRG:$11B4 Bytes:98
|
|
ASL A ; PRG:$11B5 Bytes:0A
|
|
TAY ; PRG:$11B6 Bytes:A8
|
|
LDA $D184,Y ; PRG:$11B7 Bytes:B9 84 D1
|
|
STA $EE ; PRG:$11BA Bytes:85 EE
|
|
INY ; PRG:$11BC Bytes:C8
|
|
LDA $D184,Y ; PRG:$11BD Bytes:B9 84 D1
|
|
STA $EF ; PRG:$11C0 Bytes:85 EF
|
|
LDA #$EB ; PRG:$11C2 Bytes:A9 EB
|
|
STA $02 ; PRG:$11C4 Bytes:85 02
|
|
LDA #$00 ; PRG:$11C6 Bytes:A9 00
|
|
STA $03 ; PRG:$11C8 Bytes:85 03
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$11CA Bytes:20 A1 F3
|
|
RTS ; PRG:$11CD Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D1CE
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D1CE:
|
|
LDA $87 ; PRG:$11CE Bytes:A5 87
|
|
ASL A ; PRG:$11D0 Bytes:0A
|
|
CLC ; PRG:$11D1 Bytes:18
|
|
ADC #$06 ; PRG:$11D2 Bytes:69 06
|
|
TAY ; PRG:$11D4 Bytes:A8
|
|
RTS ; PRG:$11D5 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D1D6
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D1D6:
|
|
LDA $62 ; PRG:$11D6 Bytes:A5 62
|
|
BNE ObjectPathOnNonZero_D1F4 ; PRG:$11D8 Bytes:D0 1A
|
|
LDA #$06 ; PRG:$11DA Bytes:A9 06
|
|
STA $62 ; PRG:$11DC Bytes:85 62
|
|
LDY #$04 ; PRG:$11DE Bytes:A0 04
|
|
LDA $8F ; PRG:$11E0 Bytes:A5 8F
|
|
BEQ ObjectPathOnZero_D1E6 ; PRG:$11E2 Bytes:F0 02
|
|
LDY #$12 ; PRG:$11E4 Bytes:A0 12
|
|
ObjectPathOnZero_D1E6:
|
|
LDA #$01 ; PRG:$11E6 Bytes:A9 01
|
|
EOR $A2 ; PRG:$11E8 Bytes:45 A2
|
|
STA $A2 ; PRG:$11EA Bytes:85 A2
|
|
BEQ ObjectPathOnZero_D1EF ; PRG:$11EC Bytes:F0 01
|
|
INY ; PRG:$11EE Bytes:C8
|
|
ObjectPathOnZero_D1EF:
|
|
LDX #$04 ; PRG:$11EF Bytes:A2 04
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$11F1 Bytes:20 AE D1
|
|
ObjectPathOnNonZero_D1F4:
|
|
RTS ; PRG:$11F4 Bytes:60
|
|
.byte $22, $5C, $5D, $5E, $5F, $22, $58, $59, $5A, $5B, $22, $54, $55, $56, $57, $22 ; PRG:$11F5 Bytes:22 5C 5D 5E 5F 22 58 59 5A 5B 22 54 55 56 57 22
|
|
.byte $50, $51, $52, $53 ; PRG:$1205 Bytes:50 51 52 53
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D209
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D209:
|
|
LDA $57 ; PRG:$1209 Bytes:A5 57
|
|
BNE ObjectPathContinue_D254 ; PRG:$120B Bytes:D0 47
|
|
LDA #$02 ; PRG:$120D Bytes:A9 02
|
|
STA $57 ; PRG:$120F Bytes:85 57
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D211
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D211:
|
|
LDA $A3 ; PRG:$1211 Bytes:A5 A3
|
|
LDY $A4 ; PRG:$1213 Bytes:A4 A4
|
|
CPY #$FF ; PRG:$1215 Bytes:C0 FF
|
|
BNE UpdateObjectBufferOnNonZero_D222 ; PRG:$1217 Bytes:D0 09
|
|
SEC ; PRG:$1219 Bytes:38
|
|
SBC #$05 ; PRG:$121A Bytes:E9 05
|
|
BPL ObjectPathOnPositive_D220 ; PRG:$121C Bytes:10 02
|
|
LDA #$0F ; PRG:$121E Bytes:A9 0F
|
|
ObjectPathOnPositive_D220:
|
|
STA $A3 ; PRG:$1220 Bytes:85 A3
|
|
UpdateObjectBufferOnNonZero_D222:
|
|
CLC ; PRG:$1222 Bytes:18
|
|
ADC #$F5 ; PRG:$1223 Bytes:69 F5
|
|
STA $02 ; PRG:$1225 Bytes:85 02
|
|
LDA #$00 ; PRG:$1227 Bytes:A9 00
|
|
ADC #$D1 ; PRG:$1229 Bytes:69 D1
|
|
STA $03 ; PRG:$122B Bytes:85 03
|
|
JSR RunGameTaskRoutine_C8AA ; PRG:$122D Bytes:20 AA C8
|
|
INC $A4 ; PRG:$1230 Bytes:E6 A4
|
|
INC $A4 ; PRG:$1232 Bytes:E6 A4
|
|
LDA $A4 ; PRG:$1234 Bytes:A5 A4
|
|
BMI ObjectPathOnNegative_D23A ; PRG:$1236 Bytes:30 02
|
|
LDA #$F9 ; PRG:$1238 Bytes:A9 F9
|
|
ObjectPathOnNegative_D23A:
|
|
STA $A4 ; PRG:$123A Bytes:85 A4
|
|
LDY #$00 ; PRG:$123C Bytes:A0 00
|
|
CLC ; PRG:$123E Bytes:18
|
|
ADC ($04),Y ; PRG:$123F Bytes:71 04
|
|
TAY ; PRG:$1241 Bytes:A8
|
|
CMP #$01 ; PRG:$1242 Bytes:C9 01
|
|
BEQ ObjectPathContinue_D254 ; PRG:$1244 Bytes:F0 0E
|
|
BMI ObjectPathContinue_D254 ; PRG:$1246 Bytes:30 0C
|
|
LDA ($04),Y ; PRG:$1248 Bytes:B1 04
|
|
STA $00 ; PRG:$124A Bytes:85 00
|
|
DEY ; PRG:$124C Bytes:88
|
|
LDA ($04),Y ; PRG:$124D Bytes:B1 04
|
|
STA $01 ; PRG:$124F Bytes:85 01
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$1251 Bytes:20 A1 F3
|
|
ObjectPathContinue_D254:
|
|
RTS ; PRG:$1254 Bytes:60
|
|
.byte $02, $03, $00, $00, $00, $00, $00, $01, $10, $14 ; PRG:$1255 Bytes:02 03 00 00 00 00 00 01 10 14
|
|
ObjectPathLoop_D25F:
|
|
LDY $0A ; PRG:$125F Bytes:A4 0A
|
|
LDX $D25D,Y ; PRG:$1261 Bytes:BE 5D D2
|
|
LDA $63 ; PRG:$1264 Bytes:A5 63
|
|
BEQ ObjectPathOnZero_D277 ; PRG:$1266 Bytes:F0 0F
|
|
CMP #$08 ; PRG:$1268 Bytes:C9 08
|
|
BEQ ObjectPathOnZero_D272 ; PRG:$126A Bytes:F0 06
|
|
INY ; PRG:$126C Bytes:C8
|
|
INY ; PRG:$126D Bytes:C8
|
|
CMP #$01 ; PRG:$126E Bytes:C9 01
|
|
BNE ObjectPathLoop_D275 ; PRG:$1270 Bytes:D0 03
|
|
ObjectPathOnZero_D272:
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1272 Bytes:20 AE D1
|
|
ObjectPathLoop_D275:
|
|
SEC ; PRG:$1275 Bytes:38
|
|
RTS ; PRG:$1276 Bytes:60
|
|
ObjectPathOnZero_D277:
|
|
LDA #$10 ; PRG:$1277 Bytes:A9 10
|
|
STA $63 ; PRG:$1279 Bytes:85 63
|
|
BNE ObjectPathLoop_D275 ; PRG:$127B Bytes:D0 F8
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecord_D27D
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecord_D27D:
|
|
LDA $78 ; PRG:$127D Bytes:A5 78
|
|
BNE ObjectPathLoop_D275 ; PRG:$127F Bytes:D0 F4
|
|
LDX $0A ; PRG:$1281 Bytes:A6 0A
|
|
LDA $D0,X ; PRG:$1283 Bytes:B5 D0
|
|
BEQ ObjectPathOnZero_D2CE ; PRG:$1285 Bytes:F0 47
|
|
CMP #$02 ; PRG:$1287 Bytes:C9 02
|
|
BEQ ObjectPathOnZero_D2D0 ; PRG:$1289 Bytes:F0 45
|
|
LDA $46,X ; PRG:$128B Bytes:B5 46
|
|
AND #$0F ; PRG:$128D Bytes:29 0F
|
|
BEQ ObjectPathLoop_D25F ; PRG:$128F Bytes:F0 CE
|
|
DEC $D0,X ; PRG:$1291 Bytes:D6 D0
|
|
TAX ; PRG:$1293 Bytes:AA
|
|
LDA $D254,X ; PRG:$1294 Bytes:BD 54 D2
|
|
LDY #$10 ; PRG:$1297 Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1299 Bytes:91 08
|
|
PHA ; PRG:$129B Bytes:48
|
|
TAX ; PRG:$129C Bytes:AA
|
|
LDY $E16F,X ; PRG:$129D Bytes:BC 6F E1
|
|
LDX $82 ; PRG:$12A0 Bytes:A6 82
|
|
LDA $C0DD,X ; PRG:$12A2 Bytes:BD DD C0
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12A5 Bytes:91 08
|
|
DEY ; PRG:$12A7 Bytes:88
|
|
LDA $C0D5,X ; PRG:$12A8 Bytes:BD D5 C0
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12AB Bytes:91 08
|
|
PLA ; PRG:$12AD Bytes:68
|
|
AND #$01 ; PRG:$12AE Bytes:29 01
|
|
BEQ UpdateObjectRecordOnZero_D2B5 ; PRG:$12B0 Bytes:F0 03
|
|
JSR UpdateObjectRecordRoutine_E325 ; PRG:$12B2 Bytes:20 25 E3
|
|
UpdateObjectRecordOnZero_D2B5:
|
|
LDY #$30 ; PRG:$12B5 Bytes:A0 30
|
|
LDA #$00 ; PRG:$12B7 Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12B9 Bytes:91 08
|
|
LDY $0A ; PRG:$12BB Bytes:A4 0A
|
|
LDX $D25D,Y ; PRG:$12BD Bytes:BE 5D D2
|
|
LDA a:$0075,Y ; PRG:$12C0 Bytes:B9 75 00
|
|
BEQ ObjectPathOnZero_D2C7 ; PRG:$12C3 Bytes:F0 02
|
|
INY ; PRG:$12C5 Bytes:C8
|
|
INY ; PRG:$12C6 Bytes:C8
|
|
ObjectPathOnZero_D2C7:
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$12C7 Bytes:20 AE D1
|
|
LDA #$04 ; PRG:$12CA Bytes:A9 04
|
|
STA $FF ; PRG:$12CC Bytes:85 FF
|
|
ObjectPathOnZero_D2CE:
|
|
CLC ; PRG:$12CE Bytes:18
|
|
RTS ; PRG:$12CF Bytes:60
|
|
ObjectPathOnZero_D2D0:
|
|
DEC $D0,X ; PRG:$12D0 Bytes:D6 D0
|
|
JSR RunGameTaskRoutine_C8AA ; PRG:$12D2 Bytes:20 AA C8
|
|
LDY #$00 ; PRG:$12D5 Bytes:A0 00
|
|
LDA ($04),Y ; PRG:$12D7 Bytes:B1 04
|
|
TAY ; PRG:$12D9 Bytes:A8
|
|
LDX $0A ; PRG:$12DA Bytes:A6 0A
|
|
BEQ UpdateObjectRecordOnZero_D2E0 ; PRG:$12DC Bytes:F0 02
|
|
INY ; PRG:$12DE Bytes:C8
|
|
INY ; PRG:$12DF Bytes:C8
|
|
UpdateObjectRecordOnZero_D2E0:
|
|
LDA ($04),Y ; PRG:$12E0 Bytes:B1 04
|
|
STA $00 ; PRG:$12E2 Bytes:85 00
|
|
INY ; PRG:$12E4 Bytes:C8
|
|
LDA ($04),Y ; PRG:$12E5 Bytes:B1 04
|
|
STA $01 ; PRG:$12E7 Bytes:85 01
|
|
LDY #$00 ; PRG:$12E9 Bytes:A0 00
|
|
LDA #$00 ; PRG:$12EB Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12ED Bytes:91 08
|
|
INY ; PRG:$12EF Bytes:C8
|
|
LDA WorkPtr0Lo ; PRG:$12F0 Bytes:A5 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12F2 Bytes:91 08
|
|
INY ; PRG:$12F4 Bytes:C8
|
|
LDA #$00 ; PRG:$12F5 Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12F7 Bytes:91 08
|
|
INY ; PRG:$12F9 Bytes:C8
|
|
LDA WorkPtr0Hi ; PRG:$12FA Bytes:A5 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$12FC Bytes:91 08
|
|
INY ; PRG:$12FE Bytes:C8
|
|
LDA #$00 ; PRG:$12FF Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1301 Bytes:91 08
|
|
LDA #$16 ; PRG:$1303 Bytes:A9 16
|
|
CPX #$00 ; PRG:$1305 Bytes:E0 00
|
|
BEQ UpdateObjectRecordOnZero_D30B ; PRG:$1307 Bytes:F0 02
|
|
LDA #$17 ; PRG:$1309 Bytes:A9 17
|
|
UpdateObjectRecordOnZero_D30B:
|
|
INY ; PRG:$130B Bytes:C8
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$130C Bytes:91 08
|
|
LDY #$10 ; PRG:$130E Bytes:A0 10
|
|
LDA #$00 ; PRG:$1310 Bytes:A9 00
|
|
UpdateObjectRecordLoop_D312:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1312 Bytes:91 08
|
|
INY ; PRG:$1314 Bytes:C8
|
|
CPY #$1E ; PRG:$1315 Bytes:C0 1E
|
|
BNE UpdateObjectRecordLoop_D312 ; PRG:$1317 Bytes:D0 F9
|
|
LDY #$08 ; PRG:$1319 Bytes:A0 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$131B Bytes:91 08
|
|
SEC ; PRG:$131D Bytes:38
|
|
RTS ; PRG:$131E Bytes:60
|
|
.byte $10, $D0, $12, $13, $14, $15, $17, $18, $19, $1A, $1B, $17 ; PRG:$131F Bytes:10 D0 12 13 14 15 17 18 19 1A 1B 17
|
|
ObjectPathLoop_D32B:
|
|
LDA #$00 ; PRG:$132B Bytes:A9 00
|
|
STA $90,X ; PRG:$132D Bytes:95 90
|
|
ObjectPathLoop_D32F:
|
|
CLC ; PRG:$132F Bytes:18
|
|
RTS ; PRG:$1330 Bytes:60
|
|
ReadObjectRecordLoop_D331:
|
|
LDA $78 ; PRG:$1331 Bytes:A5 78
|
|
BNE ObjectPathLoop_D32B ; PRG:$1333 Bytes:D0 F6
|
|
LDY #$10 ; PRG:$1335 Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1337 Bytes:B1 08
|
|
BMI ObjectPathLoop_D32F ; PRG:$1339 Bytes:30 F4
|
|
AND #$0F ; PRG:$133B Bytes:29 0F
|
|
TAX ; PRG:$133D Bytes:AA
|
|
JSR UpdateObjectRecordRoutine_E335 ; PRG:$133E Bytes:20 35 E3
|
|
BCC ObjectPathLoop_D32F ; PRG:$1341 Bytes:90 EC
|
|
LDX $0A ; PRG:$1343 Bytes:A6 0A
|
|
DEC $90,X ; PRG:$1345 Bytes:D6 90
|
|
LDA #$00 ; PRG:$1347 Bytes:A9 00
|
|
BEQ UpdateObjectRecordOnZero_D36E ; PRG:$1349 Bytes:F0 23
|
|
ObjectPathLoop_D34B:
|
|
JMP UpdateObjectRecordDispatch_D401 ; PRG:$134B Bytes:4C 01 D4
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D34E
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D34E:
|
|
LDX $0A ; PRG:$134E Bytes:A6 0A
|
|
LDA $90,X ; PRG:$1350 Bytes:B5 90
|
|
BEQ ObjectPathLoop_D32F ; PRG:$1352 Bytes:F0 DB
|
|
CMP #$01 ; PRG:$1354 Bytes:C9 01
|
|
BEQ ObjectPathOnZero_D382 ; PRG:$1356 Bytes:F0 2A
|
|
CMP #$10 ; PRG:$1358 Bytes:C9 10
|
|
BEQ UpdateObjectBufferOnZero_D384 ; PRG:$135A Bytes:F0 28
|
|
CMP #$11 ; PRG:$135C Bytes:C9 11
|
|
BEQ UpdateObjectBufferOnZero_D3AF ; PRG:$135E Bytes:F0 4F
|
|
CMP #$12 ; PRG:$1360 Bytes:C9 12
|
|
BEQ ObjectPathLoop_D34B ; PRG:$1362 Bytes:F0 E7
|
|
CMP #$13 ; PRG:$1364 Bytes:C9 13
|
|
BEQ ReadObjectRecordLoop_D331 ; PRG:$1366 Bytes:F0 C9
|
|
LDA #$12 ; PRG:$1368 Bytes:A9 12
|
|
STA $90,X ; PRG:$136A Bytes:95 90
|
|
LDA #$05 ; PRG:$136C Bytes:A9 05
|
|
UpdateObjectRecordOnZero_D36E:
|
|
STA $D2,X ; PRG:$136E Bytes:95 D2
|
|
LDA #$08 ; PRG:$1370 Bytes:A9 08
|
|
STA $5C,X ; PRG:$1372 Bytes:95 5C
|
|
LDY #$20 ; PRG:$1374 Bytes:A0 20
|
|
LDA #$01 ; PRG:$1376 Bytes:A9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1378 Bytes:91 08
|
|
LDY #$30 ; PRG:$137A Bytes:A0 30
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$137C Bytes:91 08
|
|
LDA #$02 ; PRG:$137E Bytes:A9 02
|
|
STA $FF ; PRG:$1380 Bytes:85 FF
|
|
ObjectPathOnZero_D382:
|
|
SEC ; PRG:$1382 Bytes:38
|
|
RTS ; PRG:$1383 Bytes:60
|
|
UpdateObjectBufferOnZero_D384:
|
|
LDA $72,X ; PRG:$1384 Bytes:B5 72
|
|
BNE UpdateObjectBufferOnNonZero_D396 ; PRG:$1386 Bytes:D0 0E
|
|
STA $90,X ; PRG:$1388 Bytes:95 90
|
|
INC $90,X ; PRG:$138A Bytes:F6 90
|
|
LDA #$01 ; PRG:$138C Bytes:A9 01
|
|
STA $03F0 ; PRG:$138E Bytes:8D F0 03
|
|
JSR RunGameTaskRoutine_C8D6 ; PRG:$1391 Bytes:20 D6 C8
|
|
SEC ; PRG:$1394 Bytes:38
|
|
RTS ; PRG:$1395 Bytes:60
|
|
UpdateObjectBufferOnNonZero_D396:
|
|
LDA $03F1 ; PRG:$1396 Bytes:AD F1 03
|
|
CMP #$1A ; PRG:$1399 Bytes:C9 1A
|
|
BCC UpdateObjectBufferOnNoCarry_D3A2 ; PRG:$139B Bytes:90 05
|
|
SBC #$02 ; PRG:$139D Bytes:E9 02
|
|
STA $03F1 ; PRG:$139F Bytes:8D F1 03
|
|
UpdateObjectBufferOnNoCarry_D3A2:
|
|
LDA #$F0 ; PRG:$13A2 Bytes:A9 F0
|
|
STA $00 ; PRG:$13A4 Bytes:85 00
|
|
LDA #$03 ; PRG:$13A6 Bytes:A9 03
|
|
STA $01 ; PRG:$13A8 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F601 ; PRG:$13AA Bytes:20 01 F6
|
|
SEC ; PRG:$13AD Bytes:38
|
|
RTS ; PRG:$13AE Bytes:60
|
|
UpdateObjectBufferOnZero_D3AF:
|
|
LDA $5C,X ; PRG:$13AF Bytes:B5 5C
|
|
BNE ObjectPathContinue_D3DA ; PRG:$13B1 Bytes:D0 27
|
|
DEC $80,X ; PRG:$13B3 Bytes:D6 80
|
|
BPL ObjectPathOnPositive_D3E0 ; PRG:$13B5 Bytes:10 29
|
|
STA $80,X ; PRG:$13B7 Bytes:95 80
|
|
LDA $03F0 ; PRG:$13B9 Bytes:AD F0 03
|
|
BEQ ObjectPathContinue_D3DA ; PRG:$13BC Bytes:F0 1C
|
|
LDA $8D ; PRG:$13BE Bytes:A5 8D
|
|
BNE ObjectPathOnNonZero_D3DC ; PRG:$13C0 Bytes:D0 1A
|
|
STA $03F0 ; PRG:$13C2 Bytes:8D F0 03
|
|
LDA #$EF ; PRG:$13C5 Bytes:A9 EF
|
|
STA $03F1 ; PRG:$13C7 Bytes:8D F1 03
|
|
LDA $D31F,X ; PRG:$13CA Bytes:BD 1F D3
|
|
STA $03F3 ; PRG:$13CD Bytes:8D F3 03
|
|
LDA #$01 ; PRG:$13D0 Bytes:A9 01
|
|
STA $FF ; PRG:$13D2 Bytes:85 FF
|
|
LDA #$14 ; PRG:$13D4 Bytes:A9 14
|
|
STA $72,X ; PRG:$13D6 Bytes:95 72
|
|
DEC $90,X ; PRG:$13D8 Bytes:D6 90
|
|
ObjectPathContinue_D3DA:
|
|
SEC ; PRG:$13DA Bytes:38
|
|
RTS ; PRG:$13DB Bytes:60
|
|
ObjectPathOnNonZero_D3DC:
|
|
STA $90,X ; PRG:$13DC Bytes:95 90
|
|
SEC ; PRG:$13DE Bytes:38
|
|
RTS ; PRG:$13DF Bytes:60
|
|
ObjectPathOnPositive_D3E0:
|
|
STA $90,X ; PRG:$13E0 Bytes:95 90
|
|
LDA #$02 ; PRG:$13E2 Bytes:A9 02
|
|
STA $D0,X ; PRG:$13E4 Bytes:95 D0
|
|
JSR ProcessObjectStateRoutine_D42C ; PRG:$13E6 Bytes:20 2C D4
|
|
LDA $A0 ; PRG:$13E9 Bytes:A5 A0
|
|
BEQ ObjectPathOnZero_D3FF ; PRG:$13EB Bytes:F0 12
|
|
LDA #$00 ; PRG:$13ED Bytes:A9 00
|
|
STA $A0 ; PRG:$13EF Bytes:85 A0
|
|
STA $2F ; PRG:$13F1 Bytes:85 2F
|
|
LDA #$04 ; PRG:$13F3 Bytes:A9 04
|
|
STA $2E ; PRG:$13F5 Bytes:85 2E
|
|
LDA #$82 ; PRG:$13F7 Bytes:A9 82
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$13F9 Bytes:20 1A F3
|
|
JSR UpdateGameStateRoutine_C402 ; PRG:$13FC Bytes:20 02 C4
|
|
ObjectPathOnZero_D3FF:
|
|
SEC ; PRG:$13FF Bytes:38
|
|
RTS ; PRG:$1400 Bytes:60
|
|
UpdateObjectRecordDispatch_D401:
|
|
LDA $5C,X ; PRG:$1401 Bytes:B5 5C
|
|
BNE ObjectPathOnNonZero_D418 ; PRG:$1403 Bytes:D0 13
|
|
LDY $D2,X ; PRG:$1405 Bytes:B4 D2
|
|
LDA $D321,Y ; PRG:$1407 Bytes:B9 21 D3
|
|
LDY #$05 ; PRG:$140A Bytes:A0 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$140C Bytes:91 08
|
|
CMP #$17 ; PRG:$140E Bytes:C9 17
|
|
BEQ UpdateObjectRecordOnZero_D41A ; PRG:$1410 Bytes:F0 08
|
|
INC $D2,X ; PRG:$1412 Bytes:F6 D2
|
|
LDA #$08 ; PRG:$1414 Bytes:A9 08
|
|
ObjectPathLoop_D416:
|
|
STA $5C,X ; PRG:$1416 Bytes:95 5C
|
|
ObjectPathOnNonZero_D418:
|
|
SEC ; PRG:$1418 Bytes:38
|
|
RTS ; PRG:$1419 Bytes:60
|
|
UpdateObjectRecordOnZero_D41A:
|
|
DEC $90,X ; PRG:$141A Bytes:D6 90
|
|
LDY #$00 ; PRG:$141C Bytes:A0 00
|
|
LDA #$01 ; PRG:$141E Bytes:A9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1420 Bytes:91 08
|
|
LDA #$80 ; PRG:$1422 Bytes:A9 80
|
|
LDY $80,X ; PRG:$1424 Bytes:B4 80
|
|
BNE ObjectPathLoop_D416 ; PRG:$1426 Bytes:D0 EE
|
|
LDA #$10 ; PRG:$1428 Bytes:A9 10
|
|
BNE ObjectPathLoop_D416 ; PRG:$142A Bytes:D0 EA
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D42C
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D42C:
|
|
LDY #$20 ; PRG:$142C Bytes:A0 20
|
|
LDA #$43 ; PRG:$142E Bytes:A9 43
|
|
CPX #$00 ; PRG:$1430 Bytes:E0 00
|
|
BEQ UpdateObjectBufferLoop_D436 ; PRG:$1432 Bytes:F0 02
|
|
LDA #$5A ; PRG:$1434 Bytes:A9 5A
|
|
UpdateObjectBufferLoop_D436:
|
|
STA $00 ; PRG:$1436 Bytes:85 00
|
|
STY $01 ; PRG:$1438 Bytes:84 01
|
|
LDA #$E7 ; PRG:$143A Bytes:A9 E7
|
|
STA $02 ; PRG:$143C Bytes:85 02
|
|
LDA #$00 ; PRG:$143E Bytes:A9 00
|
|
STA $03 ; PRG:$1440 Bytes:85 03
|
|
LDA $80,X ; PRG:$1442 Bytes:B5 80
|
|
STA $E9 ; PRG:$1444 Bytes:85 E9
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$1446 Bytes:20 A1 F3
|
|
RTS ; PRG:$1449 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D44A
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D44A:
|
|
LDY #$28 ; PRG:$144A Bytes:A0 28
|
|
LDA #$E9 ; PRG:$144C Bytes:A9 E9
|
|
CPX #$00 ; PRG:$144E Bytes:E0 00
|
|
BEQ UpdateObjectBufferLoop_D436 ; PRG:$1450 Bytes:F0 E4
|
|
LDY #$2A ; PRG:$1452 Bytes:A0 2A
|
|
LDA #$A9 ; PRG:$1454 Bytes:A9 A9
|
|
BNE UpdateObjectBufferLoop_D436 ; PRG:$1456 Bytes:D0 DE
|
|
CLC ; PRG:$1458 Bytes:18
|
|
BMI ObjectPathOnNegative_D4A3 ; PRG:$1459 Bytes:30 48
|
|
RTS ; PRG:$145B Bytes:60
|
|
.byte $78, $90, $A8, $C0, $D8, $20, $38, $50, $68, $80, $98, $B0, $C8, $C8, $0A, $18 ; PRG:$145C Bytes:78 90 A8 C0 D8 20 38 50 68 80 98 B0 C8 C8 0A 18
|
|
.byte $08, $08, $10, $04, $01, $03, $19, $1A, $01, $03 ; PRG:$146C Bytes:08 08 10 04 01 03 19 1A 01 03
|
|
ObjectPathLoop_D476:
|
|
SBC #$03 ; PRG:$1476 Bytes:E9 03
|
|
CMP #$F0 ; PRG:$1478 Bytes:C9 F0
|
|
BCC ObjectPathOnNoCarry_D47E ; PRG:$147A Bytes:90 02
|
|
LDA #$F0 ; PRG:$147C Bytes:A9 F0
|
|
ObjectPathOnNoCarry_D47E:
|
|
JMP UpdateObjectRecordDispatch_D49E ; PRG:$147E Bytes:4C 9E D4
|
|
ReadObjectRecordDispatch_D481:
|
|
CMP #$F0 ; PRG:$1481 Bytes:C9 F0
|
|
BCS ReadObjectRecordOnCarry_D4D5 ; PRG:$1483 Bytes:B0 50
|
|
CMP #$90 ; PRG:$1485 Bytes:C9 90
|
|
AND #$0F ; PRG:$1487 Bytes:29 0F
|
|
STA $06 ; PRG:$1489 Bytes:85 06
|
|
BCS UpdateObjectRecordOnCarry_D4DE ; PRG:$148B Bytes:B0 51
|
|
LSR A ; PRG:$148D Bytes:4A
|
|
TAX ; PRG:$148E Bytes:AA
|
|
LDY $D474,X ; PRG:$148F Bytes:BC 74 D4
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1492 Bytes:B1 08
|
|
BCS ObjectPathLoop_D476 ; PRG:$1494 Bytes:B0 E0
|
|
ADC #$03 ; PRG:$1496 Bytes:69 03
|
|
CMP #$F1 ; PRG:$1498 Bytes:C9 F1
|
|
BCC UpdateObjectRecordDispatch_D49E ; PRG:$149A Bytes:90 02
|
|
LDA #$00 ; PRG:$149C Bytes:A9 00
|
|
UpdateObjectRecordDispatch_D49E:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$149E Bytes:91 08
|
|
LDA $0F ; PRG:$14A0 Bytes:A5 0F
|
|
CLC ; PRG:$14A2 Bytes:18
|
|
ObjectPathOnNegative_D4A3:
|
|
ADC #$06 ; PRG:$14A3 Bytes:69 06
|
|
JSR ReadObjectRecordRoutine_E5AA ; PRG:$14A5 Bytes:20 AA E5
|
|
LDY #$10 ; PRG:$14A8 Bytes:A0 10
|
|
BCS UpdateObjectRecordContinue_D4CB ; PRG:$14AA Bytes:B0 1F
|
|
CMP #$24 ; PRG:$14AC Bytes:C9 24
|
|
BEQ UpdateObjectRecordContinue_D4CB ; PRG:$14AE Bytes:F0 1B
|
|
CMP #$FF ; PRG:$14B0 Bytes:C9 FF
|
|
BEQ UpdateObjectRecordOnZero_D4B8 ; PRG:$14B2 Bytes:F0 04
|
|
CMP #$4A ; PRG:$14B4 Bytes:C9 4A
|
|
BCS UpdateObjectRecordContinue_D4CB ; PRG:$14B6 Bytes:B0 13
|
|
UpdateObjectRecordOnZero_D4B8:
|
|
LDA #$01 ; PRG:$14B8 Bytes:A9 01
|
|
STA $FC ; PRG:$14BA Bytes:85 FC
|
|
LDA #$94 ; PRG:$14BC Bytes:A9 94
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$14BE Bytes:91 08
|
|
LDY #$15 ; PRG:$14C0 Bytes:A0 15
|
|
LDA #$02 ; PRG:$14C2 Bytes:A9 02
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$14C4 Bytes:91 08
|
|
ObjectPathLoop_D4C6:
|
|
LDA #$20 ; PRG:$14C6 Bytes:A9 20
|
|
JMP ProcessObjectStateDispatch_D783 ; PRG:$14C8 Bytes:4C 83 D7
|
|
UpdateObjectRecordContinue_D4CB:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$14CB Bytes:B1 08
|
|
AND #$03 ; PRG:$14CD Bytes:29 03
|
|
ORA #$40 ; PRG:$14CF Bytes:09 40
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$14D1 Bytes:91 08
|
|
BNE ObjectPathLoop_D4C6 ; PRG:$14D3 Bytes:D0 F1
|
|
ReadObjectRecordOnCarry_D4D5:
|
|
LDY #$15 ; PRG:$14D5 Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$14D7 Bytes:B1 08
|
|
BNE ObjectPathOnNonZero_D4F9 ; PRG:$14D9 Bytes:D0 1E
|
|
JMP UpdateObjectRecordDispatch_D57E ; PRG:$14DB Bytes:4C 7E D5
|
|
UpdateObjectRecordOnCarry_D4DE:
|
|
LDY #$15 ; PRG:$14DE Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$14E0 Bytes:B1 08
|
|
BNE ObjectPathOnNonZero_D4F9 ; PRG:$14E2 Bytes:D0 15
|
|
LDA #$01 ; PRG:$14E4 Bytes:A9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$14E6 Bytes:91 08
|
|
LDA $06 ; PRG:$14E8 Bytes:A5 06
|
|
CMP #$09 ; PRG:$14EA Bytes:C9 09
|
|
BCS UpdateObjectRecordOnCarry_D4FC ; PRG:$14EC Bytes:B0 0E
|
|
LDY #$05 ; PRG:$14EE Bytes:A0 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$14F0 Bytes:91 08
|
|
CLC ; PRG:$14F2 Bytes:18
|
|
ADC #$91 ; PRG:$14F3 Bytes:69 91
|
|
LDY #$10 ; PRG:$14F5 Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$14F7 Bytes:91 08
|
|
ObjectPathOnNonZero_D4F9:
|
|
JMP ProcessObjectStateDispatch_D67A ; PRG:$14F9 Bytes:4C 7A D6
|
|
UpdateObjectRecordOnCarry_D4FC:
|
|
LDX $82 ; PRG:$14FC Bytes:A6 82
|
|
LDA $C0C9,X ; PRG:$14FE Bytes:BD C9 C0
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1501 Bytes:91 08
|
|
LDY #$10 ; PRG:$1503 Bytes:A0 10
|
|
LDA #$01 ; PRG:$1505 Bytes:A9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1507 Bytes:91 08
|
|
LDY #$00 ; PRG:$1509 Bytes:A0 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$150B Bytes:91 08
|
|
INY ; PRG:$150D Bytes:C8
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$150E Bytes:B1 08
|
|
STA $04 ; PRG:$1510 Bytes:85 04
|
|
LDY #$03 ; PRG:$1512 Bytes:A0 03
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1514 Bytes:B1 08
|
|
STA $05 ; PRG:$1516 Bytes:85 05
|
|
LDX #$01 ; PRG:$1518 Bytes:A2 01
|
|
JSR UpdateObjectBufferRoutine_DD5B ; PRG:$151A Bytes:20 5B DD
|
|
LDY #$1B ; PRG:$151D Bytes:A0 1B
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$151F Bytes:B1 08
|
|
TAX ; PRG:$1521 Bytes:AA
|
|
INC $D6,X ; PRG:$1522 Bytes:F6 D6
|
|
JMP ProcessObjectStateDispatch_D67A ; PRG:$1524 Bytes:4C 7A D6
|
|
UpdateObjectRecordDispatch_D527:
|
|
LDX $82 ; PRG:$1527 Bytes:A6 82
|
|
LDA $C0C1,X ; PRG:$1529 Bytes:BD C1 C0
|
|
SBC #$05 ; PRG:$152C Bytes:E9 05
|
|
LDY #$15 ; PRG:$152E Bytes:A0 15
|
|
CMP (CurrentObjectPtrLo),Y ; PRG:$1530 Bytes:D1 08
|
|
BCC ObjectPathOnNoCarry_D54C ; PRG:$1532 Bytes:90 18
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1534 Bytes:B1 08
|
|
BNE ObjectPathOnNonZero_D546 ; PRG:$1536 Bytes:D0 0E
|
|
LDA #$10 ; PRG:$1538 Bytes:A9 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$153A Bytes:91 08
|
|
LDY #$10 ; PRG:$153C Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$153E Bytes:B1 08
|
|
AND #$03 ; PRG:$1540 Bytes:29 03
|
|
ORA #$30 ; PRG:$1542 Bytes:09 30
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1544 Bytes:91 08
|
|
ObjectPathOnNonZero_D546:
|
|
LDA #$04 ; PRG:$1546 Bytes:A9 04
|
|
UpdateObjectRecordLoop_D548:
|
|
LDY #$05 ; PRG:$1548 Bytes:A0 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$154A Bytes:91 08
|
|
ObjectPathOnNoCarry_D54C:
|
|
LDA #$30 ; PRG:$154C Bytes:A9 30
|
|
JMP ProcessObjectStateDispatch_D783 ; PRG:$154E Bytes:4C 83 D7
|
|
.byte $A9, $10, $91, $08 ; PRG:$1551 Bytes:A9 10 91 08
|
|
UpdateObjectRecordDispatch_D555:
|
|
AND #$03 ; PRG:$1555 Bytes:29 03
|
|
ORA #$50 ; PRG:$1557 Bytes:09 50
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1559 Bytes:91 08
|
|
LDY #$15 ; PRG:$155B Bytes:A0 15
|
|
LDX $82 ; PRG:$155D Bytes:A6 82
|
|
LDA $C0C1,X ; PRG:$155F Bytes:BD C1 C0
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1562 Bytes:91 08
|
|
INY ; PRG:$1564 Bytes:C8
|
|
LDA #$00 ; PRG:$1565 Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1567 Bytes:91 08
|
|
LDY #$08 ; PRG:$1569 Bytes:A0 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$156B Bytes:91 08
|
|
LDA #$02 ; PRG:$156D Bytes:A9 02
|
|
STA $FC ; PRG:$156F Bytes:85 FC
|
|
LDY #$09 ; PRG:$1571 Bytes:A0 09
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1573 Bytes:B1 08
|
|
AND #$F0 ; PRG:$1575 Bytes:29 F0
|
|
ORA #$03 ; PRG:$1577 Bytes:09 03
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1579 Bytes:91 08
|
|
JMP ProcessObjectStateDispatch_D67A ; PRG:$157B Bytes:4C 7A D6
|
|
UpdateObjectRecordDispatch_D57E:
|
|
LDY #$15 ; PRG:$157E Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1580 Bytes:B1 08
|
|
BNE UpdateObjectRecordOnNonZero_D595 ; PRG:$1582 Bytes:D0 11
|
|
LDA #$30 ; PRG:$1584 Bytes:A9 30
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1586 Bytes:91 08
|
|
LDY #$10 ; PRG:$1588 Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$158A Bytes:B1 08
|
|
AND #$03 ; PRG:$158C Bytes:29 03
|
|
ORA #$10 ; PRG:$158E Bytes:09 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1590 Bytes:91 08
|
|
JMP ReadObjectRecordDispatch_D777 ; PRG:$1592 Bytes:4C 77 D7
|
|
UpdateObjectRecordOnNonZero_D595:
|
|
LDY #$09 ; PRG:$1595 Bytes:A0 09
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1597 Bytes:B1 08
|
|
AND #$F0 ; PRG:$1599 Bytes:29 F0
|
|
ORA #$02 ; PRG:$159B Bytes:09 02
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$159D Bytes:91 08
|
|
ProcessObjectStateDispatch_D59F:
|
|
LDA #$04 ; PRG:$159F Bytes:A9 04
|
|
BNE UpdateObjectRecordLoop_D548 ; PRG:$15A1 Bytes:D0 A5
|
|
UpdateObjectRecordDispatch_D5A3:
|
|
STA $06 ; PRG:$15A3 Bytes:85 06
|
|
LDY #$17 ; PRG:$15A5 Bytes:A0 17
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$15A7 Bytes:B1 08
|
|
BNE ObjectPathContinue_D5CC ; PRG:$15A9 Bytes:D0 21
|
|
LDY #$15 ; PRG:$15AB Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$15AD Bytes:B1 08
|
|
BEQ ObjectPathContinue_D5CC ; PRG:$15AF Bytes:F0 1B
|
|
INY ; PRG:$15B1 Bytes:C8
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$15B2 Bytes:B1 08
|
|
BNE ObjectPathOnNonZero_D5C9 ; PRG:$15B4 Bytes:D0 13
|
|
LDA #$04 ; PRG:$15B6 Bytes:A9 04
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$15B8 Bytes:91 08
|
|
LDY #$10 ; PRG:$15BA Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$15BC Bytes:B1 08
|
|
CLC ; PRG:$15BE Bytes:18
|
|
ADC #$01 ; PRG:$15BF Bytes:69 01
|
|
CMP #$24 ; PRG:$15C1 Bytes:C9 24
|
|
BNE UpdateObjectRecordOnNonZero_D5C7 ; PRG:$15C3 Bytes:D0 02
|
|
LDA #$20 ; PRG:$15C5 Bytes:A9 20
|
|
UpdateObjectRecordOnNonZero_D5C7:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$15C7 Bytes:91 08
|
|
ObjectPathOnNonZero_D5C9:
|
|
JMP ReadObjectRecordDispatch_D777 ; PRG:$15C9 Bytes:4C 77 D7
|
|
ObjectPathContinue_D5CC:
|
|
LDX #$00 ; PRG:$15CC Bytes:A2 00
|
|
LDA $06 ; PRG:$15CE Bytes:A5 06
|
|
AND #$02 ; PRG:$15D0 Bytes:29 02
|
|
BNE ReadObjectRecordOnNonZero_D5D5 ; PRG:$15D2 Bytes:D0 01
|
|
INX ; PRG:$15D4 Bytes:E8
|
|
ReadObjectRecordOnNonZero_D5D5:
|
|
EOR #$13 ; PRG:$15D5 Bytes:49 13
|
|
PHA ; PRG:$15D7 Bytes:48
|
|
LDY $D470,X ; PRG:$15D8 Bytes:BC 70 D4
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$15DB Bytes:B1 08
|
|
LDY $D472,X ; PRG:$15DD Bytes:BC 72 D4
|
|
LDX #$80 ; PRG:$15E0 Bytes:A2 80
|
|
SEC ; PRG:$15E2 Bytes:38
|
|
SBC (CurrentObjectPtrLo),Y ; PRG:$15E3 Bytes:F1 08
|
|
STA $00 ; PRG:$15E5 Bytes:85 00
|
|
BEQ ObjectPathOnZero_D5F8 ; PRG:$15E7 Bytes:F0 0F
|
|
BCS ObjectPathOnCarry_D5F6 ; PRG:$15E9 Bytes:B0 0B
|
|
PLA ; PRG:$15EB Bytes:68
|
|
AND #$12 ; PRG:$15EC Bytes:29 12
|
|
PHA ; PRG:$15EE Bytes:48
|
|
SEC ; PRG:$15EF Bytes:38
|
|
LDA #$00 ; PRG:$15F0 Bytes:A9 00
|
|
SBC $00 ; PRG:$15F2 Bytes:E5 00
|
|
STA $00 ; PRG:$15F4 Bytes:85 00
|
|
ObjectPathOnCarry_D5F6:
|
|
LDX #$20 ; PRG:$15F6 Bytes:A2 20
|
|
ObjectPathOnZero_D5F8:
|
|
PLA ; PRG:$15F8 Bytes:68
|
|
CPX $11 ; PRG:$15F9 Bytes:E4 11
|
|
BCC UpdateObjectRecordOnNoCarry_D5FF ; PRG:$15FB Bytes:90 02
|
|
EOR #$01 ; PRG:$15FD Bytes:49 01
|
|
UpdateObjectRecordOnNoCarry_D5FF:
|
|
LDY #$10 ; PRG:$15FF Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1601 Bytes:91 08
|
|
LDX #$01 ; PRG:$1603 Bytes:A2 01
|
|
LDA $82 ; PRG:$1605 Bytes:A5 82
|
|
CMP #$03 ; PRG:$1607 Bytes:C9 03
|
|
BCC UpdateObjectRecordOnNoCarry_D60C ; PRG:$1609 Bytes:90 01
|
|
INX ; PRG:$160B Bytes:E8
|
|
UpdateObjectRecordOnNoCarry_D60C:
|
|
TXA ; PRG:$160C Bytes:8A
|
|
LDY #$18 ; PRG:$160D Bytes:A0 18
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$160F Bytes:91 08
|
|
LDY #$00 ; PRG:$1611 Bytes:A0 00
|
|
STY $01 ; PRG:$1613 Bytes:84 01
|
|
ObjectPathLoop_D615:
|
|
SEC ; PRG:$1615 Bytes:38
|
|
LDA WorkPtr0Hi ; PRG:$1616 Bytes:A5 01
|
|
SBC $C0BD,X ; PRG:$1618 Bytes:FD BD C0
|
|
STA $01 ; PRG:$161B Bytes:85 01
|
|
LDA WorkPtr0Lo ; PRG:$161D Bytes:A5 00
|
|
SBC $C0B5,X ; PRG:$161F Bytes:FD B5 C0
|
|
STA $00 ; PRG:$1622 Bytes:85 00
|
|
INY ; PRG:$1624 Bytes:C8
|
|
BCS ObjectPathLoop_D615 ; PRG:$1625 Bytes:B0 EE
|
|
TYA ; PRG:$1627 Bytes:98
|
|
LDY #$00 ; PRG:$1628 Bytes:A0 00
|
|
UpdateObjectRecordLoop_D62A:
|
|
SEC ; PRG:$162A Bytes:38
|
|
SBC #$06 ; PRG:$162B Bytes:E9 06
|
|
INY ; PRG:$162D Bytes:C8
|
|
BCS UpdateObjectRecordLoop_D62A ; PRG:$162E Bytes:B0 FA
|
|
TYA ; PRG:$1630 Bytes:98
|
|
LDY #$15 ; PRG:$1631 Bytes:A0 15
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1633 Bytes:91 08
|
|
INY ; PRG:$1635 Bytes:C8
|
|
LDA #$00 ; PRG:$1636 Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1638 Bytes:91 08
|
|
INY ; PRG:$163A Bytes:C8
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$163B Bytes:91 08
|
|
JMP ReadObjectRecordDispatch_D777 ; PRG:$163D Bytes:4C 77 D7
|
|
ObjectPathLoop_D640:
|
|
JMP UpdateObjectRecordDispatch_D5A3 ; PRG:$1640 Bytes:4C A3 D5
|
|
ObjectPathLoop_D643:
|
|
JMP ReadObjectRecordDispatch_D481 ; PRG:$1643 Bytes:4C 81 D4
|
|
ObjectPathLoop_D646:
|
|
JMP UpdateObjectRecordDispatch_D57E ; PRG:$1646 Bytes:4C 7E D5
|
|
ObjectPathLoop_D649:
|
|
JMP UpdateObjectBufferDispatch_D73B ; PRG:$1649 Bytes:4C 3B D7
|
|
ObjectPathLoop_D64C:
|
|
JMP UpdateObjectRecordDispatch_D555 ; PRG:$164C Bytes:4C 55 D5
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_D64F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_D64F:
|
|
LDA #$03 ; PRG:$164F Bytes:A9 03
|
|
STA $0F ; PRG:$1651 Bytes:85 0F
|
|
LDA #$80 ; PRG:$1653 Bytes:A9 80
|
|
STA $08 ; PRG:$1655 Bytes:85 08
|
|
LDA #$04 ; PRG:$1657 Bytes:A9 04
|
|
STA $09 ; PRG:$1659 Bytes:85 09
|
|
ReadObjectRecordLoop_D65B:
|
|
LDY #$10 ; PRG:$165B Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$165D Bytes:B1 08
|
|
BEQ ProcessObjectStateDispatch_D67A ; PRG:$165F Bytes:F0 19
|
|
BMI ObjectPathLoop_D643 ; PRG:$1661 Bytes:30 E0
|
|
CMP #$01 ; PRG:$1663 Bytes:C9 01
|
|
BEQ ReadObjectRecordOnZero_D6A9 ; PRG:$1665 Bytes:F0 42
|
|
CMP #$20 ; PRG:$1667 Bytes:C9 20
|
|
BCC ObjectPathLoop_D649 ; PRG:$1669 Bytes:90 DE
|
|
CMP #$30 ; PRG:$166B Bytes:C9 30
|
|
BCC ObjectPathLoop_D640 ; PRG:$166D Bytes:90 D1
|
|
CMP #$40 ; PRG:$166F Bytes:C9 40
|
|
BCC ObjectPathLoop_D646 ; PRG:$1671 Bytes:90 D3
|
|
CMP #$50 ; PRG:$1673 Bytes:C9 50
|
|
BCC ObjectPathLoop_D64C ; PRG:$1675 Bytes:90 D5
|
|
JMP UpdateObjectRecordDispatch_D527 ; PRG:$1677 Bytes:4C 27 D5
|
|
ProcessObjectStateDispatch_D67A:
|
|
LDX $5E ; PRG:$167A Bytes:A6 5E
|
|
BNE UpdateObjectRecordContinue_D68E ; PRG:$167C Bytes:D0 10
|
|
LDY #$15 ; PRG:$167E Bytes:A0 15
|
|
UpdateObjectRecordLoop_D680:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1680 Bytes:B1 08
|
|
BEQ UpdateObjectRecordContinue_D68E ; PRG:$1682 Bytes:F0 0A
|
|
SEC ; PRG:$1684 Bytes:38
|
|
SBC #$01 ; PRG:$1685 Bytes:E9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1687 Bytes:91 08
|
|
INY ; PRG:$1689 Bytes:C8
|
|
CPY #$17 ; PRG:$168A Bytes:C0 17
|
|
BCC UpdateObjectRecordLoop_D680 ; PRG:$168C Bytes:90 F2
|
|
UpdateObjectRecordContinue_D68E:
|
|
LDY #$1C ; PRG:$168E Bytes:A0 1C
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1690 Bytes:B1 08
|
|
BEQ ObjectPathOnZero_D699 ; PRG:$1692 Bytes:F0 05
|
|
SEC ; PRG:$1694 Bytes:38
|
|
SBC #$01 ; PRG:$1695 Bytes:E9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1697 Bytes:91 08
|
|
ObjectPathOnZero_D699:
|
|
LDX #$08 ; PRG:$1699 Bytes:A2 08
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$169B Bytes:20 D3 CB
|
|
BPL ReadObjectRecordLoop_D65B ; PRG:$169E Bytes:10 BB
|
|
LDX $5E ; PRG:$16A0 Bytes:A6 5E
|
|
BNE ObjectPathOnNonZero_D6A8 ; PRG:$16A2 Bytes:D0 04
|
|
LDX #$05 ; PRG:$16A4 Bytes:A2 05
|
|
STX $5E ; PRG:$16A6 Bytes:86 5E
|
|
ObjectPathOnNonZero_D6A8:
|
|
RTS ; PRG:$16A8 Bytes:60
|
|
ReadObjectRecordOnZero_D6A9:
|
|
LDY #$15 ; PRG:$16A9 Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$16AB Bytes:B1 08
|
|
BNE ProcessObjectStateDispatch_D67A ; PRG:$16AD Bytes:D0 CB
|
|
JSR RunGameTaskRoutine_C8AA ; PRG:$16AF Bytes:20 AA C8
|
|
LDY #$00 ; PRG:$16B2 Bytes:A0 00
|
|
LDA ($04),Y ; PRG:$16B4 Bytes:B1 04
|
|
LSR A ; PRG:$16B6 Bytes:4A
|
|
TAX ; PRG:$16B7 Bytes:AA
|
|
DEX ; PRG:$16B8 Bytes:CA
|
|
BEQ ProcessObjectStateDispatch_D67A ; PRG:$16B9 Bytes:F0 BF
|
|
LDA $A6 ; PRG:$16BB Bytes:A5 A6
|
|
BNE UpdateObjectBufferOnNonZero_D6C0 ; PRG:$16BD Bytes:D0 01
|
|
TXA ; PRG:$16BF Bytes:8A
|
|
UpdateObjectBufferOnNonZero_D6C0:
|
|
STA $A6 ; PRG:$16C0 Bytes:85 A6
|
|
DEC $A6 ; PRG:$16C2 Bytes:C6 A6
|
|
ASL A ; PRG:$16C4 Bytes:0A
|
|
TAY ; PRG:$16C5 Bytes:A8
|
|
LDA ($04),Y ; PRG:$16C6 Bytes:B1 04
|
|
STA $02 ; PRG:$16C8 Bytes:85 02
|
|
INY ; PRG:$16CA Bytes:C8
|
|
LDA ($04),Y ; PRG:$16CB Bytes:B1 04
|
|
STA $03 ; PRG:$16CD Bytes:85 03
|
|
JSR UpdateObjectBufferRoutine_E0F9 ; PRG:$16CF Bytes:20 F9 E0
|
|
LDY #$05 ; PRG:$16D2 Bytes:A0 05
|
|
LDA #$00 ; PRG:$16D4 Bytes:A9 00
|
|
UpdateObjectRecordLoop_D6D6:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$16D6 Bytes:91 08
|
|
DEY ; PRG:$16D8 Bytes:88
|
|
BPL UpdateObjectRecordLoop_D6D6 ; PRG:$16D9 Bytes:10 FB
|
|
LDY #$09 ; PRG:$16DB Bytes:A0 09
|
|
LDA #$02 ; PRG:$16DD Bytes:A9 02
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$16DF Bytes:91 08
|
|
LDY #$01 ; PRG:$16E1 Bytes:A0 01
|
|
LDA WorkPtr0Lo ; PRG:$16E3 Bytes:A5 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$16E5 Bytes:91 08
|
|
LDY #$03 ; PRG:$16E7 Bytes:A0 03
|
|
LDA WorkPtr0Hi ; PRG:$16E9 Bytes:A5 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$16EB Bytes:91 08
|
|
LDY #$10 ; PRG:$16ED Bytes:A0 10
|
|
LDA $15 ; PRG:$16EF Bytes:A5 15
|
|
AND #$03 ; PRG:$16F1 Bytes:29 03
|
|
ORA #$30 ; PRG:$16F3 Bytes:09 30
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$16F5 Bytes:91 08
|
|
LDY #$15 ; PRG:$16F7 Bytes:A0 15
|
|
LDA #$0C ; PRG:$16F9 Bytes:A9 0C
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$16FB Bytes:91 08
|
|
INY ; PRG:$16FD Bytes:C8
|
|
LDA #$00 ; PRG:$16FE Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1700 Bytes:91 08
|
|
INY ; PRG:$1702 Bytes:C8
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1703 Bytes:91 08
|
|
INY ; PRG:$1705 Bytes:C8
|
|
LDA #$01 ; PRG:$1706 Bytes:A9 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1708 Bytes:91 08
|
|
LDA #$03 ; PRG:$170A Bytes:A9 03
|
|
STA $02 ; PRG:$170C Bytes:85 02
|
|
LDA #$80 ; PRG:$170E Bytes:A9 80
|
|
STA $00 ; PRG:$1710 Bytes:85 00
|
|
LDA #$04 ; PRG:$1712 Bytes:A9 04
|
|
STA $01 ; PRG:$1714 Bytes:85 01
|
|
ObjectPathLoop_D716:
|
|
LDY #$10 ; PRG:$1716 Bytes:A0 10
|
|
LDA ($00),Y ; PRG:$1718 Bytes:B1 00
|
|
CMP #$01 ; PRG:$171A Bytes:C9 01
|
|
BNE ObjectPathContinue_D72A ; PRG:$171C Bytes:D0 0C
|
|
LDY #$15 ; PRG:$171E Bytes:A0 15
|
|
LDA ($00),Y ; PRG:$1720 Bytes:B1 00
|
|
CMP #$20 ; PRG:$1722 Bytes:C9 20
|
|
BCS ObjectPathContinue_D72A ; PRG:$1724 Bytes:B0 04
|
|
LDA #$20 ; PRG:$1726 Bytes:A9 20
|
|
STA ($00),Y ; PRG:$1728 Bytes:91 00
|
|
ObjectPathContinue_D72A:
|
|
LDX #$00 ; PRG:$172A Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$172C Bytes:20 D3 CB
|
|
DEC $02 ; PRG:$172F Bytes:C6 02
|
|
BPL ObjectPathLoop_D716 ; PRG:$1731 Bytes:10 E3
|
|
JMP ProcessObjectStateDispatch_D59F ; PRG:$1733 Bytes:4C 9F D5
|
|
ObjectPathLoop_D736:
|
|
INY ; PRG:$1736 Bytes:C8
|
|
LDA #$01 ; PRG:$1737 Bytes:A9 01
|
|
BNE UpdateObjectRecordOnNonZero_D775 ; PRG:$1739 Bytes:D0 3A
|
|
UpdateObjectBufferDispatch_D73B:
|
|
AND #$03 ; PRG:$173B Bytes:29 03
|
|
STA $06 ; PRG:$173D Bytes:85 06
|
|
LDA $0F ; PRG:$173F Bytes:A5 0F
|
|
CLC ; PRG:$1741 Bytes:18
|
|
ADC #$06 ; PRG:$1742 Bytes:69 06
|
|
JSR ReadObjectRecordRoutine_E5AA ; PRG:$1744 Bytes:20 AA E5
|
|
BCS ReadObjectRecordContinue_D7A4 ; PRG:$1747 Bytes:B0 5B
|
|
CMP #$24 ; PRG:$1749 Bytes:C9 24
|
|
BEQ ReadObjectRecordContinue_D7A4 ; PRG:$174B Bytes:F0 57
|
|
CMP #$4E ; PRG:$174D Bytes:C9 4E
|
|
BCS ObjectPathOnCarry_D755 ; PRG:$174F Bytes:B0 04
|
|
CMP #$4A ; PRG:$1751 Bytes:C9 4A
|
|
BCS ReadObjectRecordContinue_D7A4 ; PRG:$1753 Bytes:B0 4F
|
|
ObjectPathOnCarry_D755:
|
|
CMP #$60 ; PRG:$1755 Bytes:C9 60
|
|
BCS ObjectPathOnCarry_D75D ; PRG:$1757 Bytes:B0 04
|
|
CMP #$50 ; PRG:$1759 Bytes:C9 50
|
|
BCS ReadObjectRecordContinue_D7A4 ; PRG:$175B Bytes:B0 47
|
|
ObjectPathOnCarry_D75D:
|
|
CMP #$FD ; PRG:$175D Bytes:C9 FD
|
|
BCS UpdateObjectRecordOnCarry_D765 ; PRG:$175F Bytes:B0 04
|
|
CMP #$F9 ; PRG:$1761 Bytes:C9 F9
|
|
BCS ReadObjectRecordContinue_D7A4 ; PRG:$1763 Bytes:B0 3F
|
|
UpdateObjectRecordOnCarry_D765:
|
|
LDA #$11 ; PRG:$1765 Bytes:A9 11
|
|
EOR $06 ; PRG:$1767 Bytes:45 06
|
|
LDY #$10 ; PRG:$1769 Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$176B Bytes:91 08
|
|
LDY #$16 ; PRG:$176D Bytes:A0 16
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$176F Bytes:B1 08
|
|
BNE ObjectPathLoop_D736 ; PRG:$1771 Bytes:D0 C3
|
|
LDA #$18 ; PRG:$1773 Bytes:A9 18
|
|
UpdateObjectRecordOnNonZero_D775:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1775 Bytes:91 08
|
|
ReadObjectRecordDispatch_D777:
|
|
LDY #$10 ; PRG:$1777 Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1779 Bytes:B1 08
|
|
PHA ; PRG:$177B Bytes:48
|
|
AND #$03 ; PRG:$177C Bytes:29 03
|
|
TAX ; PRG:$177E Bytes:AA
|
|
JSR UpdateObjectRecordRoutine_CD45 ; PRG:$177F Bytes:20 45 CD
|
|
PLA ; PRG:$1782 Bytes:68
|
|
ProcessObjectStateDispatch_D783:
|
|
AND #$F0 ; PRG:$1783 Bytes:29 F0
|
|
LSR A ; PRG:$1785 Bytes:4A
|
|
LSR A ; PRG:$1786 Bytes:4A
|
|
LSR A ; PRG:$1787 Bytes:4A
|
|
LSR A ; PRG:$1788 Bytes:4A
|
|
TAX ; PRG:$1789 Bytes:AA
|
|
DEX ; PRG:$178A Bytes:CA
|
|
LDA $5F,X ; PRG:$178B Bytes:B5 5F
|
|
BNE UpdateObjectRecordOnNonZero_D794 ; PRG:$178D Bytes:D0 05
|
|
LDA $D46A,X ; PRG:$178F Bytes:BD 6A D4
|
|
STA $5F,X ; PRG:$1792 Bytes:95 5F
|
|
UpdateObjectRecordOnNonZero_D794:
|
|
CMP $D46D,X ; PRG:$1794 Bytes:DD 6D D4
|
|
BCC ObjectPathOnNoCarry_D7A1 ; PRG:$1797 Bytes:90 08
|
|
LDY #$05 ; PRG:$1799 Bytes:A0 05
|
|
LDA #$01 ; PRG:$179B Bytes:A9 01
|
|
EOR (CurrentObjectPtrLo),Y ; PRG:$179D Bytes:51 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$179F Bytes:91 08
|
|
ObjectPathOnNoCarry_D7A1:
|
|
JMP ProcessObjectStateDispatch_D67A ; PRG:$17A1 Bytes:4C 7A D6
|
|
ReadObjectRecordContinue_D7A4:
|
|
LDY #$15 ; PRG:$17A4 Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$17A6 Bytes:B1 08
|
|
BEQ UpdateObjectRecordContinue_D814 ; PRG:$17A8 Bytes:F0 6A
|
|
LDY #$17 ; PRG:$17AA Bytes:A0 17
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$17AC Bytes:B1 08
|
|
BNE UpdateObjectRecordContinue_D814 ; PRG:$17AE Bytes:D0 64
|
|
LDA $06 ; PRG:$17B0 Bytes:A5 06
|
|
LDX #$01 ; PRG:$17B2 Bytes:A2 01
|
|
CMP #$02 ; PRG:$17B4 Bytes:C9 02
|
|
BCC TestObjectFieldOnNoCarry_D7B9 ; PRG:$17B6 Bytes:90 01
|
|
DEX ; PRG:$17B8 Bytes:CA
|
|
TestObjectFieldOnNoCarry_D7B9:
|
|
LDY $D470,X ; PRG:$17B9 Bytes:BC 70 D4
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$17BC Bytes:B1 08
|
|
LDY $D472,X ; PRG:$17BE Bytes:BC 72 D4
|
|
CMP (CurrentObjectPtrLo),Y ; PRG:$17C1 Bytes:D1 08
|
|
BNE ReadObjectRecordLoop_D80D ; PRG:$17C3 Bytes:D0 48
|
|
TXA ; PRG:$17C5 Bytes:8A
|
|
EOR #$01 ; PRG:$17C6 Bytes:49 01
|
|
TAX ; PRG:$17C8 Bytes:AA
|
|
LDY $D470,X ; PRG:$17C9 Bytes:BC 70 D4
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$17CC Bytes:B1 08
|
|
LDY $D472,X ; PRG:$17CE Bytes:BC 72 D4
|
|
CMP (CurrentObjectPtrLo),Y ; PRG:$17D1 Bytes:D1 08
|
|
LDA $06 ; PRG:$17D3 Bytes:A5 06
|
|
AND #$01 ; PRG:$17D5 Bytes:29 01
|
|
BCS ObjectPathOnCarry_D807 ; PRG:$17D7 Bytes:B0 2E
|
|
BEQ ObjectPathOnZero_D809 ; PRG:$17D9 Bytes:F0 2E
|
|
ObjectPathLoop_D7DB:
|
|
LDA #$00 ; PRG:$17DB Bytes:A9 00
|
|
ProcessObjectStateDispatch_D7DD:
|
|
TAX ; PRG:$17DD Bytes:AA
|
|
LDA $06 ; PRG:$17DE Bytes:A5 06
|
|
LDY #$02 ; PRG:$17E0 Bytes:A0 02
|
|
CMP #$02 ; PRG:$17E2 Bytes:C9 02
|
|
BCC ObjectPathOnNoCarry_D7E8 ; PRG:$17E4 Bytes:90 02
|
|
LDY #$04 ; PRG:$17E6 Bytes:A0 04
|
|
ObjectPathOnNoCarry_D7E8:
|
|
AND #$01 ; PRG:$17E8 Bytes:29 01
|
|
BNE UpdateObjectRecordOnNonZero_D7F0 ; PRG:$17EA Bytes:D0 04
|
|
INX ; PRG:$17EC Bytes:E8
|
|
INX ; PRG:$17ED Bytes:E8
|
|
INX ; PRG:$17EE Bytes:E8
|
|
INX ; PRG:$17EF Bytes:E8
|
|
UpdateObjectRecordOnNonZero_D7F0:
|
|
LDA $77 ; PRG:$17F0 Bytes:A5 77
|
|
BNE ObjectPathOnNonZero_D804 ; PRG:$17F2 Bytes:D0 10
|
|
CLC ; PRG:$17F4 Bytes:18
|
|
LDA $C0B9,X ; PRG:$17F5 Bytes:BD B9 C0
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$17F8 Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$17FA Bytes:91 08
|
|
DEY ; PRG:$17FC Bytes:88
|
|
LDA $C0B1,X ; PRG:$17FD Bytes:BD B1 C0
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$1800 Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1802 Bytes:91 08
|
|
ObjectPathOnNonZero_D804:
|
|
JMP ReadObjectRecordDispatch_D777 ; PRG:$1804 Bytes:4C 77 D7
|
|
ObjectPathOnCarry_D807:
|
|
BEQ ObjectPathLoop_D7DB ; PRG:$1807 Bytes:F0 D2
|
|
ObjectPathOnZero_D809:
|
|
LDA #$03 ; PRG:$1809 Bytes:A9 03
|
|
BNE ProcessObjectStateDispatch_D7DD ; PRG:$180B Bytes:D0 D0
|
|
ReadObjectRecordLoop_D80D:
|
|
LDY #$18 ; PRG:$180D Bytes:A0 18
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$180F Bytes:B1 08
|
|
JMP ProcessObjectStateDispatch_D7DD ; PRG:$1811 Bytes:4C DD D7
|
|
UpdateObjectRecordContinue_D814:
|
|
LDY #$18 ; PRG:$1814 Bytes:A0 18
|
|
LDA #$00 ; PRG:$1816 Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1818 Bytes:91 08
|
|
LDY #$03 ; PRG:$181A Bytes:A0 03
|
|
LDX #$08 ; PRG:$181C Bytes:A2 08
|
|
LDA $06 ; PRG:$181E Bytes:A5 06
|
|
CMP #$02 ; PRG:$1820 Bytes:C9 02
|
|
BCS ReadObjectRecordOnCarry_D828 ; PRG:$1822 Bytes:B0 04
|
|
LDY #$01 ; PRG:$1824 Bytes:A0 01
|
|
LDX #$11 ; PRG:$1826 Bytes:A2 11
|
|
ReadObjectRecordOnCarry_D828:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$1828 Bytes:B1 08
|
|
INY ; PRG:$182A Bytes:C8
|
|
STY $00 ; PRG:$182B Bytes:84 00
|
|
LDY #$09 ; PRG:$182D Bytes:A0 09
|
|
ObjectPathLoop_D82F:
|
|
CMP $D458,X ; PRG:$182F Bytes:DD 58 D4
|
|
BEQ ObjectPathOnZero_D83A ; PRG:$1832 Bytes:F0 06
|
|
DEX ; PRG:$1834 Bytes:CA
|
|
DEY ; PRG:$1835 Bytes:88
|
|
BNE ObjectPathLoop_D82F ; PRG:$1836 Bytes:D0 F7
|
|
BEQ ReadObjectRecordLoop_D80D ; PRG:$1838 Bytes:F0 D3
|
|
ObjectPathOnZero_D83A:
|
|
LDA $15 ; PRG:$183A Bytes:A5 15
|
|
CMP #$20 ; PRG:$183C Bytes:C9 20
|
|
BCC UpdateObjectRecordOnNoCarry_D842 ; PRG:$183E Bytes:90 02
|
|
LDA #$00 ; PRG:$1840 Bytes:A9 00
|
|
UpdateObjectRecordOnNoCarry_D842:
|
|
LDY #$15 ; PRG:$1842 Bytes:A0 15
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1844 Bytes:91 08
|
|
INY ; PRG:$1846 Bytes:C8
|
|
LDA #$04 ; PRG:$1847 Bytes:A9 04
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1849 Bytes:91 08
|
|
LDY #$10 ; PRG:$184B Bytes:A0 10
|
|
LDA $06 ; PRG:$184D Bytes:A5 06
|
|
ORA #$20 ; PRG:$184F Bytes:09 20
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$1851 Bytes:91 08
|
|
JMP ReadObjectRecordDispatch_D777 ; PRG:$1853 Bytes:4C 77 D7
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D856
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D856:
|
|
LDA #$07 ; PRG:$1856 Bytes:A9 07
|
|
STA $0E ; PRG:$1858 Bytes:85 0E
|
|
LDA #$00 ; PRG:$185A Bytes:A9 00
|
|
STA $00 ; PRG:$185C Bytes:85 00
|
|
LDA #$05 ; PRG:$185E Bytes:A9 05
|
|
STA $01 ; PRG:$1860 Bytes:85 01
|
|
UpdateObjectBufferLoop_D862:
|
|
LDA #$03 ; PRG:$1862 Bytes:A9 03
|
|
STA $0F ; PRG:$1864 Bytes:85 0F
|
|
LDA #$80 ; PRG:$1866 Bytes:A9 80
|
|
STA $02 ; PRG:$1868 Bytes:85 02
|
|
LDA #$04 ; PRG:$186A Bytes:A9 04
|
|
STA $03 ; PRG:$186C Bytes:85 03
|
|
ObjectPathLoop_D86E:
|
|
LDY #$10 ; PRG:$186E Bytes:A0 10
|
|
LDA ($00),Y ; PRG:$1870 Bytes:B1 00
|
|
BEQ ObjectPathContinue_D8A5 ; PRG:$1872 Bytes:F0 31
|
|
LDY #$05 ; PRG:$1874 Bytes:A0 05
|
|
LDA ($00),Y ; PRG:$1876 Bytes:B1 00
|
|
CMP #$08 ; PRG:$1878 Bytes:C9 08
|
|
BEQ ObjectPathOnZero_D888 ; PRG:$187A Bytes:F0 0C
|
|
CMP #$09 ; PRG:$187C Bytes:C9 09
|
|
BEQ ObjectPathOnZero_D888 ; PRG:$187E Bytes:F0 08
|
|
CMP #$12 ; PRG:$1880 Bytes:C9 12
|
|
BEQ ObjectPathOnZero_D888 ; PRG:$1882 Bytes:F0 04
|
|
CMP #$13 ; PRG:$1884 Bytes:C9 13
|
|
BNE ObjectPathContinue_D8A5 ; PRG:$1886 Bytes:D0 1D
|
|
ObjectPathOnZero_D888:
|
|
LDY #$10 ; PRG:$1888 Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$188A Bytes:B1 02
|
|
CMP #$02 ; PRG:$188C Bytes:C9 02
|
|
BCC ObjectPathContinue_D8A5 ; PRG:$188E Bytes:90 15
|
|
BPL UpdateObjectBufferOnPositive_D896 ; PRG:$1890 Bytes:10 04
|
|
CMP #$F0 ; PRG:$1892 Bytes:C9 F0
|
|
BCC ObjectPathContinue_D8A5 ; PRG:$1894 Bytes:90 0F
|
|
UpdateObjectBufferOnPositive_D896:
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$1896 Bytes:20 1C F7
|
|
BCC ObjectPathContinue_D8A5 ; PRG:$1899 Bytes:90 0A
|
|
LDY #$10 ; PRG:$189B Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$189D Bytes:B1 02
|
|
AND #$03 ; PRG:$189F Bytes:29 03
|
|
ORA #$40 ; PRG:$18A1 Bytes:09 40
|
|
STA ($02),Y ; PRG:$18A3 Bytes:91 02
|
|
ObjectPathContinue_D8A5:
|
|
LDX #$02 ; PRG:$18A5 Bytes:A2 02
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$18A7 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_D86E ; PRG:$18AA Bytes:10 C2
|
|
LDX #$00 ; PRG:$18AC Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$18AE Bytes:20 D3 CB
|
|
DEC $0E ; PRG:$18B1 Bytes:C6 0E
|
|
BPL UpdateObjectBufferLoop_D862 ; PRG:$18B3 Bytes:10 AD
|
|
RTS ; PRG:$18B5 Bytes:60
|
|
.byte $00, $02, $01, $03 ; PRG:$18B6 Bytes:00 02 01 03
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D8BA
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D8BA:
|
|
LDA #$01 ; PRG:$18BA Bytes:A9 01
|
|
STA $0E ; PRG:$18BC Bytes:85 0E
|
|
LDA #$40 ; PRG:$18BE Bytes:A9 40
|
|
STA $00 ; PRG:$18C0 Bytes:85 00
|
|
LDA #$04 ; PRG:$18C2 Bytes:A9 04
|
|
STA $01 ; PRG:$18C4 Bytes:85 01
|
|
UpdateObjectBufferLoop_D8C6:
|
|
LDA #$03 ; PRG:$18C6 Bytes:A9 03
|
|
STA $0F ; PRG:$18C8 Bytes:85 0F
|
|
LDA #$80 ; PRG:$18CA Bytes:A9 80
|
|
STA $02 ; PRG:$18CC Bytes:85 02
|
|
LDA #$04 ; PRG:$18CE Bytes:A9 04
|
|
STA $03 ; PRG:$18D0 Bytes:85 03
|
|
ObjectPathLoop_D8D2:
|
|
JSR ProcessObjectStateRoutine_D970 ; PRG:$18D2 Bytes:20 70 D9
|
|
BNE ProcessObjectStateDispatch_D904 ; PRG:$18D5 Bytes:D0 2D
|
|
LDY #$10 ; PRG:$18D7 Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$18D9 Bytes:B1 02
|
|
BPL ObjectPathOnPositive_D8E1 ; PRG:$18DB Bytes:10 04
|
|
CMP #$F0 ; PRG:$18DD Bytes:C9 F0
|
|
BCC ProcessObjectStateDispatch_D904 ; PRG:$18DF Bytes:90 23
|
|
ObjectPathOnPositive_D8E1:
|
|
CMP #$02 ; PRG:$18E1 Bytes:C9 02
|
|
BCC ProcessObjectStateDispatch_D904 ; PRG:$18E3 Bytes:90 1F
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$18E5 Bytes:20 1C F7
|
|
BCC ProcessObjectStateDispatch_D904 ; PRG:$18E8 Bytes:90 1A
|
|
LDY #$10 ; PRG:$18EA Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$18EC Bytes:B1 02
|
|
CMP #$30 ; PRG:$18EE Bytes:C9 30
|
|
BCS ObjectPathOnCarry_D928 ; PRG:$18F0 Bytes:B0 36
|
|
UpdateObjectBufferLoop_D8F2:
|
|
LDA #$23 ; PRG:$18F2 Bytes:A9 23
|
|
STA $90,X ; PRG:$18F4 Bytes:95 90
|
|
LDA ($02),Y ; PRG:$18F6 Bytes:B1 02
|
|
AND #$03 ; PRG:$18F8 Bytes:29 03
|
|
ORA #$F0 ; PRG:$18FA Bytes:09 F0
|
|
STA ($02),Y ; PRG:$18FC Bytes:91 02
|
|
LDY #$15 ; PRG:$18FE Bytes:A0 15
|
|
LDA #$08 ; PRG:$1900 Bytes:A9 08
|
|
STA ($02),Y ; PRG:$1902 Bytes:91 02
|
|
ProcessObjectStateDispatch_D904:
|
|
LDX #$02 ; PRG:$1904 Bytes:A2 02
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$1906 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_D8D2 ; PRG:$1909 Bytes:10 C7
|
|
LDA #$00 ; PRG:$190B Bytes:A9 00
|
|
STA $00 ; PRG:$190D Bytes:85 00
|
|
LDA #$04 ; PRG:$190F Bytes:A9 04
|
|
STA $01 ; PRG:$1911 Bytes:85 01
|
|
DEC $0E ; PRG:$1913 Bytes:C6 0E
|
|
BPL UpdateObjectBufferLoop_D8C6 ; PRG:$1915 Bytes:10 AF
|
|
RTS ; PRG:$1917 Bytes:60
|
|
UpdateObjectBufferLoop_D918:
|
|
LDA ($02),Y ; PRG:$1918 Bytes:B1 02
|
|
AND #$03 ; PRG:$191A Bytes:29 03
|
|
ORA #$30 ; PRG:$191C Bytes:09 30
|
|
STA ($02),Y ; PRG:$191E Bytes:91 02
|
|
LDY #$15 ; PRG:$1920 Bytes:A0 15
|
|
LDA #$14 ; PRG:$1922 Bytes:A9 14
|
|
STA ($02),Y ; PRG:$1924 Bytes:91 02
|
|
BNE ProcessObjectStateDispatch_D904 ; PRG:$1926 Bytes:D0 DC
|
|
ObjectPathOnCarry_D928:
|
|
CMP #$40 ; PRG:$1928 Bytes:C9 40
|
|
BCC UpdateObjectBufferLoop_D918 ; PRG:$192A Bytes:90 EC
|
|
CMP #$F0 ; PRG:$192C Bytes:C9 F0
|
|
BCS UpdateObjectBufferLoop_D8F2 ; PRG:$192E Bytes:B0 C2
|
|
JSR ProcessObjectStateRoutine_D94D ; PRG:$1930 Bytes:20 4D D9
|
|
TAX ; PRG:$1933 Bytes:AA
|
|
EOR ($02),Y ; PRG:$1934 Bytes:51 02
|
|
AND #$02 ; PRG:$1936 Bytes:29 02
|
|
BEQ UpdateObjectBufferOnZero_D93D ; PRG:$1938 Bytes:F0 03
|
|
LDA ($02),Y ; PRG:$193A Bytes:B1 02
|
|
TAX ; PRG:$193C Bytes:AA
|
|
UpdateObjectBufferOnZero_D93D:
|
|
TXA ; PRG:$193D Bytes:8A
|
|
AND #$03 ; PRG:$193E Bytes:29 03
|
|
ORA #$80 ; PRG:$1940 Bytes:09 80
|
|
STA ($02),Y ; PRG:$1942 Bytes:91 02
|
|
LDY #$1B ; PRG:$1944 Bytes:A0 1B
|
|
LDA $0E ; PRG:$1946 Bytes:A5 0E
|
|
STA ($02),Y ; PRG:$1948 Bytes:91 02
|
|
JMP ProcessObjectStateDispatch_D904 ; PRG:$194A Bytes:4C 04 D9
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D94D
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D94D:
|
|
LDA ($00),Y ; PRG:$194D Bytes:B1 00
|
|
BPL ObjectPathContinue_D96D ; PRG:$194F Bytes:10 1C
|
|
CMP #$81 ; PRG:$1951 Bytes:C9 81
|
|
PHP ; PRG:$1953 Bytes:08
|
|
LDA #$08 ; PRG:$1954 Bytes:A9 08
|
|
BCC ObjectPathOnNoCarry_D95A ; PRG:$1956 Bytes:90 02
|
|
LDA #$38 ; PRG:$1958 Bytes:A9 38
|
|
ObjectPathOnNoCarry_D95A:
|
|
LDY #$1B ; PRG:$195A Bytes:A0 1B
|
|
CLC ; PRG:$195C Bytes:18
|
|
ADC ($00),Y ; PRG:$195D Bytes:71 00
|
|
ROL A ; PRG:$195F Bytes:2A
|
|
ROL A ; PRG:$1960 Bytes:2A
|
|
ROL A ; PRG:$1961 Bytes:2A
|
|
AND #$03 ; PRG:$1962 Bytes:29 03
|
|
TAX ; PRG:$1964 Bytes:AA
|
|
LDA $D8B6,X ; PRG:$1965 Bytes:BD B6 D8
|
|
PLP ; PRG:$1968 Bytes:28
|
|
BCC ObjectPathContinue_D96D ; PRG:$1969 Bytes:90 02
|
|
EOR #$01 ; PRG:$196B Bytes:49 01
|
|
ObjectPathContinue_D96D:
|
|
LDY #$10 ; PRG:$196D Bytes:A0 10
|
|
RTS ; PRG:$196F Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D970
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D970:
|
|
LDX $0E ; PRG:$1970 Bytes:A6 0E
|
|
LDA $90,X ; PRG:$1972 Bytes:B5 90
|
|
BNE ObjectPathOnNonZero_D978 ; PRG:$1974 Bytes:D0 02
|
|
LDA $D0,X ; PRG:$1976 Bytes:B5 D0
|
|
ObjectPathOnNonZero_D978:
|
|
RTS ; PRG:$1978 Bytes:60
|
|
.byte $03, $FD ; PRG:$1979 Bytes:03 FD
|
|
;------------------------------------------------------------
|
|
; ObjectPath_D97B
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_D97B:
|
|
LDA #$02 ; PRG:$197B Bytes:A9 02
|
|
STA $0E ; PRG:$197D Bytes:85 0E
|
|
LDA #$80 ; PRG:$197F Bytes:A9 80
|
|
STA $00 ; PRG:$1981 Bytes:85 00
|
|
LDA #$04 ; PRG:$1983 Bytes:A9 04
|
|
STA $01 ; PRG:$1985 Bytes:85 01
|
|
UpdateObjectBufferLoop_D987:
|
|
LDA $0E ; PRG:$1987 Bytes:A5 0E
|
|
STA $0F ; PRG:$1989 Bytes:85 0F
|
|
CLC ; PRG:$198B Bytes:18
|
|
LDA #$20 ; PRG:$198C Bytes:A9 20
|
|
ADC $00 ; PRG:$198E Bytes:65 00
|
|
STA $02 ; PRG:$1990 Bytes:85 02
|
|
LDA #$00 ; PRG:$1992 Bytes:A9 00
|
|
ADC $01 ; PRG:$1994 Bytes:65 01
|
|
STA $03 ; PRG:$1996 Bytes:85 03
|
|
ObjectPathLoop_D998:
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$1998 Bytes:20 1C F7
|
|
BCC ObjectPathOnNoCarry_D9A0 ; PRG:$199B Bytes:90 03
|
|
JSR ProcessObjectStateRoutine_D9B1 ; PRG:$199D Bytes:20 B1 D9
|
|
ObjectPathOnNoCarry_D9A0:
|
|
LDX #$02 ; PRG:$19A0 Bytes:A2 02
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$19A2 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_D998 ; PRG:$19A5 Bytes:10 F1
|
|
LDX #$00 ; PRG:$19A7 Bytes:A2 00
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$19A9 Bytes:20 D3 CB
|
|
DEC $0E ; PRG:$19AC Bytes:C6 0E
|
|
BPL UpdateObjectBufferLoop_D987 ; PRG:$19AE Bytes:10 D7
|
|
RTS ; PRG:$19B0 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_D9B1
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_D9B1:
|
|
LDY #$10 ; PRG:$19B1 Bytes:A0 10
|
|
LDA ($00),Y ; PRG:$19B3 Bytes:B1 00
|
|
CMP #$20 ; PRG:$19B5 Bytes:C9 20
|
|
BCS ObjectPathContinue_D9DE ; PRG:$19B7 Bytes:B0 25
|
|
LDA ($02),Y ; PRG:$19B9 Bytes:B1 02
|
|
CMP #$20 ; PRG:$19BB Bytes:C9 20
|
|
BCS ObjectPathOnCarry_D9CB ; PRG:$19BD Bytes:B0 0C
|
|
EOR ($00),Y ; PRG:$19BF Bytes:51 00
|
|
AND #$02 ; PRG:$19C1 Bytes:29 02
|
|
BNE ObjectPathOnNonZero_D9CF ; PRG:$19C3 Bytes:D0 0A
|
|
LDY #$1C ; PRG:$19C5 Bytes:A0 1C
|
|
LDA ($00),Y ; PRG:$19C7 Bytes:B1 00
|
|
BNE ObjectPathContinue_D9DE ; PRG:$19C9 Bytes:D0 13
|
|
ObjectPathOnCarry_D9CB:
|
|
JSR UpdateObjectBufferRoutine_D9E2 ; PRG:$19CB Bytes:20 E2 D9
|
|
RTS ; PRG:$19CE Bytes:60
|
|
ObjectPathOnNonZero_D9CF:
|
|
JSR UpdateObjectBufferRoutine_D9E2 ; PRG:$19CF Bytes:20 E2 D9
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$19D2 Bytes:20 1C F7
|
|
BCC ObjectPathOnNoCarry_D9E1 ; PRG:$19D5 Bytes:90 0A
|
|
JSR UpdateObjectBufferRoutine_D9E2 ; PRG:$19D7 Bytes:20 E2 D9
|
|
LDA #$00 ; PRG:$19DA Bytes:A9 00
|
|
STA ($00),Y ; PRG:$19DC Bytes:91 00
|
|
ObjectPathContinue_D9DE:
|
|
JSR UpdateObjectBufferRoutine_DA04 ; PRG:$19DE Bytes:20 04 DA
|
|
ObjectPathOnNoCarry_D9E1:
|
|
RTS ; PRG:$19E1 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_D9E2
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_D9E2:
|
|
LDY #$10 ; PRG:$19E2 Bytes:A0 10
|
|
LDA ($00),Y ; PRG:$19E4 Bytes:B1 00
|
|
EOR #$01 ; PRG:$19E6 Bytes:49 01
|
|
STA ($00),Y ; PRG:$19E8 Bytes:91 00
|
|
LDY #$01 ; PRG:$19EA Bytes:A0 01
|
|
CMP #$12 ; PRG:$19EC Bytes:C9 12
|
|
BCC ObjectPathOnNoCarry_D9F2 ; PRG:$19EE Bytes:90 02
|
|
LDY #$03 ; PRG:$19F0 Bytes:A0 03
|
|
ObjectPathOnNoCarry_D9F2:
|
|
AND #$01 ; PRG:$19F2 Bytes:29 01
|
|
TAX ; PRG:$19F4 Bytes:AA
|
|
LDA $D979,X ; PRG:$19F5 Bytes:BD 79 D9
|
|
CLC ; PRG:$19F8 Bytes:18
|
|
ADC ($00),Y ; PRG:$19F9 Bytes:71 00
|
|
STA ($00),Y ; PRG:$19FB Bytes:91 00
|
|
LDY #$1C ; PRG:$19FD Bytes:A0 1C
|
|
LDA #$05 ; PRG:$19FF Bytes:A9 05
|
|
STA ($00),Y ; PRG:$1A01 Bytes:91 00
|
|
RTS ; PRG:$1A03 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_DA04
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_DA04:
|
|
LDY #$10 ; PRG:$1A04 Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$1A06 Bytes:B1 02
|
|
EOR #$01 ; PRG:$1A08 Bytes:49 01
|
|
STA ($02),Y ; PRG:$1A0A Bytes:91 02
|
|
LDY #$01 ; PRG:$1A0C Bytes:A0 01
|
|
CMP #$12 ; PRG:$1A0E Bytes:C9 12
|
|
BCC ObjectPathOnNoCarry_DA14 ; PRG:$1A10 Bytes:90 02
|
|
LDY #$03 ; PRG:$1A12 Bytes:A0 03
|
|
ObjectPathOnNoCarry_DA14:
|
|
AND #$01 ; PRG:$1A14 Bytes:29 01
|
|
TAX ; PRG:$1A16 Bytes:AA
|
|
LDA $D979,X ; PRG:$1A17 Bytes:BD 79 D9
|
|
CLC ; PRG:$1A1A Bytes:18
|
|
ADC ($02),Y ; PRG:$1A1B Bytes:71 02
|
|
STA ($02),Y ; PRG:$1A1D Bytes:91 02
|
|
LDY #$1C ; PRG:$1A1F Bytes:A0 1C
|
|
LDA #$05 ; PRG:$1A21 Bytes:A9 05
|
|
STA ($02),Y ; PRG:$1A23 Bytes:91 02
|
|
RTS ; PRG:$1A25 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_DA26
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_DA26:
|
|
LDA $77 ; PRG:$1A26 Bytes:A5 77
|
|
BNE ObjectPathContinue_DA8A ; PRG:$1A28 Bytes:D0 60
|
|
LDA $64 ; PRG:$1A2A Bytes:A5 64
|
|
BNE ObjectPathContinue_DA8A ; PRG:$1A2C Bytes:D0 5C
|
|
LDA $2E ; PRG:$1A2E Bytes:A5 2E
|
|
BNE ObjectPathOnNonZero_DA36 ; PRG:$1A30 Bytes:D0 04
|
|
LDA $2F ; PRG:$1A32 Bytes:A5 2F
|
|
BEQ ObjectPathContinue_DA8A ; PRG:$1A34 Bytes:F0 54
|
|
ObjectPathOnNonZero_DA36:
|
|
LDX #$07 ; PRG:$1A36 Bytes:A2 07
|
|
LDA $4C ; PRG:$1A38 Bytes:A5 4C
|
|
BEQ ObjectPathOnZero_DA3E ; PRG:$1A3A Bytes:F0 02
|
|
LDX #$06 ; PRG:$1A3C Bytes:A2 06
|
|
ObjectPathOnZero_DA3E:
|
|
STX $64 ; PRG:$1A3E Bytes:86 64
|
|
LDA #$01 ; PRG:$1A40 Bytes:A9 01
|
|
STA $00 ; PRG:$1A42 Bytes:85 00
|
|
LDA #$02 ; PRG:$1A44 Bytes:A9 02
|
|
STA $01 ; PRG:$1A46 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F408 ; PRG:$1A48 Bytes:20 08 F4
|
|
LDA $2F ; PRG:$1A4B Bytes:A5 2F
|
|
BNE ObjectPathLoop_DA85 ; PRG:$1A4D Bytes:D0 36
|
|
LDA $2E ; PRG:$1A4F Bytes:A5 2E
|
|
BEQ ObjectPathOnZero_DA65 ; PRG:$1A51 Bytes:F0 12
|
|
CMP #$02 ; PRG:$1A53 Bytes:C9 02
|
|
BNE ObjectPathLoop_DA85 ; PRG:$1A55 Bytes:D0 2E
|
|
LDA #$01 ; PRG:$1A57 Bytes:A9 01
|
|
STA $64 ; PRG:$1A59 Bytes:85 64
|
|
LDA $8F ; PRG:$1A5B Bytes:A5 8F
|
|
BNE ObjectPathLoop_DA85 ; PRG:$1A5D Bytes:D0 26
|
|
LDA #$08 ; PRG:$1A5F Bytes:A9 08
|
|
STA $FB ; PRG:$1A61 Bytes:85 FB
|
|
BNE ObjectPathLoop_DA85 ; PRG:$1A63 Bytes:D0 20
|
|
ObjectPathOnZero_DA65:
|
|
LDA $8F ; PRG:$1A65 Bytes:A5 8F
|
|
BNE ObjectPathOnNonZero_DA8B ; PRG:$1A67 Bytes:D0 22
|
|
LDA #$01 ; PRG:$1A69 Bytes:A9 01
|
|
STA $A1 ; PRG:$1A6B Bytes:85 A1
|
|
STA $A0 ; PRG:$1A6D Bytes:85 A0
|
|
LDA #$23 ; PRG:$1A6F Bytes:A9 23
|
|
LDX $90 ; PRG:$1A71 Bytes:A6 90
|
|
CPX #$01 ; PRG:$1A73 Bytes:E0 01
|
|
BCS ObjectPathOnCarry_DA79 ; PRG:$1A75 Bytes:B0 02
|
|
STA $90 ; PRG:$1A77 Bytes:85 90
|
|
ObjectPathOnCarry_DA79:
|
|
LDX $91 ; PRG:$1A79 Bytes:A6 91
|
|
CPX #$01 ; PRG:$1A7B Bytes:E0 01
|
|
BCS ObjectPathOnCarry_DA81 ; PRG:$1A7D Bytes:B0 02
|
|
STA $91 ; PRG:$1A7F Bytes:85 91
|
|
ObjectPathOnCarry_DA81:
|
|
LDA #$80 ; PRG:$1A81 Bytes:A9 80
|
|
STA $FB ; PRG:$1A83 Bytes:85 FB
|
|
ObjectPathLoop_DA85:
|
|
LDA #$82 ; PRG:$1A85 Bytes:A9 82
|
|
JSR ProcessResourceStateRoutine_F31A ; PRG:$1A87 Bytes:20 1A F3
|
|
ObjectPathContinue_DA8A:
|
|
RTS ; PRG:$1A8A Bytes:60
|
|
ObjectPathOnNonZero_DA8B:
|
|
LDA #$23 ; PRG:$1A8B Bytes:A9 23
|
|
STA $78 ; PRG:$1A8D Bytes:85 78
|
|
BNE ObjectPathLoop_DA85 ; PRG:$1A8F Bytes:D0 F4
|
|
;------------------------------------------------------------
|
|
; ObjectPath_DA91
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_DA91:
|
|
LDA $0401 ; PRG:$1A91 Bytes:AD 01 04
|
|
LDY $0403 ; PRG:$1A94 Bytes:AC 03 04
|
|
LDX $D0 ; PRG:$1A97 Bytes:A6 D0
|
|
BEQ ObjectPathOnZero_DA9F ; PRG:$1A99 Bytes:F0 04
|
|
LDA $11 ; PRG:$1A9B Bytes:A5 11
|
|
LDY $12 ; PRG:$1A9D Bytes:A4 12
|
|
ObjectPathOnZero_DA9F:
|
|
STA $0499 ; PRG:$1A9F Bytes:8D 99 04
|
|
STY $049A ; PRG:$1AA2 Bytes:8C 9A 04
|
|
STA $04D9 ; PRG:$1AA5 Bytes:8D D9 04
|
|
STY $04DA ; PRG:$1AA8 Bytes:8C DA 04
|
|
LDX $4C ; PRG:$1AAB Bytes:A6 4C
|
|
BEQ ObjectPathOnZero_DAB5 ; PRG:$1AAD Bytes:F0 06
|
|
LDA $0441 ; PRG:$1AAF Bytes:AD 41 04
|
|
LDY $0443 ; PRG:$1AB2 Bytes:AC 43 04
|
|
ObjectPathOnZero_DAB5:
|
|
LDX $D1 ; PRG:$1AB5 Bytes:A6 D1
|
|
BEQ ObjectPathOnZero_DABD ; PRG:$1AB7 Bytes:F0 04
|
|
LDA $13 ; PRG:$1AB9 Bytes:A5 13
|
|
LDY $14 ; PRG:$1ABB Bytes:A4 14
|
|
ObjectPathOnZero_DABD:
|
|
STA $04B9 ; PRG:$1ABD Bytes:8D B9 04
|
|
STY $04BA ; PRG:$1AC0 Bytes:8C BA 04
|
|
STA $04F9 ; PRG:$1AC3 Bytes:8D F9 04
|
|
STY $04FA ; PRG:$1AC6 Bytes:8C FA 04
|
|
RTS ; PRG:$1AC9 Bytes:60
|
|
.byte $0C, $FC, $00, $00, $00, $00, $0C, $FC, $00, $F0, $00, $08, $08, $00, $F0, $00 ; PRG:$1ACA Bytes:0C FC 00 00 00 00 0C FC 00 F0 00 08 08 00 F0 00
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecord_DADA
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecord_DADA:
|
|
LDX $0A ; PRG:$1ADA Bytes:A6 0A
|
|
LDA $46,X ; PRG:$1ADC Bytes:B5 46
|
|
AND #$C0 ; PRG:$1ADE Bytes:29 C0
|
|
BEQ ObjectPathContinue_DB27 ; PRG:$1AE0 Bytes:F0 45
|
|
LDA $DA,X ; PRG:$1AE2 Bytes:B5 DA
|
|
CMP #$02 ; PRG:$1AE4 Bytes:C9 02
|
|
BEQ ObjectPathContinue_DB27 ; PRG:$1AE6 Bytes:F0 3F
|
|
LDA #$20 ; PRG:$1AE8 Bytes:A9 20
|
|
STA $07 ; PRG:$1AEA Bytes:85 07
|
|
LSR A ; PRG:$1AEC Bytes:4A
|
|
STA $6C,X ; PRG:$1AED Bytes:95 6C
|
|
LDA $06 ; PRG:$1AEF Bytes:A5 06
|
|
BMI ObjectPathOnNegative_DB28 ; PRG:$1AF1 Bytes:30 35
|
|
AND #$03 ; PRG:$1AF3 Bytes:29 03
|
|
TAX ; PRG:$1AF5 Bytes:AA
|
|
LSR A ; PRG:$1AF6 Bytes:4A
|
|
EOR #$01 ; PRG:$1AF7 Bytes:49 01
|
|
STA $0D ; PRG:$1AF9 Bytes:85 0D
|
|
LDY #$01 ; PRG:$1AFB Bytes:A0 01
|
|
LDA $DACA,X ; PRG:$1AFD Bytes:BD CA DA
|
|
CLC ; PRG:$1B00 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$1B01 Bytes:71 08
|
|
STA $00 ; PRG:$1B03 Bytes:85 00
|
|
LDY #$03 ; PRG:$1B05 Bytes:A0 03
|
|
LDA $DACE,X ; PRG:$1B07 Bytes:BD CE DA
|
|
ReadObjectRecordLoop_DB0A:
|
|
CLC ; PRG:$1B0A Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$1B0B Bytes:71 08
|
|
STA $01 ; PRG:$1B0D Bytes:85 01
|
|
LDA #$00 ; PRG:$1B0F Bytes:A9 00
|
|
STA $02 ; PRG:$1B11 Bytes:85 02
|
|
STA $0E ; PRG:$1B13 Bytes:85 0E
|
|
JSR ProcessObjectStateRoutine_CE50 ; PRG:$1B15 Bytes:20 50 CE
|
|
BCS ObjectPathContinue_DB27 ; PRG:$1B18 Bytes:B0 0D
|
|
LDX $0A ; PRG:$1B1A Bytes:A6 0A
|
|
INC $DA,X ; PRG:$1B1C Bytes:F6 DA
|
|
LDY #$15 ; PRG:$1B1E Bytes:A0 15
|
|
TXA ; PRG:$1B20 Bytes:8A
|
|
STA ($04),Y ; PRG:$1B21 Bytes:91 04
|
|
LDA #$40 ; PRG:$1B23 Bytes:A9 40
|
|
STA $FF ; PRG:$1B25 Bytes:85 FF
|
|
ObjectPathContinue_DB27:
|
|
RTS ; PRG:$1B27 Bytes:60
|
|
ObjectPathOnNegative_DB28:
|
|
CMP #$81 ; PRG:$1B28 Bytes:C9 81
|
|
LDA #$08 ; PRG:$1B2A Bytes:A9 08
|
|
BCC ReadObjectRecordOnNoCarry_DB30 ; PRG:$1B2C Bytes:90 02
|
|
LDA #$38 ; PRG:$1B2E Bytes:A9 38
|
|
ReadObjectRecordOnNoCarry_DB30:
|
|
LDY #$1B ; PRG:$1B30 Bytes:A0 1B
|
|
CLC ; PRG:$1B32 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$1B33 Bytes:71 08
|
|
ROL A ; PRG:$1B35 Bytes:2A
|
|
ROL A ; PRG:$1B36 Bytes:2A
|
|
ROL A ; PRG:$1B37 Bytes:2A
|
|
AND #$03 ; PRG:$1B38 Bytes:29 03
|
|
TAX ; PRG:$1B3A Bytes:AA
|
|
AND #$01 ; PRG:$1B3B Bytes:29 01
|
|
EOR #$01 ; PRG:$1B3D Bytes:49 01
|
|
STA $0D ; PRG:$1B3F Bytes:85 0D
|
|
LDY #$21 ; PRG:$1B41 Bytes:A0 21
|
|
CLC ; PRG:$1B43 Bytes:18
|
|
LDA $DAD2,X ; PRG:$1B44 Bytes:BD D2 DA
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$1B47 Bytes:71 08
|
|
STA $00 ; PRG:$1B49 Bytes:85 00
|
|
LDA $DAD6,X ; PRG:$1B4B Bytes:BD D6 DA
|
|
LDY #$23 ; PRG:$1B4E Bytes:A0 23
|
|
BNE ReadObjectRecordLoop_DB0A ; PRG:$1B50 Bytes:D0 B8
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_DB52
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_DB52:
|
|
LDA $67 ; PRG:$1B52 Bytes:A5 67
|
|
BNE ObjectPathContinue_DBC3 ; PRG:$1B54 Bytes:D0 6D
|
|
LDA $90 ; PRG:$1B56 Bytes:A5 90
|
|
BNE ObjectPathContinue_DBC3 ; PRG:$1B58 Bytes:D0 69
|
|
LDA $91 ; PRG:$1B5A Bytes:A5 91
|
|
BNE ObjectPathContinue_DBC3 ; PRG:$1B5C Bytes:D0 65
|
|
LDA $D0 ; PRG:$1B5E Bytes:A5 D0
|
|
BNE ObjectPathContinue_DBC3 ; PRG:$1B60 Bytes:D0 61
|
|
LDA $D1 ; PRG:$1B62 Bytes:A5 D1
|
|
BNE ObjectPathContinue_DBC3 ; PRG:$1B64 Bytes:D0 5D
|
|
LDA #$00 ; PRG:$1B66 Bytes:A9 00
|
|
STA $00 ; PRG:$1B68 Bytes:85 00
|
|
LDA #$04 ; PRG:$1B6A Bytes:A9 04
|
|
STA $01 ; PRG:$1B6C Bytes:85 01
|
|
LDA #$40 ; PRG:$1B6E Bytes:A9 40
|
|
STA $02 ; PRG:$1B70 Bytes:85 02
|
|
LDA #$04 ; PRG:$1B72 Bytes:A9 04
|
|
STA $03 ; PRG:$1B74 Bytes:85 03
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$1B76 Bytes:20 1C F7
|
|
BCC ObjectPathContinue_DBC3 ; PRG:$1B79 Bytes:90 48
|
|
JSR ProcessObjectStateRoutine_DB8A ; PRG:$1B7B Bytes:20 8A DB
|
|
LDA #$40 ; PRG:$1B7E Bytes:A9 40
|
|
STA $00 ; PRG:$1B80 Bytes:85 00
|
|
LDA #$04 ; PRG:$1B82 Bytes:A9 04
|
|
STA $01 ; PRG:$1B84 Bytes:85 01
|
|
LDA #$08 ; PRG:$1B86 Bytes:A9 08
|
|
STA $FF ; PRG:$1B88 Bytes:85 FF
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_DB8A
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_DB8A:
|
|
LDY #$10 ; PRG:$1B8A Bytes:A0 10
|
|
LDA ($00),Y ; PRG:$1B8C Bytes:B1 00
|
|
BMI UpdateObjectBufferOnNegative_DBA7 ; PRG:$1B8E Bytes:30 17
|
|
CMP #$04 ; PRG:$1B90 Bytes:C9 04
|
|
BCS ObjectPathContinue_DBC3 ; PRG:$1B92 Bytes:B0 2F
|
|
TAX ; PRG:$1B94 Bytes:AA
|
|
LDY $E16F,X ; PRG:$1B95 Bytes:BC 6F E1
|
|
SEC ; PRG:$1B98 Bytes:38
|
|
LDA #$00 ; PRG:$1B99 Bytes:A9 00
|
|
SBC ($00),Y ; PRG:$1B9B Bytes:F1 00
|
|
STA ($00),Y ; PRG:$1B9D Bytes:91 00
|
|
DEY ; PRG:$1B9F Bytes:88
|
|
LDA #$00 ; PRG:$1BA0 Bytes:A9 00
|
|
SBC ($00),Y ; PRG:$1BA2 Bytes:F1 00
|
|
STA ($00),Y ; PRG:$1BA4 Bytes:91 00
|
|
TXA ; PRG:$1BA6 Bytes:8A
|
|
UpdateObjectBufferOnNegative_DBA7:
|
|
LDY #$18 ; PRG:$1BA7 Bytes:A0 18
|
|
STY $67 ; PRG:$1BA9 Bytes:84 67
|
|
EOR #$01 ; PRG:$1BAB Bytes:49 01
|
|
LDY #$10 ; PRG:$1BAD Bytes:A0 10
|
|
STA ($00),Y ; PRG:$1BAF Bytes:91 00
|
|
LDA #$0A ; PRG:$1BB1 Bytes:A9 0A
|
|
STA $56 ; PRG:$1BB3 Bytes:85 56
|
|
LDY #$02 ; PRG:$1BB5 Bytes:A0 02
|
|
LDX #$10 ; PRG:$1BB7 Bytes:A2 10
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1BB9 Bytes:20 AE D1
|
|
LDY #$03 ; PRG:$1BBC Bytes:A0 03
|
|
LDX #$14 ; PRG:$1BBE Bytes:A2 14
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1BC0 Bytes:20 AE D1
|
|
ObjectPathContinue_DBC3:
|
|
RTS ; PRG:$1BC3 Bytes:60
|
|
.byte $A8, $B0, $B8 ; PRG:$1BC4 Bytes:A8 B0 B8
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_DBC7
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_DBC7:
|
|
LDA #$07 ; PRG:$1BC7 Bytes:A9 07
|
|
STA $0F ; PRG:$1BC9 Bytes:85 0F
|
|
LDA #$00 ; PRG:$1BCB Bytes:A9 00
|
|
STA $02 ; PRG:$1BCD Bytes:85 02
|
|
LDA #$06 ; PRG:$1BCF Bytes:A9 06
|
|
STA $03 ; PRG:$1BD1 Bytes:85 03
|
|
ObjectPathLoop_DBD3:
|
|
LDY #$10 ; PRG:$1BD3 Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$1BD5 Bytes:B1 02
|
|
TAX ; PRG:$1BD7 Bytes:AA
|
|
BEQ ObjectPathLoop_DC36 ; PRG:$1BD8 Bytes:F0 5C
|
|
DEX ; PRG:$1BDA Bytes:CA
|
|
TXA ; PRG:$1BDB Bytes:8A
|
|
STA ($02),Y ; PRG:$1BDC Bytes:91 02
|
|
LDY #$00 ; PRG:$1BDE Bytes:A0 00
|
|
LDA ($02),Y ; PRG:$1BE0 Bytes:B1 02
|
|
BMI ObjectPathOnNegative_DC3E ; PRG:$1BE2 Bytes:30 5A
|
|
LDY #$05 ; PRG:$1BE4 Bytes:A0 05
|
|
LDA #$08 ; PRG:$1BE6 Bytes:A9 08
|
|
CPX #$1C ; PRG:$1BE8 Bytes:E0 1C
|
|
BEQ ObjectPathOnZero_DC34 ; PRG:$1BEA Bytes:F0 48
|
|
LDA #$09 ; PRG:$1BEC Bytes:A9 09
|
|
CPX #$14 ; PRG:$1BEE Bytes:E0 14
|
|
BEQ ObjectPathOnZero_DC34 ; PRG:$1BF0 Bytes:F0 42
|
|
LDA #$01 ; PRG:$1BF2 Bytes:A9 01
|
|
CPX #$01 ; PRG:$1BF4 Bytes:E0 01
|
|
BEQ ObjectPathLoop_DC2E ; PRG:$1BF6 Bytes:F0 36
|
|
CPX #$00 ; PRG:$1BF8 Bytes:E0 00
|
|
BNE ObjectPathLoop_DC36 ; PRG:$1BFA Bytes:D0 3A
|
|
LDY #$01 ; PRG:$1BFC Bytes:A0 01
|
|
LDA ($02),Y ; PRG:$1BFE Bytes:B1 02
|
|
SEC ; PRG:$1C00 Bytes:38
|
|
SBC #$04 ; PRG:$1C01 Bytes:E9 04
|
|
STA $04 ; PRG:$1C03 Bytes:85 04
|
|
LDY #$03 ; PRG:$1C05 Bytes:A0 03
|
|
LDA ($02),Y ; PRG:$1C07 Bytes:B1 02
|
|
SEC ; PRG:$1C09 Bytes:38
|
|
SBC #$04 ; PRG:$1C0A Bytes:E9 04
|
|
STA $05 ; PRG:$1C0C Bytes:85 05
|
|
LDY #$11 ; PRG:$1C0E Bytes:A0 11
|
|
LDA ($02),Y ; PRG:$1C10 Bytes:B1 02
|
|
TAX ; PRG:$1C12 Bytes:AA
|
|
BEQ ObjectPathOnZero_DC18 ; PRG:$1C13 Bytes:F0 03
|
|
JSR UpdateObjectBufferRoutine_DD5B ; PRG:$1C15 Bytes:20 5B DD
|
|
ObjectPathOnZero_DC18:
|
|
LDY #$0B ; PRG:$1C18 Bytes:A0 0B
|
|
LDA ($02),Y ; PRG:$1C1A Bytes:B1 02
|
|
LDX #$03 ; PRG:$1C1C Bytes:A2 03
|
|
ObjectPathLoop_DC1E:
|
|
DEX ; PRG:$1C1E Bytes:CA
|
|
CMP $DBC4,X ; PRG:$1C1F Bytes:DD C4 DB
|
|
BNE ObjectPathLoop_DC1E ; PRG:$1C22 Bytes:D0 FA
|
|
LDA #$00 ; PRG:$1C24 Bytes:A9 00
|
|
STA $A9,X ; PRG:$1C26 Bytes:95 A9
|
|
LDY #$01 ; PRG:$1C28 Bytes:A0 01
|
|
STA ($02),Y ; PRG:$1C2A Bytes:91 02
|
|
LDA #$80 ; PRG:$1C2C Bytes:A9 80
|
|
ObjectPathLoop_DC2E:
|
|
LDX #$10 ; PRG:$1C2E Bytes:A2 10
|
|
STX $FF ; PRG:$1C30 Bytes:86 FF
|
|
LDY #$00 ; PRG:$1C32 Bytes:A0 00
|
|
ObjectPathOnZero_DC34:
|
|
STA ($02),Y ; PRG:$1C34 Bytes:91 02
|
|
ObjectPathLoop_DC36:
|
|
LDX #$02 ; PRG:$1C36 Bytes:A2 02
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$1C38 Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_DBD3 ; PRG:$1C3B Bytes:10 96
|
|
RTS ; PRG:$1C3D Bytes:60
|
|
ObjectPathOnNegative_DC3E:
|
|
CPX #$00 ; PRG:$1C3E Bytes:E0 00
|
|
BNE ObjectPathLoop_DC36 ; PRG:$1C40 Bytes:D0 F4
|
|
LDX #$03 ; PRG:$1C42 Bytes:A2 03
|
|
ObjectPathLoop_DC44:
|
|
DEX ; PRG:$1C44 Bytes:CA
|
|
BMI ObjectPathLoop_DC36 ; PRG:$1C45 Bytes:30 EF
|
|
LDA $A9,X ; PRG:$1C47 Bytes:B5 A9
|
|
BNE ObjectPathLoop_DC44 ; PRG:$1C49 Bytes:D0 F9
|
|
LDY #$0B ; PRG:$1C4B Bytes:A0 0B
|
|
LDA $DBC4,X ; PRG:$1C4D Bytes:BD C4 DB
|
|
STA ($02),Y ; PRG:$1C50 Bytes:91 02
|
|
LDA #$01 ; PRG:$1C52 Bytes:A9 01
|
|
STA $A9,X ; PRG:$1C54 Bytes:95 A9
|
|
LDA #$00 ; PRG:$1C56 Bytes:A9 00
|
|
BEQ ObjectPathLoop_DC2E ; PRG:$1C58 Bytes:F0 D4
|
|
;------------------------------------------------------------
|
|
; ObjectPath_DC5A
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_DC5A:
|
|
LDA #$01 ; PRG:$1C5A Bytes:A9 01
|
|
STA $0E ; PRG:$1C5C Bytes:85 0E
|
|
LDA #$40 ; PRG:$1C5E Bytes:A9 40
|
|
STA $00 ; PRG:$1C60 Bytes:85 00
|
|
LDA #$04 ; PRG:$1C62 Bytes:A9 04
|
|
STA $01 ; PRG:$1C64 Bytes:85 01
|
|
UpdateObjectBufferLoop_DC66:
|
|
LDA #$07 ; PRG:$1C66 Bytes:A9 07
|
|
STA $0F ; PRG:$1C68 Bytes:85 0F
|
|
LDA #$00 ; PRG:$1C6A Bytes:A9 00
|
|
STA $02 ; PRG:$1C6C Bytes:85 02
|
|
LDA #$06 ; PRG:$1C6E Bytes:A9 06
|
|
STA $03 ; PRG:$1C70 Bytes:85 03
|
|
ObjectPathLoop_DC72:
|
|
JSR ProcessObjectStateRoutine_D970 ; PRG:$1C72 Bytes:20 70 D9
|
|
BNE ObjectPathLoop_DC8A ; PRG:$1C75 Bytes:D0 13
|
|
LDY #$00 ; PRG:$1C77 Bytes:A0 00
|
|
LDA ($02),Y ; PRG:$1C79 Bytes:B1 02
|
|
BMI ObjectPathOnNegative_DC9E ; PRG:$1C7B Bytes:30 21
|
|
BNE ObjectPathLoop_DC8A ; PRG:$1C7D Bytes:D0 0B
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$1C7F Bytes:20 1C F7
|
|
BCC ObjectPathLoop_DC8A ; PRG:$1C82 Bytes:90 06
|
|
LDY #$10 ; PRG:$1C84 Bytes:A0 10
|
|
LDA ($02),Y ; PRG:$1C86 Bytes:B1 02
|
|
BEQ UpdateObjectBufferOnZero_DCBB ; PRG:$1C88 Bytes:F0 31
|
|
ObjectPathLoop_DC8A:
|
|
LDX #$02 ; PRG:$1C8A Bytes:A2 02
|
|
JSR RunGameTaskRoutine_CBD3 ; PRG:$1C8C Bytes:20 D3 CB
|
|
BPL ObjectPathLoop_DC72 ; PRG:$1C8F Bytes:10 E1
|
|
LDA #$00 ; PRG:$1C91 Bytes:A9 00
|
|
STA $00 ; PRG:$1C93 Bytes:85 00
|
|
LDA #$04 ; PRG:$1C95 Bytes:A9 04
|
|
STA $01 ; PRG:$1C97 Bytes:85 01
|
|
DEC $0E ; PRG:$1C99 Bytes:C6 0E
|
|
BPL UpdateObjectBufferLoop_DC66 ; PRG:$1C9B Bytes:10 C9
|
|
RTS ; PRG:$1C9D Bytes:60
|
|
ObjectPathOnNegative_DC9E:
|
|
INY ; PRG:$1C9E Bytes:C8
|
|
LDA ($02),Y ; PRG:$1C9F Bytes:B1 02
|
|
BEQ ObjectPathLoop_DC8A ; PRG:$1CA1 Bytes:F0 E7
|
|
DEY ; PRG:$1CA3 Bytes:88
|
|
LDA #$00 ; PRG:$1CA4 Bytes:A9 00
|
|
STA ($02),Y ; PRG:$1CA6 Bytes:91 02
|
|
JSR ProcessResourceStateRoutine_F71C ; PRG:$1CA8 Bytes:20 1C F7
|
|
LDY #$00 ; PRG:$1CAB Bytes:A0 00
|
|
LDA #$80 ; PRG:$1CAD Bytes:A9 80
|
|
STA ($02),Y ; PRG:$1CAF Bytes:91 02
|
|
BCC ObjectPathLoop_DC8A ; PRG:$1CB1 Bytes:90 D7
|
|
LDA #$04 ; PRG:$1CB3 Bytes:A9 04
|
|
LDY #$10 ; PRG:$1CB5 Bytes:A0 10
|
|
STA ($02),Y ; PRG:$1CB7 Bytes:91 02
|
|
BNE ObjectPathLoop_DC8A ; PRG:$1CB9 Bytes:D0 CF
|
|
UpdateObjectBufferOnZero_DCBB:
|
|
LDY #$10 ; PRG:$1CBB Bytes:A0 10
|
|
LDA #$28 ; PRG:$1CBD Bytes:A9 28
|
|
STA ($02),Y ; PRG:$1CBF Bytes:91 02
|
|
LDY #$05 ; PRG:$1CC1 Bytes:A0 05
|
|
LDA ($02),Y ; PRG:$1CC3 Bytes:B1 02
|
|
TAX ; PRG:$1CC5 Bytes:AA
|
|
BEQ ObjectPathOnZero_DCEA ; PRG:$1CC6 Bytes:F0 22
|
|
DEX ; PRG:$1CC8 Bytes:CA
|
|
BEQ ObjectPathOnZero_DD08 ; PRG:$1CC9 Bytes:F0 3D
|
|
LDA #$03 ; PRG:$1CCB Bytes:A9 03
|
|
LDY #$15 ; PRG:$1CCD Bytes:A0 15
|
|
DEX ; PRG:$1CCF Bytes:CA
|
|
BEQ ObjectPathOnZero_DCD6 ; PRG:$1CD0 Bytes:F0 04
|
|
LDA #$02 ; PRG:$1CD2 Bytes:A9 02
|
|
LDY #$08 ; PRG:$1CD4 Bytes:A0 08
|
|
ObjectPathOnZero_DCD6:
|
|
STY $00 ; PRG:$1CD6 Bytes:84 00
|
|
LDY #$11 ; PRG:$1CD8 Bytes:A0 11
|
|
STA ($02),Y ; PRG:$1CDA Bytes:91 02
|
|
LDA $8D ; PRG:$1CDC Bytes:A5 8D
|
|
BNE ObjectPathOnNonZero_DCE9 ; PRG:$1CDE Bytes:D0 09
|
|
LDA $0E ; PRG:$1CE0 Bytes:A5 0E
|
|
ORA #$08 ; PRG:$1CE2 Bytes:09 08
|
|
STA $01 ; PRG:$1CE4 Bytes:85 01
|
|
JSR ProcessResourceStateRoutine_F40C ; PRG:$1CE6 Bytes:20 0C F4
|
|
ObjectPathOnNonZero_DCE9:
|
|
RTS ; PRG:$1CE9 Bytes:60
|
|
ObjectPathOnZero_DCEA:
|
|
JSR ProcessObjectStateRoutine_D1CE ; PRG:$1CEA Bytes:20 CE D1
|
|
INY ; PRG:$1CED Bytes:C8
|
|
LDX #$08 ; PRG:$1CEE Bytes:A2 08
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1CF0 Bytes:20 AE D1
|
|
LDA $0E ; PRG:$1CF3 Bytes:A5 0E
|
|
EOR #$01 ; PRG:$1CF5 Bytes:49 01
|
|
TAY ; PRG:$1CF7 Bytes:A8
|
|
LDA #$30 ; PRG:$1CF8 Bytes:A9 30
|
|
STA a:$0075,Y ; PRG:$1CFA Bytes:99 75 00
|
|
STA $77 ; PRG:$1CFD Bytes:85 77
|
|
LDX $D25D,Y ; PRG:$1CFF Bytes:BE 5D D2
|
|
INY ; PRG:$1D02 Bytes:C8
|
|
INY ; PRG:$1D03 Bytes:C8
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1D04 Bytes:20 AE D1
|
|
RTS ; PRG:$1D07 Bytes:60
|
|
ObjectPathOnZero_DD08:
|
|
LDX $0E ; PRG:$1D08 Bytes:A6 0E
|
|
INC $80,X ; PRG:$1D0A Bytes:F6 80
|
|
JSR ProcessObjectStateRoutine_D42C ; PRG:$1D0C Bytes:20 2C D4
|
|
RTS ; PRG:$1D0F Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_DD10
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_DD10:
|
|
LDA $77 ; PRG:$1D10 Bytes:A5 77
|
|
CMP #$01 ; PRG:$1D12 Bytes:C9 01
|
|
BNE ObjectPathOnNonZero_DD20 ; PRG:$1D14 Bytes:D0 0A
|
|
DEC $77 ; PRG:$1D16 Bytes:C6 77
|
|
JSR ProcessObjectStateRoutine_D1CE ; PRG:$1D18 Bytes:20 CE D1
|
|
LDX #$08 ; PRG:$1D1B Bytes:A2 08
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1D1D Bytes:20 AE D1
|
|
ObjectPathOnNonZero_DD20:
|
|
LDA $75 ; PRG:$1D20 Bytes:A5 75
|
|
CMP #$01 ; PRG:$1D22 Bytes:C9 01
|
|
BNE ObjectPathOnNonZero_DD2F ; PRG:$1D24 Bytes:D0 09
|
|
DEC $75 ; PRG:$1D26 Bytes:C6 75
|
|
LDY #$00 ; PRG:$1D28 Bytes:A0 00
|
|
LDX #$10 ; PRG:$1D2A Bytes:A2 10
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1D2C Bytes:20 AE D1
|
|
ObjectPathOnNonZero_DD2F:
|
|
LDA $76 ; PRG:$1D2F Bytes:A5 76
|
|
CMP #$01 ; PRG:$1D31 Bytes:C9 01
|
|
BNE ObjectPathOnNonZero_DD3E ; PRG:$1D33 Bytes:D0 09
|
|
DEC $76 ; PRG:$1D35 Bytes:C6 76
|
|
LDY #$01 ; PRG:$1D37 Bytes:A0 01
|
|
LDX #$14 ; PRG:$1D39 Bytes:A2 14
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1D3B Bytes:20 AE D1
|
|
ObjectPathOnNonZero_DD3E:
|
|
LDA $56 ; PRG:$1D3E Bytes:A5 56
|
|
CMP #$01 ; PRG:$1D40 Bytes:C9 01
|
|
BNE ObjectPathOnNonZero_DD5A ; PRG:$1D42 Bytes:D0 16
|
|
LDA $75 ; PRG:$1D44 Bytes:A5 75
|
|
BNE ObjectPathOnNonZero_DD4F ; PRG:$1D46 Bytes:D0 07
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateDispatch_DD48
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateDispatch_DD48:
|
|
LDY #$00 ; PRG:$1D48 Bytes:A0 00
|
|
LDX #$10 ; PRG:$1D4A Bytes:A2 10
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1D4C Bytes:20 AE D1
|
|
ObjectPathOnNonZero_DD4F:
|
|
LDA $76 ; PRG:$1D4F Bytes:A5 76
|
|
BNE ObjectPathOnNonZero_DD5A ; PRG:$1D51 Bytes:D0 07
|
|
LDY #$01 ; PRG:$1D53 Bytes:A0 01
|
|
LDX #$14 ; PRG:$1D55 Bytes:A2 14
|
|
JSR UpdateObjectBufferRoutine_D1AE ; PRG:$1D57 Bytes:20 AE D1
|
|
ObjectPathOnNonZero_DD5A:
|
|
RTS ; PRG:$1D5A Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_DD5B
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_DD5B:
|
|
STX $06 ; PRG:$1D5B Bytes:86 06
|
|
LDA #$B0 ; PRG:$1D5D Bytes:A9 B0
|
|
STA $00 ; PRG:$1D5F Bytes:85 00
|
|
LDA #$03 ; PRG:$1D61 Bytes:A9 03
|
|
STA $01 ; PRG:$1D63 Bytes:85 01
|
|
LDX #$03 ; PRG:$1D65 Bytes:A2 03
|
|
UpdateObjectBufferLoop_DD67:
|
|
JSR ProcessObjectStateRoutine_DDB2 ; PRG:$1D67 Bytes:20 B2 DD
|
|
BMI ObjectPathOnNegative_DD8E ; PRG:$1D6A Bytes:30 22
|
|
LDY #$00 ; PRG:$1D6C Bytes:A0 00
|
|
LDA ($00),Y ; PRG:$1D6E Bytes:B1 00
|
|
BEQ UpdateObjectBufferLoop_DD67 ; PRG:$1D70 Bytes:F0 F5
|
|
LDA #$00 ; PRG:$1D72 Bytes:A9 00
|
|
STA ($00),Y ; PRG:$1D74 Bytes:91 00
|
|
LDA $04 ; PRG:$1D76 Bytes:A5 04
|
|
LDY #$01 ; PRG:$1D78 Bytes:A0 01
|
|
STA ($00),Y ; PRG:$1D7A Bytes:91 00
|
|
LDA $05 ; PRG:$1D7C Bytes:A5 05
|
|
LDY #$03 ; PRG:$1D7E Bytes:A0 03
|
|
STA ($00),Y ; PRG:$1D80 Bytes:91 00
|
|
LDA $06 ; PRG:$1D82 Bytes:A5 06
|
|
LDY #$05 ; PRG:$1D84 Bytes:A0 05
|
|
STA ($00),Y ; PRG:$1D86 Bytes:91 00
|
|
LDA #$20 ; PRG:$1D88 Bytes:A9 20
|
|
LDY #$0C ; PRG:$1D8A Bytes:A0 0C
|
|
STA ($00),Y ; PRG:$1D8C Bytes:91 00
|
|
ObjectPathOnNegative_DD8E:
|
|
RTS ; PRG:$1D8E Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_DD8F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_DD8F:
|
|
LDA #$C0 ; PRG:$1D8F Bytes:A9 C0
|
|
STA $00 ; PRG:$1D91 Bytes:85 00
|
|
LDA #$03 ; PRG:$1D93 Bytes:A9 03
|
|
STA $01 ; PRG:$1D95 Bytes:85 01
|
|
LDX #$02 ; PRG:$1D97 Bytes:A2 02
|
|
ObjectPathLoop_DD99:
|
|
LDY #$0C ; PRG:$1D99 Bytes:A0 0C
|
|
LDA ($00),Y ; PRG:$1D9B Bytes:B1 00
|
|
BEQ ObjectPathContinue_DDAC ; PRG:$1D9D Bytes:F0 0D
|
|
SEC ; PRG:$1D9F Bytes:38
|
|
SBC #$01 ; PRG:$1DA0 Bytes:E9 01
|
|
STA ($00),Y ; PRG:$1DA2 Bytes:91 00
|
|
BNE ObjectPathContinue_DDAC ; PRG:$1DA4 Bytes:D0 06
|
|
LDY #$00 ; PRG:$1DA6 Bytes:A0 00
|
|
LDA #$01 ; PRG:$1DA8 Bytes:A9 01
|
|
STA ($00),Y ; PRG:$1DAA Bytes:91 00
|
|
ObjectPathContinue_DDAC:
|
|
JSR ProcessObjectStateRoutine_DDB2 ; PRG:$1DAC Bytes:20 B2 DD
|
|
BPL ObjectPathLoop_DD99 ; PRG:$1DAF Bytes:10 E8
|
|
RTS ; PRG:$1DB1 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_DDB2
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_DDB2:
|
|
CLC ; PRG:$1DB2 Bytes:18
|
|
LDA #$10 ; PRG:$1DB3 Bytes:A9 10
|
|
ADC $00 ; PRG:$1DB5 Bytes:65 00
|
|
STA $00 ; PRG:$1DB7 Bytes:85 00
|
|
LDA #$00 ; PRG:$1DB9 Bytes:A9 00
|
|
ADC $01 ; PRG:$1DBB Bytes:65 01
|
|
STA $01 ; PRG:$1DBD Bytes:85 01
|
|
DEX ; PRG:$1DBF Bytes:CA
|
|
RTS ; PRG:$1DC0 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_DDC1
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_DDC1:
|
|
LDA $8D ; PRG:$1DC1 Bytes:A5 8D
|
|
BEQ ObjectPathOnZero_DDF8 ; PRG:$1DC3 Bytes:F0 33
|
|
LDX #$01 ; PRG:$1DC5 Bytes:A2 01
|
|
ObjectPathLoop_DDC7:
|
|
LDA $70,X ; PRG:$1DC7 Bytes:B5 70
|
|
BNE ObjectPathOnNonZero_DDE3 ; PRG:$1DC9 Bytes:D0 18
|
|
LDA $10,X ; PRG:$1DCB Bytes:B5 10
|
|
AND #$07 ; PRG:$1DCD Bytes:29 07
|
|
ORA #$02 ; PRG:$1DCF Bytes:09 02
|
|
STA $70,X ; PRG:$1DD1 Bytes:95 70
|
|
LDA $12,X ; PRG:$1DD3 Bytes:B5 12
|
|
AND #$0F ; PRG:$1DD5 Bytes:29 0F
|
|
TAY ; PRG:$1DD7 Bytes:A8
|
|
LDA #$00 ; PRG:$1DD8 Bytes:A9 00
|
|
SEC ; PRG:$1DDA Bytes:38
|
|
ObjectPathLoop_DDDB:
|
|
ROL A ; PRG:$1DDB Bytes:2A
|
|
DEY ; PRG:$1DDC Bytes:88
|
|
BNE ObjectPathLoop_DDDB ; PRG:$1DDD Bytes:D0 FC
|
|
AND #$0F ; PRG:$1DDF Bytes:29 0F
|
|
STA $D8,X ; PRG:$1DE1 Bytes:95 D8
|
|
ObjectPathOnNonZero_DDE3:
|
|
LDA $44,X ; PRG:$1DE3 Bytes:B5 44
|
|
AND #$30 ; PRG:$1DE5 Bytes:29 30
|
|
ORA $D8,X ; PRG:$1DE7 Bytes:15 D8
|
|
STA $44,X ; PRG:$1DE9 Bytes:95 44
|
|
LDY $14,X ; PRG:$1DEB Bytes:B4 14
|
|
CPY #$08 ; PRG:$1DED Bytes:C0 08
|
|
BCS ObjectPathOnCarry_DDF3 ; PRG:$1DEF Bytes:B0 02
|
|
ORA #$80 ; PRG:$1DF1 Bytes:09 80
|
|
ObjectPathOnCarry_DDF3:
|
|
STA $46,X ; PRG:$1DF3 Bytes:95 46
|
|
DEX ; PRG:$1DF5 Bytes:CA
|
|
BPL ObjectPathLoop_DDC7 ; PRG:$1DF6 Bytes:10 CF
|
|
ObjectPathOnZero_DDF8:
|
|
RTS ; PRG:$1DF8 Bytes:60
|
|
.byte $28, $28, $20, $23, $00, $1F, $00, $A0, $00, $FF, $00, $FF, $01, $FF, $20, $E0 ; PRG:$1DF9 Bytes:28 28 20 23 00 1F 00 A0 00 FF 00 FF 01 FF 20 E0
|
|
.byte $20, $20, $01, $01, $1E, $1E, $20, $20, $20, $20, $1E, $1E ; PRG:$1E09 Bytes:20 20 01 01 1E 1E 20 20 20 20 1E 1E
|
|
;------------------------------------------------------------
|
|
; ObjectPath_DE15
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_DE15:
|
|
LDX #$03 ; PRG:$1E15 Bytes:A2 03
|
|
ObjectPathLoop_DE17:
|
|
LDA $DE0D,X ; PRG:$1E17 Bytes:BD 0D DE
|
|
STA $04 ; PRG:$1E1A Bytes:85 04
|
|
LDA $DDFD,X ; PRG:$1E1C Bytes:BD FD DD
|
|
STA $00 ; PRG:$1E1F Bytes:85 00
|
|
LDA $DDF9,X ; PRG:$1E21 Bytes:BD F9 DD
|
|
STA $01 ; PRG:$1E24 Bytes:85 01
|
|
UpdateObjectBufferLoop_DE26:
|
|
LDY $DE11,X ; PRG:$1E26 Bytes:BC 11 DE
|
|
LDA WorkPtr0Lo ; PRG:$1E29 Bytes:A5 00
|
|
STA $02 ; PRG:$1E2B Bytes:85 02
|
|
LDA WorkPtr0Hi ; PRG:$1E2D Bytes:A5 01
|
|
STA $03 ; PRG:$1E2F Bytes:85 03
|
|
ObjectPathLoop_DE31:
|
|
JSR UpdateObjectBufferRoutine_DE81 ; PRG:$1E31 Bytes:20 81 DE
|
|
CMP #$4E ; PRG:$1E34 Bytes:C9 4E
|
|
BEQ UpdateObjectBufferOnZero_DE3C ; PRG:$1E36 Bytes:F0 04
|
|
CMP #$24 ; PRG:$1E38 Bytes:C9 24
|
|
BNE ObjectPathOnNonZero_DE4D ; PRG:$1E3A Bytes:D0 11
|
|
UpdateObjectBufferOnZero_DE3C:
|
|
PHA ; PRG:$1E3C Bytes:48
|
|
LDA $03 ; PRG:$1E3D Bytes:A5 03
|
|
STA PPUADDR ; PRG:$1E3F Bytes:8D 06 20
|
|
LDA WorkPtr1Lo ; PRG:$1E42 Bytes:A5 02
|
|
STA PPUADDR ; PRG:$1E44 Bytes:8D 06 20
|
|
LDA #$FF ; PRG:$1E47 Bytes:A9 FF
|
|
STA PPUDATA ; PRG:$1E49 Bytes:8D 07 20
|
|
PLA ; PRG:$1E4C Bytes:68
|
|
ObjectPathOnNonZero_DE4D:
|
|
CMP #$4E ; PRG:$1E4D Bytes:C9 4E
|
|
BCS UpdateObjectBufferOnCarry_DE55 ; PRG:$1E4F Bytes:B0 04
|
|
CMP #$30 ; PRG:$1E51 Bytes:C9 30
|
|
BCS ObjectPathOnCarry_DE6B ; PRG:$1E53 Bytes:B0 16
|
|
UpdateObjectBufferOnCarry_DE55:
|
|
CMP #$B9 ; PRG:$1E55 Bytes:C9 B9
|
|
BCS ObjectPathOnCarry_DE6B ; PRG:$1E57 Bytes:B0 12
|
|
CLC ; PRG:$1E59 Bytes:18
|
|
LDA $DE05,X ; PRG:$1E5A Bytes:BD 05 DE
|
|
ADC $02 ; PRG:$1E5D Bytes:65 02
|
|
STA $02 ; PRG:$1E5F Bytes:85 02
|
|
LDA $DE01,X ; PRG:$1E61 Bytes:BD 01 DE
|
|
ADC $03 ; PRG:$1E64 Bytes:65 03
|
|
STA $03 ; PRG:$1E66 Bytes:85 03
|
|
DEY ; PRG:$1E68 Bytes:88
|
|
BNE ObjectPathLoop_DE31 ; PRG:$1E69 Bytes:D0 C6
|
|
ObjectPathOnCarry_DE6B:
|
|
CLC ; PRG:$1E6B Bytes:18
|
|
LDA $DE09,X ; PRG:$1E6C Bytes:BD 09 DE
|
|
ADC $00 ; PRG:$1E6F Bytes:65 00
|
|
STA $00 ; PRG:$1E71 Bytes:85 00
|
|
LDA #$00 ; PRG:$1E73 Bytes:A9 00
|
|
ADC $01 ; PRG:$1E75 Bytes:65 01
|
|
STA $01 ; PRG:$1E77 Bytes:85 01
|
|
DEC $04 ; PRG:$1E79 Bytes:C6 04
|
|
BNE UpdateObjectBufferLoop_DE26 ; PRG:$1E7B Bytes:D0 A9
|
|
DEX ; PRG:$1E7D Bytes:CA
|
|
BPL ObjectPathLoop_DE17 ; PRG:$1E7E Bytes:10 97
|
|
RTS ; PRG:$1E80 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_DE81
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_DE81:
|
|
LDA PPUSTATUS ; PRG:$1E81 Bytes:AD 02 20
|
|
LDA $03 ; PRG:$1E84 Bytes:A5 03
|
|
STA PPUADDR ; PRG:$1E86 Bytes:8D 06 20
|
|
LDA WorkPtr1Lo ; PRG:$1E89 Bytes:A5 02
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_DE8B
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_DE8B:
|
|
STA PPUADDR ; PRG:$1E8B Bytes:8D 06 20
|
|
LDA PPUDATA ; PRG:$1E8E Bytes:AD 07 20
|
|
LDA PPUDATA ; PRG:$1E91 Bytes:AD 07 20
|
|
RTS ; PRG:$1E94 Bytes:60
|
|
.byte $30, $35, $31, $4A, $3A, $3E, $4C, $3F, $33, $4B, $34, $38, $4D, $40, $3D, $41 ; PRG:$1E95 Bytes:30 35 31 4A 3A 3E 4C 3F 33 4B 34 38 4D 40 3D 41
|
|
.byte $37, $35, $3B, $3C, $3A, $49, $48, $36, $45, $47, $46, $38, $42, $43, $3D, $44 ; PRG:$1EA5 Bytes:37 35 3B 3C 3A 49 48 36 45 47 46 38 42 43 3D 44
|
|
.byte $4E, $FA, $FA, $4E, $6E, $86, $86, $6F, $FC, $FC, $FC, $FC, $4F, $F9, $F9, $4F ; PRG:$1EB5 Bytes:4E FA FA 4E 6E 86 86 6F FC FC FC FC 4F F9 F9 4F
|
|
.byte $4E, $FB, $FB, $4E, $60, $7C, $7C, $61, $FC, $FC, $FC, $FC, $4F, $F9, $F9, $4F ; PRG:$1EC5 Bytes:4E FB FB 4E 60 7C 7C 61 FC FC FC FC 4F F9 F9 4F
|
|
ObjectPathLoop_DED5:
|
|
AND #$F0 ; PRG:$1ED5 Bytes:29 F0
|
|
PHA ; PRG:$1ED7 Bytes:48
|
|
CMP #$C0 ; PRG:$1ED8 Bytes:C9 C0
|
|
LDA $40 ; PRG:$1EDA Bytes:A5 40
|
|
AND #$FB ; PRG:$1EDC Bytes:29 FB
|
|
BCC UpdateObjectBufferOnNoCarry_DEE2 ; PRG:$1EDE Bytes:90 02
|
|
ORA #$04 ; PRG:$1EE0 Bytes:09 04
|
|
UpdateObjectBufferOnNoCarry_DEE2:
|
|
STA $2000 ; PRG:$1EE2 Bytes:8D 00 20
|
|
STA $40 ; PRG:$1EE5 Bytes:85 40
|
|
LDA ($00),Y ; PRG:$1EE7 Bytes:B1 00
|
|
AND #$0F ; PRG:$1EE9 Bytes:29 0F
|
|
ORA #$20 ; PRG:$1EEB Bytes:09 20
|
|
STA PPUADDR ; PRG:$1EED Bytes:8D 06 20
|
|
STA $03 ; PRG:$1EF0 Bytes:85 03
|
|
INY ; PRG:$1EF2 Bytes:C8
|
|
LDA ($00),Y ; PRG:$1EF3 Bytes:B1 00
|
|
STA PPUADDR ; PRG:$1EF5 Bytes:8D 06 20
|
|
STA $02 ; PRG:$1EF8 Bytes:85 02
|
|
PLA ; PRG:$1EFA Bytes:68
|
|
LSR A ; PRG:$1EFB Bytes:4A
|
|
LSR A ; PRG:$1EFC Bytes:4A
|
|
TAY ; PRG:$1EFD Bytes:A8
|
|
LDA $DE95,Y ; PRG:$1EFE Bytes:B9 95 DE
|
|
STA PPUDATA ; PRG:$1F01 Bytes:8D 07 20
|
|
INY ; PRG:$1F04 Bytes:C8
|
|
LDA $DE95,Y ; PRG:$1F05 Bytes:B9 95 DE
|
|
STA PPUDATA ; PRG:$1F08 Bytes:8D 07 20
|
|
CPY #$20 ; PRG:$1F0B Bytes:C0 20
|
|
BCS ObjectPathOnCarry_DF1F ; PRG:$1F0D Bytes:B0 10
|
|
CLC ; PRG:$1F0F Bytes:18
|
|
LDA #$20 ; PRG:$1F10 Bytes:A9 20
|
|
ADC $02 ; PRG:$1F12 Bytes:65 02
|
|
TAX ; PRG:$1F14 Bytes:AA
|
|
LDA #$00 ; PRG:$1F15 Bytes:A9 00
|
|
ADC $03 ; PRG:$1F17 Bytes:65 03
|
|
STA PPUADDR ; PRG:$1F19 Bytes:8D 06 20
|
|
STX PPUADDR ; PRG:$1F1C Bytes:8E 06 20
|
|
ObjectPathOnCarry_DF1F:
|
|
INY ; PRG:$1F1F Bytes:C8
|
|
LDA $DE95,Y ; PRG:$1F20 Bytes:B9 95 DE
|
|
STA PPUDATA ; PRG:$1F23 Bytes:8D 07 20
|
|
INY ; PRG:$1F26 Bytes:C8
|
|
LDA $DE95,Y ; PRG:$1F27 Bytes:B9 95 DE
|
|
STA PPUDATA ; PRG:$1F2A Bytes:8D 07 20
|
|
LDY #$02 ; PRG:$1F2D Bytes:A0 02
|
|
;------------------------------------------------------------
|
|
; ObjectPath_DF2F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_DF2F:
|
|
LDX PPUSTATUS ; PRG:$1F2F Bytes:AE 02 20
|
|
TYA ; PRG:$1F32 Bytes:98
|
|
CLC ; PRG:$1F33 Bytes:18
|
|
ADC $00 ; PRG:$1F34 Bytes:65 00
|
|
STA $00 ; PRG:$1F36 Bytes:85 00
|
|
LDA #$00 ; PRG:$1F38 Bytes:A9 00
|
|
ADC $01 ; PRG:$1F3A Bytes:65 01
|
|
STA $01 ; PRG:$1F3C Bytes:85 01
|
|
LDY #$00 ; PRG:$1F3E Bytes:A0 00
|
|
LDA ($00),Y ; PRG:$1F40 Bytes:B1 00
|
|
CMP #$FF ; PRG:$1F42 Bytes:C9 FF
|
|
BNE ObjectPathLoop_DED5 ; PRG:$1F44 Bytes:D0 8F
|
|
RTS ; PRG:$1F46 Bytes:60
|
|
.byte $00, $02, $40, $42, $FC, $F3, $CF, $3F, $01, $04, $10, $40 ; PRG:$1F47 Bytes:00 02 40 42 FC F3 CF 3F 01 04 10 40
|
|
ObjectPathLoop_DF53:
|
|
LDA $42 ; PRG:$1F53 Bytes:A5 42
|
|
STA PPUSCROLL ; PRG:$1F55 Bytes:8D 05 20
|
|
LDA $43 ; PRG:$1F58 Bytes:A5 43
|
|
STA PPUSCROLL ; PRG:$1F5A Bytes:8D 05 20
|
|
RTS ; PRG:$1F5D Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_DF5E
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_DF5E:
|
|
LDA #$1F ; PRG:$1F5E Bytes:A9 1F
|
|
STA $03 ; PRG:$1F60 Bytes:85 03
|
|
LDA #$FF ; PRG:$1F62 Bytes:A9 FF
|
|
STA $02 ; PRG:$1F64 Bytes:85 02
|
|
UpdateObjectBufferDispatch_DF66:
|
|
CLC ; PRG:$1F66 Bytes:18
|
|
LDA #$01 ; PRG:$1F67 Bytes:A9 01
|
|
ADC $02 ; PRG:$1F69 Bytes:65 02
|
|
STA $02 ; PRG:$1F6B Bytes:85 02
|
|
LDA #$00 ; PRG:$1F6D Bytes:A9 00
|
|
ADC $03 ; PRG:$1F6F Bytes:65 03
|
|
STA $03 ; PRG:$1F71 Bytes:85 03
|
|
CMP #$23 ; PRG:$1F73 Bytes:C9 23
|
|
BNE ObjectPathOnNonZero_DF7D ; PRG:$1F75 Bytes:D0 06
|
|
LDA WorkPtr1Lo ; PRG:$1F77 Bytes:A5 02
|
|
CMP #$C0 ; PRG:$1F79 Bytes:C9 C0
|
|
BEQ ObjectPathLoop_DF53 ; PRG:$1F7B Bytes:F0 D6
|
|
ObjectPathOnNonZero_DF7D:
|
|
JSR UpdateObjectBufferRoutine_DE81 ; PRG:$1F7D Bytes:20 81 DE
|
|
LDY #$00 ; PRG:$1F80 Bytes:A0 00
|
|
CMP #$4E ; PRG:$1F82 Bytes:C9 4E
|
|
BEQ UpdateObjectBufferContinue_DFAC ; PRG:$1F84 Bytes:F0 26
|
|
CMP #$FA ; PRG:$1F86 Bytes:C9 FA
|
|
BEQ UpdateObjectBufferContinue_DFAC ; PRG:$1F88 Bytes:F0 22
|
|
CMP #$FB ; PRG:$1F8A Bytes:C9 FB
|
|
BEQ UpdateObjectBufferContinue_DFAC ; PRG:$1F8C Bytes:F0 1E
|
|
INY ; PRG:$1F8E Bytes:C8
|
|
CMP #$24 ; PRG:$1F8F Bytes:C9 24
|
|
BEQ UpdateObjectBufferDispatch_DF66 ; PRG:$1F91 Bytes:F0 D3
|
|
CMP #$4E ; PRG:$1F93 Bytes:C9 4E
|
|
BCC UpdateObjectBufferContinue_DFAC ; PRG:$1F95 Bytes:90 15
|
|
CMP #$FF ; PRG:$1F97 Bytes:C9 FF
|
|
BEQ UpdateObjectBufferContinue_DFAC ; PRG:$1F99 Bytes:F0 11
|
|
CMP #$CC ; PRG:$1F9B Bytes:C9 CC
|
|
BCS ObjectPathOnCarry_DFA3 ; PRG:$1F9D Bytes:B0 04
|
|
CMP #$AB ; PRG:$1F9F Bytes:C9 AB
|
|
BCS UpdateObjectBufferContinue_DFAC ; PRG:$1FA1 Bytes:B0 09
|
|
ObjectPathOnCarry_DFA3:
|
|
INY ; PRG:$1FA3 Bytes:C8
|
|
CMP #$60 ; PRG:$1FA4 Bytes:C9 60
|
|
BCS UpdateObjectBufferDispatch_DF66 ; PRG:$1FA6 Bytes:B0 BE
|
|
CMP #$50 ; PRG:$1FA8 Bytes:C9 50
|
|
BCC UpdateObjectBufferDispatch_DF66 ; PRG:$1FAA Bytes:90 BA
|
|
UpdateObjectBufferContinue_DFAC:
|
|
LDA WorkPtr1Lo ; PRG:$1FAC Bytes:A5 02
|
|
AND #$1C ; PRG:$1FAE Bytes:29 1C
|
|
LSR A ; PRG:$1FB0 Bytes:4A
|
|
LSR A ; PRG:$1FB1 Bytes:4A
|
|
STA $00 ; PRG:$1FB2 Bytes:85 00
|
|
LDA WorkPtr1Lo ; PRG:$1FB4 Bytes:A5 02
|
|
ASL A ; PRG:$1FB6 Bytes:0A
|
|
LDA $03 ; PRG:$1FB7 Bytes:A5 03
|
|
AND #$03 ; PRG:$1FB9 Bytes:29 03
|
|
ROL A ; PRG:$1FBB Bytes:2A
|
|
ASL A ; PRG:$1FBC Bytes:0A
|
|
ASL A ; PRG:$1FBD Bytes:0A
|
|
ASL A ; PRG:$1FBE Bytes:0A
|
|
CLC ; PRG:$1FBF Bytes:18
|
|
ADC $00 ; PRG:$1FC0 Bytes:65 00
|
|
CLC ; PRG:$1FC2 Bytes:18
|
|
ADC #$C0 ; PRG:$1FC3 Bytes:69 C0
|
|
STA $00 ; PRG:$1FC5 Bytes:85 00
|
|
LDA #$23 ; PRG:$1FC7 Bytes:A9 23
|
|
STA $01 ; PRG:$1FC9 Bytes:85 01
|
|
LDA WorkPtr1Lo ; PRG:$1FCB Bytes:A5 02
|
|
AND #$42 ; PRG:$1FCD Bytes:29 42
|
|
LDX #$FF ; PRG:$1FCF Bytes:A2 FF
|
|
ObjectPathLoop_DFD1:
|
|
INX ; PRG:$1FD1 Bytes:E8
|
|
CMP $DF47,X ; PRG:$1FD2 Bytes:DD 47 DF
|
|
BNE ObjectPathLoop_DFD1 ; PRG:$1FD5 Bytes:D0 FA
|
|
LDA $DF4F,X ; PRG:$1FD7 Bytes:BD 4F DF
|
|
CPY #$00 ; PRG:$1FDA Bytes:C0 00
|
|
BEQ ObjectPathOnZero_DFE6 ; PRG:$1FDC Bytes:F0 08
|
|
ASL A ; PRG:$1FDE Bytes:0A
|
|
CPY #$01 ; PRG:$1FDF Bytes:C0 01
|
|
BEQ ObjectPathOnZero_DFE6 ; PRG:$1FE1 Bytes:F0 03
|
|
ORA $DF4F,X ; PRG:$1FE3 Bytes:1D 4F DF
|
|
ObjectPathOnZero_DFE6:
|
|
STA $04 ; PRG:$1FE6 Bytes:85 04
|
|
LDY $01 ; PRG:$1FE8 Bytes:A4 01
|
|
STY PPUADDR ; PRG:$1FEA Bytes:8C 06 20
|
|
LDA WorkPtr0Lo ; PRG:$1FED Bytes:A5 00
|
|
JSR ProcessObjectStateRoutine_DE8B ; PRG:$1FEF Bytes:20 8B DE
|
|
AND $DF4B,X ; PRG:$1FF2 Bytes:3D 4B DF
|
|
ORA $04 ; PRG:$1FF5 Bytes:05 04
|
|
STY PPUADDR ; PRG:$1FF7 Bytes:8C 06 20
|
|
LDY $00 ; PRG:$1FFA Bytes:A4 00
|
|
STY PPUADDR ; PRG:$1FFC Bytes:8C 06 20
|
|
STA PPUDATA ; PRG:$1FFF Bytes:8D 07 20
|
|
JMP UpdateObjectBufferDispatch_DF66 ; PRG:$2002 Bytes:4C 66 DF
|
|
.byte $00, $00, $01, $01, $01, $01, $02, $02, $02, $03, $03, $03, $03, $04, $04, $04 ; PRG:$2005 Bytes:00 00 01 01 01 01 02 02 02 03 03 03 03 04 04 04
|
|
.byte $05, $05, $05, $05, $06, $06, $06, $06, $07, $07, $07, $07, $08, $08, $08, $08 ; PRG:$2015 Bytes:05 05 05 05 06 06 06 06 07 07 07 07 08 08 08 08
|
|
.byte $08, $09, $09, $09, $09, $09, $0A, $0A, $0A, $0A, $0A, $0A, $0B, $0B, $0B, $0B ; PRG:$2025 Bytes:08 09 09 09 09 09 0A 0A 0A 0A 0A 0A 0B 0B 0B 0B
|
|
.byte $0B, $0B, $0B, $0B, $0B, $0C, $0C, $0C, $0C, $0C, $0C, $0C, $0C, $0C, $0C, $0C ; PRG:$2035 Bytes:0B 0B 0B 0B 0B 0C 0C 0C 0C 0C 0C 0C 0C 0C 0C 0C
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E045
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E045:
|
|
LDX #$00 ; PRG:$2045 Bytes:A2 00
|
|
CMP #$80 ; PRG:$2047 Bytes:C9 80
|
|
BCC ObjectPathOnNoCarry_E04F ; PRG:$2049 Bytes:90 04
|
|
SBC #$80 ; PRG:$204B Bytes:E9 80
|
|
LDX #$01 ; PRG:$204D Bytes:A2 01
|
|
ObjectPathOnNoCarry_E04F:
|
|
CMP #$40 ; PRG:$204F Bytes:C9 40
|
|
BCC ObjectPathOnNoCarry_E059 ; PRG:$2051 Bytes:90 06
|
|
STA $00 ; PRG:$2053 Bytes:85 00
|
|
LDA #$7F ; PRG:$2055 Bytes:A9 7F
|
|
SBC $00 ; PRG:$2057 Bytes:E5 00
|
|
ObjectPathOnNoCarry_E059:
|
|
TAY ; PRG:$2059 Bytes:A8
|
|
LDA $E005,Y ; PRG:$205A Bytes:B9 05 E0
|
|
STA $00 ; PRG:$205D Bytes:85 00
|
|
DEX ; PRG:$205F Bytes:CA
|
|
BNE ObjectPathOnNonZero_E069 ; PRG:$2060 Bytes:D0 07
|
|
SEC ; PRG:$2062 Bytes:38
|
|
LDA #$00 ; PRG:$2063 Bytes:A9 00
|
|
SBC $00 ; PRG:$2065 Bytes:E5 00
|
|
STA $00 ; PRG:$2067 Bytes:85 00
|
|
ObjectPathOnNonZero_E069:
|
|
RTS ; PRG:$2069 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecordRoutine_E06A
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecordRoutine_E06A:
|
|
LDA $56 ; PRG:$206A Bytes:A5 56
|
|
BNE ObjectPathContinue_E09B ; PRG:$206C Bytes:D0 2D
|
|
LDX $0A ; PRG:$206E Bytes:A6 0A
|
|
LDA $75,X ; PRG:$2070 Bytes:B5 75
|
|
BNE ObjectPathContinue_E09B ; PRG:$2072 Bytes:D0 27
|
|
LDY #$1B ; PRG:$2074 Bytes:A0 1B
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2076 Bytes:B1 08
|
|
CMP #$30 ; PRG:$2078 Bytes:C9 30
|
|
BCC UpdateObjectRecordOnNoCarry_E080 ; PRG:$207A Bytes:90 04
|
|
CMP #$40 ; PRG:$207C Bytes:C9 40
|
|
BCC ObjectPathContinue_E09B ; PRG:$207E Bytes:90 1B
|
|
UpdateObjectRecordOnNoCarry_E080:
|
|
LDA $06 ; PRG:$2080 Bytes:A5 06
|
|
AND #$02 ; PRG:$2082 Bytes:29 02
|
|
BEQ UpdateObjectRecordOnZero_E09C ; PRG:$2084 Bytes:F0 16
|
|
CLC ; PRG:$2086 Bytes:18
|
|
LDY #$14 ; PRG:$2087 Bytes:A0 14
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2089 Bytes:B1 08
|
|
LDY #$04 ; PRG:$208B Bytes:A0 04
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$208D Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$208F Bytes:91 08
|
|
LDY #$13 ; PRG:$2091 Bytes:A0 13
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2093 Bytes:B1 08
|
|
LDY #$03 ; PRG:$2095 Bytes:A0 03
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$2097 Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2099 Bytes:91 08
|
|
ObjectPathContinue_E09B:
|
|
RTS ; PRG:$209B Bytes:60
|
|
UpdateObjectRecordOnZero_E09C:
|
|
CLC ; PRG:$209C Bytes:18
|
|
LDY #$12 ; PRG:$209D Bytes:A0 12
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$209F Bytes:B1 08
|
|
LDY #$02 ; PRG:$20A1 Bytes:A0 02
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$20A3 Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$20A5 Bytes:91 08
|
|
LDY #$11 ; PRG:$20A7 Bytes:A0 11
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$20A9 Bytes:B1 08
|
|
LDY #$01 ; PRG:$20AB Bytes:A0 01
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$20AD Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$20AF Bytes:91 08
|
|
RTS ; PRG:$20B1 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E0B2
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E0B2:
|
|
TAX ; PRG:$20B2 Bytes:AA
|
|
LDA #$FD ; PRG:$20B3 Bytes:A9 FD
|
|
ObjectPathLoop_E0B5:
|
|
CLC ; PRG:$20B5 Bytes:18
|
|
ADC #$03 ; PRG:$20B6 Bytes:69 03
|
|
DEX ; PRG:$20B8 Bytes:CA
|
|
BPL ObjectPathLoop_E0B5 ; PRG:$20B9 Bytes:10 FA
|
|
TAX ; PRG:$20BB Bytes:AA
|
|
TAY ; PRG:$20BC Bytes:A8
|
|
LDA a:$00B2,X ; PRG:$20BD Bytes:BD B2 00
|
|
CMP $02 ; PRG:$20C0 Bytes:C5 02
|
|
BNE UpdateObjectBufferOnNonZero_E0D2 ; PRG:$20C2 Bytes:D0 0E
|
|
INX ; PRG:$20C4 Bytes:E8
|
|
LDA a:$00B2,X ; PRG:$20C5 Bytes:BD B2 00
|
|
CMP $03 ; PRG:$20C8 Bytes:C5 03
|
|
BNE UpdateObjectBufferOnNonZero_E0D2 ; PRG:$20CA Bytes:D0 06
|
|
INX ; PRG:$20CC Bytes:E8
|
|
LDA a:$00B2,X ; PRG:$20CD Bytes:BD B2 00
|
|
CLC ; PRG:$20D0 Bytes:18
|
|
RTS ; PRG:$20D1 Bytes:60
|
|
UpdateObjectBufferOnNonZero_E0D2:
|
|
LDA WorkPtr1Lo ; PRG:$20D2 Bytes:A5 02
|
|
STA a:$00B2,Y ; PRG:$20D4 Bytes:99 B2 00
|
|
INY ; PRG:$20D7 Bytes:C8
|
|
LDA $03 ; PRG:$20D8 Bytes:A5 03
|
|
STA a:$00B2,Y ; PRG:$20DA Bytes:99 B2 00
|
|
SEC ; PRG:$20DD Bytes:38
|
|
RTS ; PRG:$20DE Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_E0DF
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_E0DF:
|
|
LDA #$08 ; PRG:$20DF Bytes:A9 08
|
|
STA $02 ; PRG:$20E1 Bytes:85 02
|
|
LDA WorkPtr0Lo ; PRG:$20E3 Bytes:A5 00
|
|
ASL A ; PRG:$20E5 Bytes:0A
|
|
ROL $02 ; PRG:$20E6 Bytes:26 02
|
|
ASL A ; PRG:$20E8 Bytes:0A
|
|
ROL $02 ; PRG:$20E9 Bytes:26 02
|
|
AND #$E0 ; PRG:$20EB Bytes:29 E0
|
|
STA $03 ; PRG:$20ED Bytes:85 03
|
|
LDA WorkPtr0Hi ; PRG:$20EF Bytes:A5 01
|
|
LSR A ; PRG:$20F1 Bytes:4A
|
|
LSR A ; PRG:$20F2 Bytes:4A
|
|
LSR A ; PRG:$20F3 Bytes:4A
|
|
ORA $03 ; PRG:$20F4 Bytes:05 03
|
|
STA $03 ; PRG:$20F6 Bytes:85 03
|
|
RTS ; PRG:$20F8 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_E0F9
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_E0F9:
|
|
LDA $03 ; PRG:$20F9 Bytes:A5 03
|
|
ASL A ; PRG:$20FB Bytes:0A
|
|
ASL A ; PRG:$20FC Bytes:0A
|
|
ASL A ; PRG:$20FD Bytes:0A
|
|
STA $01 ; PRG:$20FE Bytes:85 01
|
|
LDA $03 ; PRG:$2100 Bytes:A5 03
|
|
STA $00 ; PRG:$2102 Bytes:85 00
|
|
LDA WorkPtr1Lo ; PRG:$2104 Bytes:A5 02
|
|
LSR A ; PRG:$2106 Bytes:4A
|
|
ROR $00 ; PRG:$2107 Bytes:66 00
|
|
LSR A ; PRG:$2109 Bytes:4A
|
|
ROR $00 ; PRG:$210A Bytes:66 00
|
|
LDA #$F8 ; PRG:$210C Bytes:A9 F8
|
|
AND $00 ; PRG:$210E Bytes:25 00
|
|
STA $00 ; PRG:$2110 Bytes:85 00
|
|
RTS ; PRG:$2112 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ObjectPath_E113
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ObjectPath_E113:
|
|
LDA PPUSTATUS ; PRG:$2113 Bytes:AD 02 20
|
|
LDX #$00 ; PRG:$2116 Bytes:A2 00
|
|
ObjectPathLoop_E118:
|
|
LDA a:$00B2,X ; PRG:$2118 Bytes:BD B2 00
|
|
STA PPUADDR ; PRG:$211B Bytes:8D 06 20
|
|
INX ; PRG:$211E Bytes:E8
|
|
LDA a:$00B2,X ; PRG:$211F Bytes:BD B2 00
|
|
STA PPUADDR ; PRG:$2122 Bytes:8D 06 20
|
|
INX ; PRG:$2125 Bytes:E8
|
|
LDA PPUDATA ; PRG:$2126 Bytes:AD 07 20
|
|
LDA PPUDATA ; PRG:$2129 Bytes:AD 07 20
|
|
STA a:$00B2,X ; PRG:$212C Bytes:9D B2 00
|
|
INX ; PRG:$212F Bytes:E8
|
|
CPX #$1E ; PRG:$2130 Bytes:E0 1E
|
|
BNE ObjectPathLoop_E118 ; PRG:$2132 Bytes:D0 E4
|
|
LDA $42 ; PRG:$2134 Bytes:A5 42
|
|
STA PPUSCROLL ; PRG:$2136 Bytes:8D 05 20
|
|
LDA $43 ; PRG:$2139 Bytes:A5 43
|
|
STA PPUSCROLL ; PRG:$213B Bytes:8D 05 20
|
|
RTS ; PRG:$213E Bytes:60
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecordRoutine_E13F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecordRoutine_E13F:
|
|
LDY #$10 ; PRG:$213F Bytes:A0 10
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2141 Bytes:B1 08
|
|
LDY #$21 ; PRG:$2143 Bytes:A0 21
|
|
CMP #$00 ; PRG:$2145 Bytes:C9 00
|
|
BEQ ReadObjectRecordOnZero_E15D ; PRG:$2147 Bytes:F0 14
|
|
CMP #$01 ; PRG:$2149 Bytes:C9 01
|
|
BEQ ReadObjectRecordOnZero_E153 ; PRG:$214B Bytes:F0 06
|
|
LDY #$23 ; PRG:$214D Bytes:A0 23
|
|
CMP #$02 ; PRG:$214F Bytes:C9 02
|
|
BEQ ReadObjectRecordOnZero_E15D ; PRG:$2151 Bytes:F0 0A
|
|
ReadObjectRecordOnZero_E153:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2153 Bytes:B1 08
|
|
AND #$07 ; PRG:$2155 Bytes:29 07
|
|
CMP #$07 ; PRG:$2157 Bytes:C9 07
|
|
BCS ObjectPathOnCarry_E165 ; PRG:$2159 Bytes:B0 0A
|
|
ObjectPathLoop_E15B:
|
|
CLC ; PRG:$215B Bytes:18
|
|
RTS ; PRG:$215C Bytes:60
|
|
ReadObjectRecordOnZero_E15D:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$215D Bytes:B1 08
|
|
AND #$07 ; PRG:$215F Bytes:29 07
|
|
CMP #$01 ; PRG:$2161 Bytes:C9 01
|
|
BCS ObjectPathLoop_E15B ; PRG:$2163 Bytes:B0 F6
|
|
ObjectPathOnCarry_E165:
|
|
SEC ; PRG:$2165 Bytes:38
|
|
RTS ; PRG:$2166 Bytes:60
|
|
.byte $01, $19, $03, $1A, $19, $01, $1A, $03, $12, $12, $14, $14, $11, $11, $13, $13 ; PRG:$2167 Bytes:01 19 03 1A 19 01 1A 03 12 12 14 14 11 11 13 13
|
|
.byte $19, $19, $1A, $1A, $01, $01, $03, $03 ; PRG:$2177 Bytes:19 19 1A 1A 01 01 03 03
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E17F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E17F:
|
|
LDX #$08 ; PRG:$217F Bytes:A2 08
|
|
LDY #$41 ; PRG:$2181 Bytes:A0 41
|
|
CMP #$F9 ; PRG:$2183 Bytes:C9 F9
|
|
BEQ ObjectPathContinue_E1BB ; PRG:$2185 Bytes:F0 34
|
|
LDX #$20 ; PRG:$2187 Bytes:A2 20
|
|
CMP #$93 ; PRG:$2189 Bytes:C9 93
|
|
BCS ObjectPathOnCarry_E191 ; PRG:$218B Bytes:B0 04
|
|
CMP #$7C ; PRG:$218D Bytes:C9 7C
|
|
BCS ObjectPathContinue_E1BB ; PRG:$218F Bytes:B0 2A
|
|
ObjectPathOnCarry_E191:
|
|
LDY #$31 ; PRG:$2191 Bytes:A0 31
|
|
CMP #$24 ; PRG:$2193 Bytes:C9 24
|
|
BEQ ObjectPathOnZero_E1A7 ; PRG:$2195 Bytes:F0 10
|
|
CMP #$4A ; PRG:$2197 Bytes:C9 4A
|
|
BCC ObjectPathContinue_E1BB ; PRG:$2199 Bytes:90 20
|
|
CMP #$C4 ; PRG:$219B Bytes:C9 C4
|
|
BCS ObjectPathOnCarry_E1A3 ; PRG:$219D Bytes:B0 04
|
|
CMP #$B9 ; PRG:$219F Bytes:C9 B9
|
|
BCS ObjectPathContinue_E1BB ; PRG:$21A1 Bytes:B0 18
|
|
ObjectPathOnCarry_E1A3:
|
|
CMP #$FF ; PRG:$21A3 Bytes:C9 FF
|
|
BEQ ObjectPathContinue_E1BB ; PRG:$21A5 Bytes:F0 14
|
|
ObjectPathOnZero_E1A7:
|
|
LDY #$80 ; PRG:$21A7 Bytes:A0 80
|
|
CMP #$60 ; PRG:$21A9 Bytes:C9 60
|
|
BCS ObjectPathContinue_E1B9 ; PRG:$21AB Bytes:B0 0C
|
|
CMP #$50 ; PRG:$21AD Bytes:C9 50
|
|
BCC ObjectPathContinue_E1B9 ; PRG:$21AF Bytes:90 08
|
|
LDX $0A ; PRG:$21B1 Bytes:A6 0A
|
|
LDA $90,X ; PRG:$21B3 Bytes:B5 90
|
|
CMP #$13 ; PRG:$21B5 Bytes:C9 13
|
|
BNE ObjectPathOnNonZero_E1BD ; PRG:$21B7 Bytes:D0 04
|
|
ObjectPathContinue_E1B9:
|
|
CLC ; PRG:$21B9 Bytes:18
|
|
RTS ; PRG:$21BA Bytes:60
|
|
ObjectPathContinue_E1BB:
|
|
STX $FF ; PRG:$21BB Bytes:86 FF
|
|
ObjectPathOnNonZero_E1BD:
|
|
SEC ; PRG:$21BD Bytes:38
|
|
RTS ; PRG:$21BE Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E1BF
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E1BF:
|
|
TYA ; PRG:$21BF Bytes:98
|
|
BPL UpdateObjectRecordOnPositive_E1CF ; PRG:$21C0 Bytes:10 0D
|
|
JSR ReadObjectRecordRoutine_E262 ; PRG:$21C2 Bytes:20 62 E2
|
|
JSR UpdateObjectRecordRoutine_E229 ; PRG:$21C5 Bytes:20 29 E2
|
|
LDX $0A ; PRG:$21C8 Bytes:A6 0A
|
|
LDA #$13 ; PRG:$21CA Bytes:A9 13
|
|
STA $90,X ; PRG:$21CC Bytes:95 90
|
|
RTS ; PRG:$21CE Bytes:60
|
|
UpdateObjectRecordOnPositive_E1CF:
|
|
EOR $06 ; PRG:$21CF Bytes:45 06
|
|
LDY #$1B ; PRG:$21D1 Bytes:A0 1B
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$21D3 Bytes:91 08
|
|
STA $00 ; PRG:$21D5 Bytes:85 00
|
|
JSR ReadObjectRecordRoutine_E262 ; PRG:$21D7 Bytes:20 62 E2
|
|
LDA WorkPtr0Lo ; PRG:$21DA Bytes:A5 00
|
|
CMP #$40 ; PRG:$21DC Bytes:C9 40
|
|
BMI ObjectPathOnNegative_E1E8 ; PRG:$21DE Bytes:30 08
|
|
LSR $04 ; PRG:$21E0 Bytes:46 04
|
|
ROR $05 ; PRG:$21E2 Bytes:66 05
|
|
LSR $04 ; PRG:$21E4 Bytes:46 04
|
|
ROR $05 ; PRG:$21E6 Bytes:66 05
|
|
ObjectPathOnNegative_E1E8:
|
|
LSR $04 ; PRG:$21E8 Bytes:46 04
|
|
ROR $05 ; PRG:$21EA Bytes:66 05
|
|
LSR $04 ; PRG:$21EC Bytes:46 04
|
|
ROR $05 ; PRG:$21EE Bytes:66 05
|
|
LSR $04 ; PRG:$21F0 Bytes:46 04
|
|
ROR $05 ; PRG:$21F2 Bytes:66 05
|
|
LDA $06 ; PRG:$21F4 Bytes:A5 06
|
|
AND #$01 ; PRG:$21F6 Bytes:29 01
|
|
BNE UpdateObjectRecordOnNonZero_E1FD ; PRG:$21F8 Bytes:D0 03
|
|
JSR ProcessObjectStateRoutine_E281 ; PRG:$21FA Bytes:20 81 E2
|
|
UpdateObjectRecordOnNonZero_E1FD:
|
|
LDY #$18 ; PRG:$21FD Bytes:A0 18
|
|
LDA $05 ; PRG:$21FF Bytes:A5 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2201 Bytes:91 08
|
|
DEY ; PRG:$2203 Bytes:88
|
|
LDA $04 ; PRG:$2204 Bytes:A5 04
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2206 Bytes:91 08
|
|
JSR UpdateObjectRecordRoutine_E229 ; PRG:$2208 Bytes:20 29 E2
|
|
LDA $06 ; PRG:$220B Bytes:A5 06
|
|
ORA #$70 ; PRG:$220D Bytes:09 70
|
|
LDY #$10 ; PRG:$220F Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2211 Bytes:91 08
|
|
LDA WorkPtr0Lo ; PRG:$2213 Bytes:A5 00
|
|
CMP #$40 ; PRG:$2215 Bytes:C9 40
|
|
BCC ObjectPathOnNoCarry_E21D ; PRG:$2217 Bytes:90 04
|
|
JSR ProcessObjectStateRoutine_E69A ; PRG:$2219 Bytes:20 9A E6
|
|
RTS ; PRG:$221C Bytes:60
|
|
ObjectPathOnNoCarry_E21D:
|
|
LDY $0A ; PRG:$221D Bytes:A4 0A
|
|
LDA #$10 ; PRG:$221F Bytes:A9 10
|
|
STA a:$0058,Y ; PRG:$2221 Bytes:99 58 00
|
|
RTS ; PRG:$2224 Bytes:60
|
|
.byte $F8, $00, $10, $18 ; PRG:$2225 Bytes:F8 00 10 18
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_E229
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_E229:
|
|
LDY #$01 ; PRG:$2229 Bytes:A0 01
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$222B Bytes:B1 08
|
|
LDY #$19 ; PRG:$222D Bytes:A0 19
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$222F Bytes:91 08
|
|
LDY #$03 ; PRG:$2231 Bytes:A0 03
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2233 Bytes:B1 08
|
|
LDY #$1A ; PRG:$2235 Bytes:A0 1A
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2237 Bytes:91 08
|
|
LDX $06 ; PRG:$2239 Bytes:A6 06
|
|
LDY $E17B,X ; PRG:$223B Bytes:BC 7B E1
|
|
LDX #$00 ; PRG:$223E Bytes:A2 00
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2240 Bytes:B1 08
|
|
AND #$0F ; PRG:$2242 Bytes:29 0F
|
|
CMP #$08 ; PRG:$2244 Bytes:C9 08
|
|
BCC ObjectPathOnNoCarry_E249 ; PRG:$2246 Bytes:90 01
|
|
INX ; PRG:$2248 Bytes:E8
|
|
ObjectPathOnNoCarry_E249:
|
|
LDA $06 ; PRG:$2249 Bytes:A5 06
|
|
AND #$01 ; PRG:$224B Bytes:29 01
|
|
BNE UpdateObjectRecordOnNonZero_E251 ; PRG:$224D Bytes:D0 02
|
|
INX ; PRG:$224F Bytes:E8
|
|
INX ; PRG:$2250 Bytes:E8
|
|
UpdateObjectRecordOnNonZero_E251:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2251 Bytes:B1 08
|
|
AND #$F0 ; PRG:$2253 Bytes:29 F0
|
|
CLC ; PRG:$2255 Bytes:18
|
|
ADC $E225,X ; PRG:$2256 Bytes:7D 25 E2
|
|
TAX ; PRG:$2259 Bytes:AA
|
|
LDA $E177,Y ; PRG:$225A Bytes:B9 77 E1
|
|
TAY ; PRG:$225D Bytes:A8
|
|
TXA ; PRG:$225E Bytes:8A
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$225F Bytes:91 08
|
|
RTS ; PRG:$2261 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecordRoutine_E262
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecordRoutine_E262:
|
|
LDX $06 ; PRG:$2262 Bytes:A6 06
|
|
LDY $E16F,X ; PRG:$2264 Bytes:BC 6F E1
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2267 Bytes:B1 08
|
|
STA $05 ; PRG:$2269 Bytes:85 05
|
|
DEY ; PRG:$226B Bytes:88
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$226C Bytes:B1 08
|
|
STA $04 ; PRG:$226E Bytes:85 04
|
|
BPL UpdateObjectRecordOnPositive_E275 ; PRG:$2270 Bytes:10 03
|
|
JSR ProcessObjectStateRoutine_E281 ; PRG:$2272 Bytes:20 81 E2
|
|
UpdateObjectRecordOnPositive_E275:
|
|
LDY #$16 ; PRG:$2275 Bytes:A0 16
|
|
LDA $05 ; PRG:$2277 Bytes:A5 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2279 Bytes:91 08
|
|
DEY ; PRG:$227B Bytes:88
|
|
LDA $04 ; PRG:$227C Bytes:A5 04
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$227E Bytes:91 08
|
|
RTS ; PRG:$2280 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E281
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E281:
|
|
SEC ; PRG:$2281 Bytes:38
|
|
LDA #$00 ; PRG:$2282 Bytes:A9 00
|
|
SBC $05 ; PRG:$2284 Bytes:E5 05
|
|
STA $05 ; PRG:$2286 Bytes:85 05
|
|
LDA #$00 ; PRG:$2288 Bytes:A9 00
|
|
SBC $04 ; PRG:$228A Bytes:E5 04
|
|
STA $04 ; PRG:$228C Bytes:85 04
|
|
RTS ; PRG:$228E Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E28F
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E28F:
|
|
LDA $06 ; PRG:$228F Bytes:A5 06
|
|
AND #$03 ; PRG:$2291 Bytes:29 03
|
|
TAX ; PRG:$2293 Bytes:AA
|
|
LDA $06 ; PRG:$2294 Bytes:A5 06
|
|
AND #$F0 ; PRG:$2296 Bytes:29 F0
|
|
CMP #$70 ; PRG:$2298 Bytes:C9 70
|
|
BNE ReadObjectRecordOnNonZero_E2C7 ; PRG:$229A Bytes:D0 2B
|
|
JSR UpdateObjectRecordRoutine_E335 ; PRG:$229C Bytes:20 35 E3
|
|
BCS ObjectPathOnCarry_E2BA ; PRG:$229F Bytes:B0 19
|
|
JSR UpdateObjectRecordRoutine_E2E6 ; PRG:$22A1 Bytes:20 E6 E2
|
|
BMI ObjectPathOnNegative_E2B5 ; PRG:$22A4 Bytes:30 0F
|
|
LDA WorkPtr0Lo ; PRG:$22A6 Bytes:A5 00
|
|
BMI ObjectPathOnNegative_E2B9 ; PRG:$22A8 Bytes:30 0F
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_E2AA
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_E2AA:
|
|
LDY #$1B ; PRG:$22AA Bytes:A0 1B
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$22AC Bytes:B1 08
|
|
LDY #$10 ; PRG:$22AE Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$22B0 Bytes:91 08
|
|
STA $06 ; PRG:$22B2 Bytes:85 06
|
|
RTS ; PRG:$22B4 Bytes:60
|
|
ObjectPathOnNegative_E2B5:
|
|
LDA WorkPtr0Lo ; PRG:$22B5 Bytes:A5 00
|
|
BMI UpdateObjectRecordRoutine_E2AA ; PRG:$22B7 Bytes:30 F1
|
|
ObjectPathOnNegative_E2B9:
|
|
RTS ; PRG:$22B9 Bytes:60
|
|
ObjectPathOnCarry_E2BA:
|
|
JSR UpdateObjectRecordRoutine_E2AA ; PRG:$22BA Bytes:20 AA E2
|
|
AND #$03 ; PRG:$22BD Bytes:29 03
|
|
TAX ; PRG:$22BF Bytes:AA
|
|
LDY $E173,X ; PRG:$22C0 Bytes:BC 73 E1
|
|
JSR UpdateObjectRecordRoutine_E325 ; PRG:$22C3 Bytes:20 25 E3
|
|
RTS ; PRG:$22C6 Bytes:60
|
|
ReadObjectRecordOnNonZero_E2C7:
|
|
LDY $E16F,X ; PRG:$22C7 Bytes:BC 6F E1
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$22CA Bytes:B1 08
|
|
STA $05 ; PRG:$22CC Bytes:85 05
|
|
DEY ; PRG:$22CE Bytes:88
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$22CF Bytes:B1 08
|
|
STA $04 ; PRG:$22D1 Bytes:85 04
|
|
BPL ReadObjectRecordOnPositive_E2D8 ; PRG:$22D3 Bytes:10 03
|
|
JSR ProcessObjectStateRoutine_E281 ; PRG:$22D5 Bytes:20 81 E2
|
|
ReadObjectRecordOnPositive_E2D8:
|
|
LDY #$16 ; PRG:$22D8 Bytes:A0 16
|
|
SEC ; PRG:$22DA Bytes:38
|
|
LDA $05 ; PRG:$22DB Bytes:A5 05
|
|
SBC (CurrentObjectPtrLo),Y ; PRG:$22DD Bytes:F1 08
|
|
DEY ; PRG:$22DF Bytes:88
|
|
LDA $04 ; PRG:$22E0 Bytes:A5 04
|
|
SBC (CurrentObjectPtrLo),Y ; PRG:$22E2 Bytes:F1 08
|
|
BCC UpdateObjectRecordOnNoCarry_E301 ; PRG:$22E4 Bytes:90 1B
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_E2E6
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_E2E6:
|
|
LDY #$18 ; PRG:$22E6 Bytes:A0 18
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$22E8 Bytes:B1 08
|
|
CLC ; PRG:$22EA Bytes:18
|
|
LDY $E16F,X ; PRG:$22EB Bytes:BC 6F E1
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$22EE Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$22F0 Bytes:91 08
|
|
LDY #$17 ; PRG:$22F2 Bytes:A0 17
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$22F4 Bytes:B1 08
|
|
STA $00 ; PRG:$22F6 Bytes:85 00
|
|
LDY $E16F,X ; PRG:$22F8 Bytes:BC 6F E1
|
|
DEY ; PRG:$22FB Bytes:88
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$22FC Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$22FE Bytes:91 08
|
|
RTS ; PRG:$2300 Bytes:60
|
|
UpdateObjectRecordOnNoCarry_E301:
|
|
LDY #$10 ; PRG:$2301 Bytes:A0 10
|
|
TXA ; PRG:$2303 Bytes:8A
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2304 Bytes:91 08
|
|
LDY #$1B ; PRG:$2306 Bytes:A0 1B
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2308 Bytes:91 08
|
|
AND #$01 ; PRG:$230A Bytes:29 01
|
|
BEQ UpdateObjectRecordOnZero_E313 ; PRG:$230C Bytes:F0 05
|
|
LDY #$15 ; PRG:$230E Bytes:A0 15
|
|
JSR UpdateObjectRecordRoutine_E325 ; PRG:$2310 Bytes:20 25 E3
|
|
UpdateObjectRecordOnZero_E313:
|
|
LDY #$15 ; PRG:$2313 Bytes:A0 15
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2315 Bytes:B1 08
|
|
PHA ; PRG:$2317 Bytes:48
|
|
INY ; PRG:$2318 Bytes:C8
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2319 Bytes:B1 08
|
|
LDY $E16F,X ; PRG:$231B Bytes:BC 6F E1
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$231E Bytes:91 08
|
|
DEY ; PRG:$2320 Bytes:88
|
|
PLA ; PRG:$2321 Bytes:68
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2322 Bytes:91 08
|
|
RTS ; PRG:$2324 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_E325
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_E325:
|
|
INY ; PRG:$2325 Bytes:C8
|
|
SEC ; PRG:$2326 Bytes:38
|
|
LDA #$00 ; PRG:$2327 Bytes:A9 00
|
|
SBC (CurrentObjectPtrLo),Y ; PRG:$2329 Bytes:F1 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$232B Bytes:91 08
|
|
DEY ; PRG:$232D Bytes:88
|
|
LDA #$00 ; PRG:$232E Bytes:A9 00
|
|
SBC (CurrentObjectPtrLo),Y ; PRG:$2330 Bytes:F1 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2332 Bytes:91 08
|
|
RTS ; PRG:$2334 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_E335
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_E335:
|
|
LDY $E167,X ; PRG:$2335 Bytes:BC 67 E1
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2338 Bytes:B1 08
|
|
LDY $E16B,X ; PRG:$233A Bytes:BC 6B E1
|
|
CMP (CurrentObjectPtrLo),Y ; PRG:$233D Bytes:D1 08
|
|
BCC ObjectPathOnNoCarry_E350 ; PRG:$233F Bytes:90 0F
|
|
LDY $E177,X ; PRG:$2341 Bytes:BC 77 E1
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2344 Bytes:B1 08
|
|
LDY $E17B,X ; PRG:$2346 Bytes:BC 7B E1
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2349 Bytes:91 08
|
|
INY ; PRG:$234B Bytes:C8
|
|
LDA #$00 ; PRG:$234C Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$234E Bytes:91 08
|
|
ObjectPathOnNoCarry_E350:
|
|
RTS ; PRG:$2350 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecordRoutine_E351
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecordRoutine_E351:
|
|
LDY #$20 ; PRG:$2351 Bytes:A0 20
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2353 Bytes:B1 08
|
|
BNE ObjectPathLoop_E37E ; PRG:$2355 Bytes:D0 27
|
|
LDY #$21 ; PRG:$2357 Bytes:A0 21
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2359 Bytes:B1 08
|
|
CLC ; PRG:$235B Bytes:18
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecord_E35C
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecord_E35C:
|
|
ADC #$04 ; PRG:$235C Bytes:69 04
|
|
STA $00 ; PRG:$235E Bytes:85 00
|
|
LDY #$23 ; PRG:$2360 Bytes:A0 23
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2362 Bytes:B1 08
|
|
CLC ; PRG:$2364 Bytes:18
|
|
ADC #$04 ; PRG:$2365 Bytes:69 04
|
|
STA $01 ; PRG:$2367 Bytes:85 01
|
|
JSR UpdateObjectBufferRoutine_E0DF ; PRG:$2369 Bytes:20 DF E0
|
|
LDA $0A ; PRG:$236C Bytes:A5 0A
|
|
CLC ; PRG:$236E Bytes:18
|
|
ADC #$02 ; PRG:$236F Bytes:69 02
|
|
JSR ProcessObjectStateRoutine_E0B2 ; PRG:$2371 Bytes:20 B2 E0
|
|
BCS ObjectPathLoop_E37E ; PRG:$2374 Bytes:B0 08
|
|
CMP #$4E ; PRG:$2376 Bytes:C9 4E
|
|
BEQ ObjectPathOnZero_E380 ; PRG:$2378 Bytes:F0 06
|
|
CMP #$4F ; PRG:$237A Bytes:C9 4F
|
|
BEQ ObjectPathOnZero_E380 ; PRG:$237C Bytes:F0 02
|
|
ObjectPathLoop_E37E:
|
|
CLC ; PRG:$237E Bytes:18
|
|
RTS ; PRG:$237F Bytes:60
|
|
ObjectPathOnZero_E380:
|
|
JSR ReadObjectRecordRoutine_E13F ; PRG:$2380 Bytes:20 3F E1
|
|
BCS ObjectPathLoop_E37E ; PRG:$2383 Bytes:B0 F9
|
|
SEC ; PRG:$2385 Bytes:38
|
|
RTS ; PRG:$2386 Bytes:60
|
|
.byte $00, $00, $00, $00, $0C, $F4, $0C, $F4, $F4, $0C, $F4, $0C, $00, $00, $00, $00 ; PRG:$2387 Bytes:00 00 00 00 0C F4 0C F4 F4 0C F4 0C 00 00 00 00
|
|
.byte $80, $00, $80, $00, $40, $C0, $40, $C0, $81, $80, $80, $81, $81, $80, $80, $81 ; PRG:$2397 Bytes:80 00 80 00 40 C0 40 C0 81 80 80 81 81 80 80 81
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecordRoutine_E3A7
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecordRoutine_E3A7:
|
|
JSR ReadObjectRecordRoutine_E262 ; PRG:$23A7 Bytes:20 62 E2
|
|
LDX $06 ; PRG:$23AA Bytes:A6 06
|
|
LDY $E16F,X ; PRG:$23AC Bytes:BC 6F E1
|
|
LDA #$00 ; PRG:$23AF Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23B1 Bytes:91 08
|
|
DEY ; PRG:$23B3 Bytes:88
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23B4 Bytes:91 08
|
|
;------------------------------------------------------------
|
|
; UpdateObjectRecord_E3B6
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectRecord_E3B6:
|
|
LDA $07 ; PRG:$23B6 Bytes:A5 07
|
|
SEC ; PRG:$23B8 Bytes:38
|
|
SBC #$04 ; PRG:$23B9 Bytes:E9 04
|
|
TAX ; PRG:$23BB Bytes:AA
|
|
LDA $E39F,X ; PRG:$23BC Bytes:BD 9F E3
|
|
LDY #$10 ; PRG:$23BF Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23C1 Bytes:91 08
|
|
LDA $E387,X ; PRG:$23C3 Bytes:BD 87 E3
|
|
LDY #$19 ; PRG:$23C6 Bytes:A0 19
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23C8 Bytes:91 08
|
|
LDA $E38F,X ; PRG:$23CA Bytes:BD 8F E3
|
|
INY ; PRG:$23CD Bytes:C8
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23CE Bytes:91 08
|
|
LDA $E397,X ; PRG:$23D0 Bytes:BD 97 E3
|
|
INY ; PRG:$23D3 Bytes:C8
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23D4 Bytes:91 08
|
|
LDY #$01 ; PRG:$23D6 Bytes:A0 01
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$23D8 Bytes:B1 08
|
|
LDX $06 ; PRG:$23DA Bytes:A6 06
|
|
CPX #$02 ; PRG:$23DC Bytes:E0 02
|
|
PHP ; PRG:$23DE Bytes:08
|
|
BCS UpdateObjectRecordOnCarry_E3E4 ; PRG:$23DF Bytes:B0 03
|
|
JSR ProcessObjectStateRoutine_E405 ; PRG:$23E1 Bytes:20 05 E4
|
|
UpdateObjectRecordOnCarry_E3E4:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23E4 Bytes:91 08
|
|
LDY #$17 ; PRG:$23E6 Bytes:A0 17
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23E8 Bytes:91 08
|
|
LDY #$03 ; PRG:$23EA Bytes:A0 03
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$23EC Bytes:B1 08
|
|
PLP ; PRG:$23EE Bytes:28
|
|
BCC UpdateObjectRecordOnNoCarry_E3F4 ; PRG:$23EF Bytes:90 03
|
|
JSR ProcessObjectStateRoutine_E405 ; PRG:$23F1 Bytes:20 05 E4
|
|
UpdateObjectRecordOnNoCarry_E3F4:
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23F4 Bytes:91 08
|
|
LDY #$18 ; PRG:$23F6 Bytes:A0 18
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23F8 Bytes:91 08
|
|
LDA #$00 ; PRG:$23FA Bytes:A9 00
|
|
LDY #$02 ; PRG:$23FC Bytes:A0 02
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$23FE Bytes:91 08
|
|
LDY #$04 ; PRG:$2400 Bytes:A0 04
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2402 Bytes:91 08
|
|
RTS ; PRG:$2404 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E405
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E405:
|
|
AND #$0F ; PRG:$2405 Bytes:29 0F
|
|
LDX #$04 ; PRG:$2407 Bytes:A2 04
|
|
CMP #$08 ; PRG:$2409 Bytes:C9 08
|
|
BCC ReadObjectRecordOnNoCarry_E40F ; PRG:$240B Bytes:90 02
|
|
LDX #$0C ; PRG:$240D Bytes:A2 0C
|
|
ReadObjectRecordOnNoCarry_E40F:
|
|
STX $04 ; PRG:$240F Bytes:86 04
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2411 Bytes:B1 08
|
|
AND #$F0 ; PRG:$2413 Bytes:29 F0
|
|
ORA $04 ; PRG:$2415 Bytes:05 04
|
|
RTS ; PRG:$2417 Bytes:60
|
|
.byte $00, $04, $02, $04, $00, $04, $02, $04, $00, $04, $02, $04, $00, $04, $02, $04 ; PRG:$2418 Bytes:00 04 02 04 00 04 02 04 00 04 02 04 00 04 02 04
|
|
.byte $40, $40, $40, $C0, $80, $80, $80, $00, $C0, $80, $00, $00, $00, $40, $C0, $C0 ; PRG:$2428 Bytes:40 40 40 C0 80 80 80 00 C0 80 00 00 00 40 C0 C0
|
|
.byte $00, $03, $01, $02, $00, $03, $01, $02, $00, $02, $01, $03, $00, $02, $01, $03 ; PRG:$2438 Bytes:00 03 01 02 00 03 01 02 00 02 01 03 00 02 01 03
|
|
.byte $F8, $F8, $04, $10, $10, $10, $04, $F8, $10, $10, $04, $F8, $F8, $F8, $04, $10 ; PRG:$2448 Bytes:F8 F8 04 10 10 10 04 F8 10 10 04 F8 F8 F8 04 10
|
|
.byte $04, $FC, $F8, $FC, $04, $0C, $10, $0C, $04, $0C, $10, $0C, $04, $FC, $F8, $FC ; PRG:$2458 Bytes:04 FC F8 FC 04 0C 10 0C 04 0C 10 0C 04 FC F8 FC
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBufferRoutine_E468
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBufferRoutine_E468:
|
|
LDA #$00 ; PRG:$2468 Bytes:A9 00
|
|
STA $04 ; PRG:$246A Bytes:85 04
|
|
STA $05 ; PRG:$246C Bytes:85 05
|
|
LDX #$03 ; PRG:$246E Bytes:A2 03
|
|
ReadObjectRecordLoop_E470:
|
|
LDY #$16 ; PRG:$2470 Bytes:A0 16
|
|
LDA $05 ; PRG:$2472 Bytes:A5 05
|
|
CLC ; PRG:$2474 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$2475 Bytes:71 08
|
|
STA $05 ; PRG:$2477 Bytes:85 05
|
|
LDY #$15 ; PRG:$2479 Bytes:A0 15
|
|
LDA $04 ; PRG:$247B Bytes:A5 04
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$247D Bytes:71 08
|
|
STA $04 ; PRG:$247F Bytes:85 04
|
|
DEX ; PRG:$2481 Bytes:CA
|
|
BNE ReadObjectRecordLoop_E470 ; PRG:$2482 Bytes:D0 EC
|
|
LDA $06 ; PRG:$2484 Bytes:A5 06
|
|
CMP #$80 ; PRG:$2486 Bytes:C9 80
|
|
BNE ObjectPathOnNonZero_E491 ; PRG:$2488 Bytes:D0 07
|
|
SEC ; PRG:$248A Bytes:38
|
|
LDA #$00 ; PRG:$248B Bytes:A9 00
|
|
SBC $04 ; PRG:$248D Bytes:E5 04
|
|
STA $04 ; PRG:$248F Bytes:85 04
|
|
ObjectPathOnNonZero_E491:
|
|
LDA $56 ; PRG:$2491 Bytes:A5 56
|
|
BNE ObjectPathOnNonZero_E49B ; PRG:$2493 Bytes:D0 06
|
|
LDX $0A ; PRG:$2495 Bytes:A6 0A
|
|
LDA $75,X ; PRG:$2497 Bytes:B5 75
|
|
BEQ UpdateObjectRecordOnZero_E49F ; PRG:$2499 Bytes:F0 04
|
|
ObjectPathOnNonZero_E49B:
|
|
LDA #$00 ; PRG:$249B Bytes:A9 00
|
|
STA $04 ; PRG:$249D Bytes:85 04
|
|
UpdateObjectRecordOnZero_E49F:
|
|
LDY #$1B ; PRG:$249F Bytes:A0 1B
|
|
CLC ; PRG:$24A1 Bytes:18
|
|
LDA $04 ; PRG:$24A2 Bytes:A5 04
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$24A4 Bytes:71 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$24A6 Bytes:91 08
|
|
JSR ProcessObjectStateRoutine_E045 ; PRG:$24A8 Bytes:20 45 E0
|
|
LDY #$19 ; PRG:$24AB Bytes:A0 19
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$24AD Bytes:B1 08
|
|
SEC ; PRG:$24AF Bytes:38
|
|
SBC $00 ; PRG:$24B0 Bytes:E5 00
|
|
LDY #$17 ; PRG:$24B2 Bytes:A0 17
|
|
CLC ; PRG:$24B4 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$24B5 Bytes:71 08
|
|
LDY #$01 ; PRG:$24B7 Bytes:A0 01
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$24B9 Bytes:91 08
|
|
LDY #$1B ; PRG:$24BB Bytes:A0 1B
|
|
SEC ; PRG:$24BD Bytes:38
|
|
LDA #$40 ; PRG:$24BE Bytes:A9 40
|
|
SBC (CurrentObjectPtrLo),Y ; PRG:$24C0 Bytes:F1 08
|
|
JSR ProcessObjectStateRoutine_E045 ; PRG:$24C2 Bytes:20 45 E0
|
|
LDY #$1A ; PRG:$24C5 Bytes:A0 1A
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$24C7 Bytes:B1 08
|
|
SEC ; PRG:$24C9 Bytes:38
|
|
SBC $00 ; PRG:$24CA Bytes:E5 00
|
|
STA $00 ; PRG:$24CC Bytes:85 00
|
|
LDY #$18 ; PRG:$24CE Bytes:A0 18
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$24D0 Bytes:B1 08
|
|
SEC ; PRG:$24D2 Bytes:38
|
|
SBC $00 ; PRG:$24D3 Bytes:E5 00
|
|
LDY #$03 ; PRG:$24D5 Bytes:A0 03
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$24D7 Bytes:91 08
|
|
LDX #$07 ; PRG:$24D9 Bytes:A2 07
|
|
LDA $06 ; PRG:$24DB Bytes:A5 06
|
|
CMP #$81 ; PRG:$24DD Bytes:C9 81
|
|
BEQ ReadObjectRecordOnZero_E4E3 ; PRG:$24DF Bytes:F0 02
|
|
LDX #$FF ; PRG:$24E1 Bytes:A2 FF
|
|
ReadObjectRecordOnZero_E4E3:
|
|
LDY #$1B ; PRG:$24E3 Bytes:A0 1B
|
|
LDA #$10 ; PRG:$24E5 Bytes:A9 10
|
|
CLC ; PRG:$24E7 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$24E8 Bytes:71 08
|
|
UpdateObjectRecordLoop_E4EA:
|
|
SEC ; PRG:$24EA Bytes:38
|
|
SBC #$20 ; PRG:$24EB Bytes:E9 20
|
|
INX ; PRG:$24ED Bytes:E8
|
|
BCS UpdateObjectRecordLoop_E4EA ; PRG:$24EE Bytes:B0 FA
|
|
LDA $E418,X ; PRG:$24F0 Bytes:BD 18 E4
|
|
LDY #$05 ; PRG:$24F3 Bytes:A0 05
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$24F5 Bytes:91 08
|
|
LDA $E428,X ; PRG:$24F7 Bytes:BD 28 E4
|
|
LDY #$08 ; PRG:$24FA Bytes:A0 08
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$24FC Bytes:91 08
|
|
LDY #$28 ; PRG:$24FE Bytes:A0 28
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2500 Bytes:91 08
|
|
LDY #$38 ; PRG:$2502 Bytes:A0 38
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2504 Bytes:91 08
|
|
LDA $E438,X ; PRG:$2506 Bytes:BD 38 E4
|
|
LDY #$25 ; PRG:$2509 Bytes:A0 25
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$250B Bytes:91 08
|
|
LDA $E418,X ; PRG:$250D Bytes:BD 18 E4
|
|
LDY #$35 ; PRG:$2510 Bytes:A0 35
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2512 Bytes:91 08
|
|
LDA $E448,X ; PRG:$2514 Bytes:BD 48 E4
|
|
LDY #$01 ; PRG:$2517 Bytes:A0 01
|
|
CLC ; PRG:$2519 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$251A Bytes:71 08
|
|
LDY #$31 ; PRG:$251C Bytes:A0 31
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$251E Bytes:91 08
|
|
LDA $E458,X ; PRG:$2520 Bytes:BD 58 E4
|
|
LDY #$03 ; PRG:$2523 Bytes:A0 03
|
|
CLC ; PRG:$2525 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$2526 Bytes:71 08
|
|
LDY #$33 ; PRG:$2528 Bytes:A0 33
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$252A Bytes:91 08
|
|
RTS ; PRG:$252C Bytes:60
|
|
.byte $02, $01, $03, $00, $02, $03, $03, $01, $01, $11, $24 ; PRG:$252D Bytes:02 01 03 00 02 03 03 01 01 11 24
|
|
ObjectPathLoop_E538:
|
|
RTS ; PRG:$2538 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecordRoutine_E539
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecordRoutine_E539:
|
|
LDX $0A ; PRG:$2539 Bytes:A6 0A
|
|
LDA $46,X ; PRG:$253B Bytes:B5 46
|
|
AND #$0F ; PRG:$253D Bytes:29 0F
|
|
BNE ObjectPathLoop_E538 ; PRG:$253F Bytes:D0 F7
|
|
LDY #$1B ; PRG:$2541 Bytes:A0 1B
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2543 Bytes:B1 08
|
|
LDY #$FF ; PRG:$2545 Bytes:A0 FF
|
|
ObjectPathLoop_E547:
|
|
INY ; PRG:$2547 Bytes:C8
|
|
SEC ; PRG:$2548 Bytes:38
|
|
SBC #$40 ; PRG:$2549 Bytes:E9 40
|
|
BCS ObjectPathLoop_E547 ; PRG:$254B Bytes:B0 FA
|
|
ADC #$40 ; PRG:$254D Bytes:69 40
|
|
LDX $06 ; PRG:$254F Bytes:A6 06
|
|
CPX #$80 ; PRG:$2551 Bytes:E0 80
|
|
BEQ ObjectPathOnZero_E59C ; PRG:$2553 Bytes:F0 47
|
|
CMP #$1C ; PRG:$2555 Bytes:C9 1C
|
|
BCS ObjectPathLoop_E538 ; PRG:$2557 Bytes:B0 DF
|
|
INY ; PRG:$2559 Bytes:C8
|
|
UpdateObjectRecordLoop_E55A:
|
|
LDA $E52D,Y ; PRG:$255A Bytes:B9 2D E5
|
|
LDY #$10 ; PRG:$255D Bytes:A0 10
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$255F Bytes:91 08
|
|
LDY #$1B ; PRG:$2561 Bytes:A0 1B
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2563 Bytes:91 08
|
|
STA $06 ; PRG:$2565 Bytes:85 06
|
|
LDY #$15 ; PRG:$2567 Bytes:A0 15
|
|
TAX ; PRG:$2569 Bytes:AA
|
|
AND #$01 ; PRG:$256A Bytes:29 01
|
|
BEQ UpdateObjectRecordOnZero_E571 ; PRG:$256C Bytes:F0 03
|
|
JSR UpdateObjectRecordRoutine_E325 ; PRG:$256E Bytes:20 25 E3
|
|
UpdateObjectRecordOnZero_E571:
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2571 Bytes:B1 08
|
|
STA $00 ; PRG:$2573 Bytes:85 00
|
|
INY ; PRG:$2575 Bytes:C8
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2576 Bytes:B1 08
|
|
LDY $E16F,X ; PRG:$2578 Bytes:BC 6F E1
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$257B Bytes:91 08
|
|
LDA WorkPtr0Lo ; PRG:$257D Bytes:A5 00
|
|
DEY ; PRG:$257F Bytes:88
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2580 Bytes:91 08
|
|
LDY $E532,X ; PRG:$2582 Bytes:BC 32 E5
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$2585 Bytes:B1 08
|
|
AND #$04 ; PRG:$2587 Bytes:29 04
|
|
PHP ; PRG:$2589 Bytes:08
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$258A Bytes:B1 08
|
|
PLP ; PRG:$258C Bytes:28
|
|
BEQ UpdateObjectRecordOnZero_E592 ; PRG:$258D Bytes:F0 03
|
|
CLC ; PRG:$258F Bytes:18
|
|
ADC #$04 ; PRG:$2590 Bytes:69 04
|
|
UpdateObjectRecordOnZero_E592:
|
|
AND #$F8 ; PRG:$2592 Bytes:29 F8
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2594 Bytes:91 08
|
|
INY ; PRG:$2596 Bytes:C8
|
|
LDA #$00 ; PRG:$2597 Bytes:A9 00
|
|
STA (CurrentObjectPtrLo),Y ; PRG:$2599 Bytes:91 08
|
|
ObjectPathLoop_E59B:
|
|
RTS ; PRG:$259B Bytes:60
|
|
ObjectPathOnZero_E59C:
|
|
CMP #$24 ; PRG:$259C Bytes:C9 24
|
|
BCC ObjectPathLoop_E59B ; PRG:$259E Bytes:90 FB
|
|
BCS UpdateObjectRecordLoop_E55A ; PRG:$25A0 Bytes:B0 B8
|
|
.byte $0F, $01, $04, $04, $04, $04, $0F, $01 ; PRG:$25A2 Bytes:0F 01 04 04 04 04 0F 01
|
|
;------------------------------------------------------------
|
|
; ReadObjectRecordRoutine_E5AA
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ReadObjectRecordRoutine_E5AA:
|
|
PHA ; PRG:$25AA Bytes:48
|
|
LDA $06 ; PRG:$25AB Bytes:A5 06
|
|
AND #$03 ; PRG:$25AD Bytes:29 03
|
|
TAX ; PRG:$25AF Bytes:AA
|
|
LDA $E5A2,X ; PRG:$25B0 Bytes:BD A2 E5
|
|
LDY #$01 ; PRG:$25B3 Bytes:A0 01
|
|
CLC ; PRG:$25B5 Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$25B6 Bytes:71 08
|
|
STA $00 ; PRG:$25B8 Bytes:85 00
|
|
LDA $E5A6,X ; PRG:$25BA Bytes:BD A6 E5
|
|
LDY #$03 ; PRG:$25BD Bytes:A0 03
|
|
CLC ; PRG:$25BF Bytes:18
|
|
ADC (CurrentObjectPtrLo),Y ; PRG:$25C0 Bytes:71 08
|
|
STA $01 ; PRG:$25C2 Bytes:85 01
|
|
JSR UpdateObjectBufferRoutine_E0DF ; PRG:$25C4 Bytes:20 DF E0
|
|
PLA ; PRG:$25C7 Bytes:68
|
|
JSR ProcessObjectStateRoutine_E0B2 ; PRG:$25C8 Bytes:20 B2 E0
|
|
RTS ; PRG:$25CB Bytes:60
|
|
.byte $34, $24, $24, $24, $24, $6E, $86, $86, $6F, $24, $24, $24, $24, $34, $24, $24 ; PRG:$25CC Bytes:34 24 24 24 24 6E 86 86 6F 24 24 24 24 34 24 24
|
|
.byte $24, $24, $70, $87, $88, $71, $24, $24, $24, $24, $34, $24, $24, $24, $24, $72 ; PRG:$25DC Bytes:24 24 70 87 88 71 24 24 24 24 34 24 24 24 24 72
|
|
.byte $89, $8A, $73, $24, $9F, $A0, $24, $34, $24, $24, $24, $24, $74, $8B, $8C, $75 ; PRG:$25EC Bytes:89 8A 73 24 9F A0 24 34 24 24 24 24 74 8B 8C 75
|
|
.byte $A1, $A2, $A3, $A4, $34, $24, $24, $24, $24, $76, $8D, $8E, $77, $24, $24, $24 ; PRG:$25FC Bytes:A1 A2 A3 A4 34 24 24 24 24 76 8D 8E 77 24 24 24
|
|
.byte $24, $34, $24, $A5, $A6, $24, $78, $8F, $90, $79, $24, $24, $24, $24, $34, $A7 ; PRG:$260C Bytes:24 34 24 A5 A6 24 78 8F 90 79 24 24 24 24 34 A7
|
|
.byte $A8, $A9, $AA, $7A, $91, $92, $7B, $24, $24, $24, $24, $43, $24, $60, $24, $24 ; PRG:$261C Bytes:A8 A9 AA 7A 91 92 7B 24 24 24 24 43 24 60 24 24
|
|
.byte $7C, $24, $24, $7C, $24, $24, $61, $24, $43, $24, $62, $24, $24, $7D, $24, $24 ; PRG:$262C Bytes:7C 24 24 7C 24 24 61 24 43 24 62 24 24 7D 24 24
|
|
.byte $7E, $24, $24, $63, $24, $43, $24, $64, $24, $24, $81, $93, $24, $82, $94, $24 ; PRG:$263C Bytes:7E 24 24 63 24 43 24 64 24 24 81 93 24 82 94 24
|
|
.byte $65, $24, $43, $24, $66, $95, $24, $85, $96, $24, $85, $97, $24, $67, $98, $43 ; PRG:$264C Bytes:65 24 43 24 66 95 24 85 96 24 85 97 24 67 98 43
|
|
.byte $24, $68, $24, $24, $7F, $24, $24, $80, $24, $24, $69, $24, $43, $24, $6A, $24 ; PRG:$265C Bytes:24 68 24 24 7F 24 24 80 24 24 69 24 43 24 6A 24
|
|
.byte $99, $83, $24, $9A, $84, $24, $24, $6B, $24, $43, $9B, $6C, $24, $9C, $85, $24 ; PRG:$266C Bytes:99 83 24 9A 84 24 24 6B 24 43 9B 6C 24 9C 85 24
|
|
.byte $9D, $85, $24, $9E, $6D, $24, $00, $0D, $00, $34, $41, $34, $00, $0D, $1A, $27 ; PRG:$267C Bytes:9D 85 24 9E 6D 24 00 0D 00 34 41 34 00 0D 1A 27
|
|
.byte $1A, $0D, $00, $34, $00, $0D, $1A, $0D, $00, $34, $41, $4E, $41, $34 ; PRG:$268C Bytes:1A 0D 00 34 00 0D 1A 0D 00 34 41 4E 41 34
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E69A
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E69A:
|
|
LDX #$FB ; PRG:$269A Bytes:A2 FB
|
|
ReadObjectRecordLoop_E69C:
|
|
INX ; PRG:$269C Bytes:E8
|
|
INX ; PRG:$269D Bytes:E8
|
|
INX ; PRG:$269E Bytes:E8
|
|
INX ; PRG:$269F Bytes:E8
|
|
INX ; PRG:$26A0 Bytes:E8
|
|
CPX #$14 ; PRG:$26A1 Bytes:E0 14
|
|
BEQ ObjectPathLoop_E6F2 ; PRG:$26A3 Bytes:F0 4D
|
|
LDA $0370,X ; PRG:$26A5 Bytes:BD 70 03
|
|
BNE ReadObjectRecordLoop_E69C ; PRG:$26A8 Bytes:D0 F2
|
|
LDA #$0C ; PRG:$26AA Bytes:A9 0C
|
|
STA $0370,X ; PRG:$26AC Bytes:9D 70 03
|
|
LDY #$16 ; PRG:$26AF Bytes:A0 16
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$26B1 Bytes:B1 08
|
|
STA $00 ; PRG:$26B3 Bytes:85 00
|
|
DEY ; PRG:$26B5 Bytes:88
|
|
LDA (CurrentObjectPtrLo),Y ; PRG:$26B6 Bytes:B1 08
|
|
LSR A ; PRG:$26B8 Bytes:4A
|
|
ROR $00 ; PRG:$26B9 Bytes:66 00
|
|
LSR A ; PRG:$26BB Bytes:4A
|
|
ROR $00 ; PRG:$26BC Bytes:66 00
|
|
LSR A ; PRG:$26BE Bytes:4A
|
|
ROR $00 ; PRG:$26BF Bytes:66 00
|
|
BNE ObjectPathOnNonZero_E6C5 ; PRG:$26C1 Bytes:D0 02
|
|
INC $00 ; PRG:$26C3 Bytes:E6 00
|
|
ObjectPathOnNonZero_E6C5:
|
|
SEC ; PRG:$26C5 Bytes:38
|
|
LDA #$00 ; PRG:$26C6 Bytes:A9 00
|
|
SBC $00 ; PRG:$26C8 Bytes:E5 00
|
|
LDY #$00 ; PRG:$26CA Bytes:A0 00
|
|
ObjectPathLoop_E6CC:
|
|
INY ; PRG:$26CC Bytes:C8
|
|
SEC ; PRG:$26CD Bytes:38
|
|
SBC $00 ; PRG:$26CE Bytes:E5 00
|
|
BCS ObjectPathLoop_E6CC ; PRG:$26D0 Bytes:B0 FA
|
|
TYA ; PRG:$26D2 Bytes:98
|
|
BNE UpdateObjectBufferOnNonZero_E6D7 ; PRG:$26D3 Bytes:D0 02
|
|
LDA #$FF ; PRG:$26D5 Bytes:A9 FF
|
|
UpdateObjectBufferOnNonZero_E6D7:
|
|
INX ; PRG:$26D7 Bytes:E8
|
|
STA $0370,X ; PRG:$26D8 Bytes:9D 70 03
|
|
INX ; PRG:$26DB Bytes:E8
|
|
LDA $06 ; PRG:$26DC Bytes:A5 06
|
|
STA $0370,X ; PRG:$26DE Bytes:9D 70 03
|
|
INX ; PRG:$26E1 Bytes:E8
|
|
SEC ; PRG:$26E2 Bytes:38
|
|
LDA $03 ; PRG:$26E3 Bytes:A5 03
|
|
SBC #$21 ; PRG:$26E5 Bytes:E9 21
|
|
STA $0370,X ; PRG:$26E7 Bytes:9D 70 03
|
|
INX ; PRG:$26EA Bytes:E8
|
|
LDA WorkPtr1Lo ; PRG:$26EB Bytes:A5 02
|
|
SBC #$00 ; PRG:$26ED Bytes:E9 00
|
|
STA $0370,X ; PRG:$26EF Bytes:9D 70 03
|
|
ObjectPathLoop_E6F2:
|
|
RTS ; PRG:$26F2 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessObjectStateRoutine_E6F3
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessObjectStateRoutine_E6F3:
|
|
LDA #$FF ; PRG:$26F3 Bytes:A9 FF
|
|
STA $07 ; PRG:$26F5 Bytes:85 07
|
|
LDX #$FB ; PRG:$26F7 Bytes:A2 FB
|
|
ObjectPathLoop_E6F9:
|
|
INX ; PRG:$26F9 Bytes:E8
|
|
INX ; PRG:$26FA Bytes:E8
|
|
INX ; PRG:$26FB Bytes:E8
|
|
INX ; PRG:$26FC Bytes:E8
|
|
ProcessObjectStateDispatch_E6FD:
|
|
INX ; PRG:$26FD Bytes:E8
|
|
INC $07 ; PRG:$26FE Bytes:E6 07
|
|
;------------------------------------------------------------
|
|
; UpdateObjectBuffer_E700
|
|
;
|
|
; Global:
|
|
; First-pass object-engine entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Object pointers, entity state, or gameplay state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateObjectBuffer_E700:
|
|
CPX #$14 ; PRG:$2700 Bytes:E0 14
|
|
BEQ ObjectPathLoop_E6F2 ; PRG:$2702 Bytes:F0 EE
|
|
LDY $07 ; PRG:$2704 Bytes:A4 07
|
|
LDA a:$0068,Y ; PRG:$2706 Bytes:B9 68 00
|
|
BNE ObjectPathLoop_E6F9 ; PRG:$2709 Bytes:D0 EE
|
|
LDA $0370,X ; PRG:$270B Bytes:BD 70 03
|
|
BEQ ObjectPathLoop_E6F9 ; PRG:$270E Bytes:F0 E9
|
|
DEC $0370,X ; PRG:$2710 Bytes:DE 70 03
|
|
LDA $0370,X ; PRG:$2713 Bytes:BD 70 03
|
|
STA $00 ; PRG:$2716 Bytes:85 00
|
|
INX ; PRG:$2718 Bytes:E8
|
|
LDA $0370,X ; PRG:$2719 Bytes:BD 70 03
|
|
STA a:$0068,Y ; PRG:$271C Bytes:99 68 00
|
|
INX ; PRG:$271F Bytes:E8
|
|
LDA $0370,X ; PRG:$2720 Bytes:BD 70 03
|
|
CMP #$02 ; PRG:$2723 Bytes:C9 02
|
|
PHP ; PRG:$2725 Bytes:08
|
|
AND #$01 ; PRG:$2726 Bytes:29 01
|
|
BEQ ObjectPathOnZero_E731 ; PRG:$2728 Bytes:F0 07
|
|
LDA #$0C ; PRG:$272A Bytes:A9 0C
|
|
CLC ; PRG:$272C Bytes:18
|
|
ADC $00 ; PRG:$272D Bytes:65 00
|
|
STA $00 ; PRG:$272F Bytes:85 00
|
|
ObjectPathOnZero_E731:
|
|
LDY $00 ; PRG:$2731 Bytes:A4 00
|
|
LDA $E682,Y ; PRG:$2733 Bytes:B9 82 E6
|
|
PLP ; PRG:$2736 Bytes:28
|
|
BCC UpdateObjectBufferOnNoCarry_E73C ; PRG:$2737 Bytes:90 03
|
|
CLC ; PRG:$2739 Bytes:18
|
|
ADC #$5B ; PRG:$273A Bytes:69 5B
|
|
UpdateObjectBufferOnNoCarry_E73C:
|
|
CLC ; PRG:$273C Bytes:18
|
|
ADC #$CC ; PRG:$273D Bytes:69 CC
|
|
STA $02 ; PRG:$273F Bytes:85 02
|
|
LDA #$00 ; PRG:$2741 Bytes:A9 00
|
|
ADC #$E5 ; PRG:$2743 Bytes:69 E5
|
|
STA $03 ; PRG:$2745 Bytes:85 03
|
|
INX ; PRG:$2747 Bytes:E8
|
|
LDA $0370,X ; PRG:$2748 Bytes:BD 70 03
|
|
STA $00 ; PRG:$274B Bytes:85 00
|
|
INX ; PRG:$274D Bytes:E8
|
|
LDA $0370,X ; PRG:$274E Bytes:BD 70 03
|
|
STA $01 ; PRG:$2751 Bytes:85 01
|
|
STX $08 ; PRG:$2753 Bytes:86 08
|
|
JSR UpdateCommandBufferRoutine_F3A1 ; PRG:$2755 Bytes:20 A1 F3
|
|
LDX $08 ; PRG:$2758 Bytes:A6 08
|
|
JMP ProcessObjectStateDispatch_E6FD ; PRG:$275A Bytes:4C FD E6
|
|
.byte $80, $C8, $80, $CB, $80, $D1, $80, $D4, $81, $25, $81, $2E, $81, $37, $81, $E5 ; PRG:$275D Bytes:80 C8 80 CB 80 D1 80 D4 81 25 81 2E 81 37 81 E5
|
|
.byte $81, $F7, $82, $48, $82, $54, $82, $AB, $82, $B1, $83, $0E, $C0, $C8, $C0, $CE ; PRG:$276D Bytes:81 F7 82 48 82 54 82 AB 82 B1 83 0E C0 C8 C0 CE
|
|
.byte $C0, $D1, $C0 ; PRG:$277D Bytes:C0 D1 C0
|
|
|
|
;------------------------------------------------------------
|
|
; Resource and level data with embedded PPU update code
|
|
; CPU $F20B-$F21A
|
|
; PRG $2780-$321A
|
|
;
|
|
; Pass 1 recursively traced from verified entry roots in this region.
|
|
; Direct branches, jumps, and subroutine calls are decoded.
|
|
; Bytes not reached by that trace remain explicit .byte data.
|
|
;------------------------------------------------------------
|
|
|
|
.byte $D7, $C1, $25, $C1, $3A, $C1, $85, $C1, $9A, $C1, $E8, $C1, $F7, $C2, $4B, $C2 ; PRG:$2780 Bytes:D7 C1 25 C1 3A C1 85 C1 9A C1 E8 C1 F7 C2 4B C2
|
|
.byte $54, $C2, $AE, $C2, $B1, $F1, $8B, $F1, $94, $FF, $80, $CB, $80, $D1, $81, $8B ; PRG:$2790 Bytes:54 C2 AE C2 B1 F1 8B F1 94 FF 80 CB 80 D1 81 8B
|
|
.byte $81, $91, $82, $45, $82, $57, $82, $A5, $82, $A8, $82, $AB, $82, $AE, $82, $B1 ; PRG:$27A0 Bytes:81 91 82 45 82 57 82 A5 82 A8 82 AB 82 AE 82 B1
|
|
.byte $82, $B4, $82, $B7, $82, $57, $83, $08, $83, $0B, $83, $0E, $83, $11, $83, $14 ; PRG:$27B0 Bytes:82 B4 82 B7 82 57 83 08 83 0B 83 0E 83 11 83 14
|
|
.byte $C0, $CB, $C0, $CE, $C0, $D1, $C0, $D4, $C1, $2B, $C1, $2E, $C1, $31, $C1, $34 ; PRG:$27C0 Bytes:C0 CB C0 CE C0 D1 C0 D4 C1 2B C1 2E C1 31 C1 34
|
|
.byte $C2, $45, $C2, $48, $C2, $57, $C2, $5A, $C2, $A8, $C2, $B7, $B1, $E5, $B1, $F7 ; PRG:$27D0 Bytes:C2 45 C2 48 C2 57 C2 5A C2 A8 C2 B7 B1 E5 B1 F7
|
|
.byte $FF, $80, $CE, $81, $28, $81, $2B, $81, $2E, $81, $31, $81, $34, $81, $85, $81 ; PRG:$27E0 Bytes:FF 80 CE 81 28 81 2B 81 2E 81 31 81 34 81 85 81
|
|
.byte $88, $81, $94, $81, $97, $81, $E5, $81, $F7, $82, $AE, $83, $0B, $83, $11, $C0 ; PRG:$27F0 Bytes:88 81 94 81 97 81 E5 81 F7 82 AE 83 0B 83 11 C0
|
|
.byte $CE, $C0, $D1, $C1, $28, $C1, $37, $C1, $85, $C1, $88, $C1, $8B, $C1, $94, $C1 ; PRG:$2800 Bytes:CE C0 D1 C1 28 C1 37 C1 85 C1 88 C1 8B C1 94 C1
|
|
.byte $97, $C1, $9A, $C1, $EB, $C1, $F4, $C2, $4B, $C2, $54, $C2, $AB, $C2, $AE, $C2 ; PRG:$2810 Bytes:97 C1 9A C1 EB C1 F4 C2 4B C2 54 C2 AB C2 AE C2
|
|
.byte $B1, $C2, $B4, $B1, $8E, $FF, $80, $CB, $80, $CE, $80, $D1, $81, $28, $81, $34 ; PRG:$2820 Bytes:B1 C2 B4 B1 8E FF 80 CB 80 CE 80 D1 81 28 81 34
|
|
.byte $81, $85, $81, $97, $81, $E5, $81, $E8, $81, $EB, $81, $EE, $81, $F1, $81, $F4 ; PRG:$2830 Bytes:81 85 81 97 81 E5 81 E8 81 EB 81 EE 81 F1 81 F4
|
|
.byte $81, $F7, $83, $08, $83, $0B, $83, $0E, $83, $11, $83, $14, $C0, $CB, $C0, $D4 ; PRG:$2840 Bytes:81 F7 83 08 83 0B 83 0E 83 11 83 14 C0 CB C0 D4
|
|
.byte $C1, $28, $C1, $37, $C1, $85, $C1, $9A, $C1, $E8, $C1, $F7, $C2, $48, $C2, $57 ; PRG:$2850 Bytes:C1 28 C1 37 C1 85 C1 9A C1 E8 C1 F7 C2 48 C2 57
|
|
.byte $C2, $A8, $C2, $B7, $F2, $4B, $F2, $54, $FF, $80, $CE, $80, $D1, $81, $31, $81 ; PRG:$2860 Bytes:C2 A8 C2 B7 F2 4B F2 54 FF 80 CE 80 D1 81 31 81
|
|
.byte $85, $81, $88, $81, $8B, $81, $91, $81, $94, $81, $97, $81, $E5, $81, $F7, $82 ; PRG:$2870 Bytes:85 81 88 81 8B 81 91 81 94 81 97 81 E5 81 F7 82
|
|
.byte $4B, $82, $51, $82, $AB, $82, $AE, $82, $B1, $83, $0B, $83, $11, $C0, $CE, $C0 ; PRG:$2880 Bytes:4B 82 51 82 AB 82 AE 82 B1 83 0B 83 11 C0 CE C0
|
|
.byte $D4, $C1, $2E, $C1, $31, $C1, $85, $C1, $9A, $C2, $AB, $C2, $AE, $C2, $B1, $C2 ; PRG:$2890 Bytes:D4 C1 2E C1 31 C1 85 C1 9A C2 AB C2 AE C2 B1 C2
|
|
.byte $B4, $B1, $EB, $B1, $F1, $FF, $80, $C8, $80, $D4, $81, $28, $81, $2B, $81, $2E ; PRG:$28A0 Bytes:B4 B1 EB B1 F1 FF 80 C8 80 D4 81 28 81 2B 81 2E
|
|
.byte $81, $31, $81, $34, $81, $88, $81, $94, $82, $4E, $82, $AB, $82, $AE, $82, $B1 ; PRG:$28B0 Bytes:81 31 81 34 81 88 81 94 82 4E 82 AB 82 AE 82 B1
|
|
.byte $83, $0E, $C0, $C8, $C0, $CB, $C0, $D4, $C0, $D7, $C1, $2B, $C1, $34, $C1, $88 ; PRG:$28C0 Bytes:83 0E C0 C8 C0 CB C0 D4 C0 D7 C1 2B C1 34 C1 88
|
|
.byte $C1, $97, $C2, $4B, $C2, $54, $C2, $AE, $C2, $B1, $F1, $8E, $F1, $91, $FF, $81 ; PRG:$28D0 Bytes:C1 97 C2 4B C2 54 C2 AE C2 B1 F1 8E F1 91 FF 81
|
|
.byte $28, $81, $34, $81, $85, $81, $8B, $81, $91, $81, $97, $81, $E5, $81, $EB, $81 ; PRG:$28E0 Bytes:28 81 34 81 85 81 8B 81 91 81 97 81 E5 81 EB 81
|
|
.byte $F1, $81, $F7, $82, $4E, $83, $0E, $C1, $28, $C1, $2B, $C1, $34, $C1, $37, $C1 ; PRG:$28F0 Bytes:F1 81 F7 82 4E 83 0E C1 28 C1 2B C1 34 C1 37 C1
|
|
.byte $85, $C1, $8E, $C1, $91, $C1, $9A, $C1, $EB, $C1, $F4, $C2, $AE, $C2, $B1, $B1 ; PRG:$2900 Bytes:85 C1 8E C1 91 C1 9A C1 EB C1 F4 C2 AE C2 B1 B1
|
|
.byte $2E, $F2, $AB, $F2, $B4, $FF, $80, $CE, $81, $2B, $81, $31, $81, $88, $81, $94 ; PRG:$2910 Bytes:2E F2 AB F2 B4 FF 80 CE 81 2B 81 31 81 88 81 94
|
|
.byte $81, $EE, $82, $4B, $82, $4E, $82, $51, $82, $AB, $82, $B1, $83, $0B, $83, $0E ; PRG:$2920 Bytes:81 EE 82 4B 82 4E 82 51 82 AB 82 B1 83 0B 83 0E
|
|
.byte $83, $11, $C0, $CE, $C0, $D1, $C1, $2B, $C1, $34, $C1, $88, $C1, $97, $C1, $EE ; PRG:$2930 Bytes:83 11 C0 CE C0 D1 C1 2B C1 34 C1 88 C1 97 C1 EE
|
|
.byte $C1, $F1, $C2, $AB, $C2, $B4, $B1, $8E, $FF, $81, $88, $81, $8B, $81, $91, $81 ; PRG:$2940 Bytes:C1 F1 C2 AB C2 B4 B1 8E FF 81 88 81 8B 81 91 81
|
|
.byte $94, $81, $E5, $81, $EE, $81, $F7, $82, $A8, $82, $AB, $82, $B1, $82, $B4, $C0 ; PRG:$2950 Bytes:94 81 E5 81 EE 81 F7 82 A8 82 AB 82 B1 82 B4 C0
|
|
.byte $C5, $C0, $DA, $C1, $25, $C1, $3A, $C1, $85, $C1, $88, $C1, $8E, $C1, $91, $C1 ; PRG:$2960 Bytes:C5 C0 DA C1 25 C1 3A C1 85 C1 88 C1 8E C1 91 C1
|
|
.byte $97, $C1, $9A, $C1, $E8, $C1, $EE, $C1, $F1, $C1, $F7, $C2, $48, $C2, $4E, $C2 ; PRG:$2970 Bytes:97 C1 9A C1 E8 C1 EE C1 F1 C1 F7 C2 48 C2 4E C2
|
|
.byte $51, $C2, $57, $B1, $28, $B1, $34, $FF, $81, $25, $81, $37, $81, $88, $81, $94 ; PRG:$2980 Bytes:51 C2 57 B1 28 B1 34 FF 81 25 81 37 81 88 81 94
|
|
.byte $81, $EB, $81, $EE, $81, $F1, $82, $4B, $82, $51, $82, $A5, $82, $A8, $82, $AE ; PRG:$2990 Bytes:81 EB 81 EE 81 F1 82 4B 82 51 82 A5 82 A8 82 AE
|
|
.byte $82, $B4, $82, $B7, $C1, $25, $C1, $28, $C1, $37, $C1, $3A, $C1, $85, $C1, $8B ; PRG:$29A0 Bytes:82 B4 82 B7 C1 25 C1 28 C1 37 C1 3A C1 85 C1 8B
|
|
.byte $C1, $94, $C1, $9A, $C1, $E5, $C1, $EE, $C1, $F1, $C1, $FA, $C2, $45, $C2, $4B ; PRG:$29B0 Bytes:C1 94 C1 9A C1 E5 C1 EE C1 F1 C1 FA C2 45 C2 4B
|
|
.byte $C2, $4E, $C2, $51, $C2, $54, $C2, $5A, $F1, $2E, $F1, $31, $FF, $80, $C5, $80 ; PRG:$29C0 Bytes:C2 4E C2 51 C2 54 C2 5A F1 2E F1 31 FF 80 C5 80
|
|
.byte $D7, $81, $28, $81, $2B, $81, $2E, $81, $31, $81, $34, $81, $85, $81, $97, $82 ; PRG:$29D0 Bytes:D7 81 28 81 2B 81 2E 81 31 81 34 81 85 81 97 82
|
|
.byte $48, $82, $4E, $82, $54, $82, $AB, $82, $AE, $82, $B1, $C0, $C5, $C0, $C8, $C0 ; PRG:$29E0 Bytes:48 82 4E 82 54 82 AB 82 AE 82 B1 C0 C5 C0 C8 C0
|
|
.byte $D7, $C0, $DA, $C1, $25, $C1, $3A, $C1, $88, $C1, $97, $C1, $E8, $C1, $F7, $C2 ; PRG:$29F0 Bytes:D7 C0 DA C1 25 C1 3A C1 88 C1 97 C1 E8 C1 F7 C2
|
|
.byte $4B, $C2, $4E, $C2, $51, $C2, $54, $B2, $A5, $B2, $B7, $B1, $8B, $B1, $91, $FF ; PRG:$2A00 Bytes:4B C2 4E C2 51 C2 54 B2 A5 B2 B7 B1 8B B1 91 FF
|
|
.byte $81, $8B, $81, $8E, $81, $97, $81, $E5, $81, $E8, $81, $EB, $81, $EE, $81, $F1 ; PRG:$2A10 Bytes:81 8B 81 8E 81 97 81 E5 81 E8 81 EB 81 EE 81 F1
|
|
.byte $81, $F4, $81, $F7, $82, $54, $82, $57, $82, $A5, $82, $A8, $82, $AB, $82, $AE ; PRG:$2A20 Bytes:81 F4 81 F7 82 54 82 57 82 A5 82 A8 82 AB 82 AE
|
|
.byte $82, $B1, $82, $B7, $C1, $2E, $C1, $8B, $C1, $91, $C1, $97, $C1, $9A, $C1, $E5 ; PRG:$2A30 Bytes:82 B1 82 B7 C1 2E C1 8B C1 91 C1 97 C1 9A C1 E5
|
|
.byte $C1, $F7, $C2, $45, $C2, $54, $C2, $57, $C2, $5A, $F0, $C8, $F0, $D7, $FF, $80 ; PRG:$2A40 Bytes:C1 F7 C2 45 C2 54 C2 57 C2 5A F0 C8 F0 D7 FF 80
|
|
.byte $C8, $80, $D4, $81, $28, $81, $34, $81, $8E, $81, $E5, $81, $EE, $81, $F7, $82 ; PRG:$2A50 Bytes:C8 80 D4 81 28 81 34 81 8E 81 E5 81 EE 81 F7 82
|
|
.byte $45, $82, $4E, $82, $57, $82, $A8, $82, $B4, $83, $08, $83, $14, $C0, $C8, $C0 ; PRG:$2A60 Bytes:45 82 4E 82 57 82 A8 82 B4 83 08 83 14 C0 C8 C0
|
|
.byte $CB, $C0, $D4, $C0, $D7, $C1, $8E, $C1, $91, $C1, $E5, $C1, $E8, $C1, $EE, $C1 ; PRG:$2A70 Bytes:CB C0 D4 C0 D7 C1 8E C1 91 C1 E5 C1 E8 C1 EE C1
|
|
.byte $F1, $C1, $F7, $C1, $FA, $C2, $A8, $C2, $AB, $C2, $B4, $C2, $B7, $B1, $88, $B1 ; PRG:$2A80 Bytes:F1 C1 F7 C1 FA C2 A8 C2 AB C2 B4 C2 B7 B1 88 B1
|
|
.byte $94, $F1, $EB, $F1, $F4, $FF, $80, $C5, $80, $C8, $80, $D4, $80, $D7, $81, $8B ; PRG:$2A90 Bytes:94 F1 EB F1 F4 FF 80 C5 80 C8 80 D4 80 D7 81 8B
|
|
.byte $81, $8E, $81, $91, $82, $4B, $82, $4E, $82, $51, $83, $05, $83, $08, $83, $14 ; PRG:$2AA0 Bytes:81 8E 81 91 82 4B 82 4E 82 51 83 05 83 08 83 14
|
|
.byte $83, $17, $C0, $C5, $C0, $CB, $C0, $D4, $C0, $DA, $C1, $25, $C1, $2B, $C1, $34 ; PRG:$2AB0 Bytes:83 17 C0 C5 C0 CB C0 D4 C0 DA C1 25 C1 2B C1 34
|
|
.byte $C1, $3A, $C1, $85, $C1, $9A, $C1, $E5, $C1, $FA, $C2, $45, $C2, $4B, $C2, $54 ; PRG:$2AC0 Bytes:C1 3A C1 85 C1 9A C1 E5 C1 FA C2 45 C2 4B C2 54
|
|
.byte $C2, $5A, $C2, $A5, $C2, $AB, $C2, $B4, $C2, $BA, $B1, $EB, $B1, $F1, $F1, $88 ; PRG:$2AD0 Bytes:C2 5A C2 A5 C2 AB C2 B4 C2 BA B1 EB B1 F1 F1 88
|
|
.byte $F1, $97, $F2, $48, $F2, $57, $FF, $81, $25, $81, $28, $81, $34, $81, $37, $81 ; PRG:$2AE0 Bytes:F1 97 F2 48 F2 57 FF 81 25 81 28 81 34 81 37 81
|
|
.byte $85, $81, $88, $81, $8B, $81, $8E, $81, $91, $81, $94, $81, $97, $82, $45, $82 ; PRG:$2AF0 Bytes:85 81 88 81 8B 81 8E 81 91 81 94 81 97 82 45 82
|
|
.byte $48, $82, $4B, $82, $4E, $82, $51, $82, $54, $82, $57, $82, $A5, $82, $A8, $82 ; PRG:$2B00 Bytes:48 82 4B 82 4E 82 51 82 54 82 57 82 A5 82 A8 82
|
|
.byte $B4, $82, $B7, $C1, $25, $C1, $2B, $C1, $34, $C1, $3A, $C1, $8B, $C1, $94, $C1 ; PRG:$2B10 Bytes:B4 82 B7 C1 25 C1 2B C1 34 C1 3A C1 8B C1 94 C1
|
|
.byte $EB, $C1, $F4, $C2, $45, $C2, $4B, $C2, $54, $C2, $5A, $B1, $E5, $B1, $EE, $B1 ; PRG:$2B20 Bytes:EB C1 F4 C2 45 C2 4B C2 54 C2 5A B1 E5 B1 EE B1
|
|
.byte $F7, $FF, $80, $C5, $80, $D7, $81, $28, $81, $34, $81, $85, $81, $88, $81, $94 ; PRG:$2B30 Bytes:F7 FF 80 C5 80 D7 81 28 81 34 81 85 81 88 81 94
|
|
.byte $81, $97, $82, $45, $82, $48, $82, $54, $82, $57, $82, $A5, $82, $B7, $83, $08 ; PRG:$2B40 Bytes:81 97 82 45 82 48 82 54 82 57 82 A5 82 B7 83 08
|
|
.byte $83, $14, $C0, $C5, $C0, $C8, $C0, $D7, $C0, $DA, $C1, $25, $C1, $2B, $C1, $34 ; PRG:$2B50 Bytes:83 14 C0 C5 C0 C8 C0 D7 C0 DA C1 25 C1 2B C1 34
|
|
.byte $C1, $3A, $C2, $45, $C2, $4B, $C2, $54, $C2, $5A, $C2, $A8, $C2, $AB, $C2, $B4 ; PRG:$2B60 Bytes:C1 3A C2 45 C2 4B C2 54 C2 5A C2 A8 C2 AB C2 B4
|
|
.byte $C2, $B7, $B1, $E5, $B1, $EB, $B1, $F1, $B1, $F7, $FF, $80, $C5, $80, $D7, $81 ; PRG:$2B70 Bytes:C2 B7 B1 E5 B1 EB B1 F1 B1 F7 FF 80 C5 80 D7 81
|
|
.byte $85, $81, $2E, $81, $97, $82, $45, $82, $AE, $82, $57, $83, $05, $83, $17, $C0 ; PRG:$2B80 Bytes:85 81 2E 81 97 82 45 82 AE 82 57 83 05 83 17 C0
|
|
.byte $C8, $C0, $D7, $C1, $8E, $C1, $91, $C1, $EE, $C1, $F1, $C2, $A8, $C2, $B7, $B1 ; PRG:$2B90 Bytes:C8 C0 D7 C1 8E C1 91 C1 EE C1 F1 C2 A8 C2 B7 B1
|
|
.byte $E8, $B1, $F4, $F1, $2B, $F1, $34, $F2, $4B, $F2, $54, $F1, $22, $F2, $5D, $FF ; PRG:$2BA0 Bytes:E8 B1 F4 F1 2B F1 34 F2 4B F2 54 F1 22 F2 5D FF
|
|
.byte $81, $25, $81, $2E, $81, $37, $81, $82, $81, $88, $81, $8E, $81, $94, $81, $9A ; PRG:$2BB0 Bytes:81 25 81 2E 81 37 81 82 81 88 81 8E 81 94 81 9A
|
|
.byte $82, $42, $82, $48, $82, $4E, $82, $54, $82, $5A, $82, $A5, $82, $AE, $82, $B7 ; PRG:$2BC0 Bytes:82 42 82 48 82 4E 82 54 82 5A 82 A5 82 AE 82 B7
|
|
.byte $C0, $C8, $C0, $D7, $C2, $A8, $C2, $B7, $B1, $E8, $B1, $EE, $B1, $F4, $F0, $CB ; PRG:$2BD0 Bytes:C0 C8 C0 D7 C2 A8 C2 B7 B1 E8 B1 EE B1 F4 F0 CB
|
|
.byte $F0, $D4, $F2, $AB, $F2, $B4, $FF, $81, $2B, $81, $2E, $81, $31, $81, $85, $81 ; PRG:$2BE0 Bytes:F0 D4 F2 AB F2 B4 FF 81 2B 81 2E 81 31 81 85 81
|
|
.byte $97, $81, $EE, $82, $45, $82, $57, $82, $AB, $82, $AE, $82, $B1, $C0, $CB, $C0 ; PRG:$2BF0 Bytes:97 81 EE 82 45 82 57 82 AB 82 AE 82 B1 C0 CB C0
|
|
.byte $D4, $C1, $88, $C1, $97, $C1, $E8, $C1, $F7, $C2, $AB, $C2, $B4, $B1, $8E, $B2 ; PRG:$2C00 Bytes:D4 C1 88 C1 97 C1 E8 C1 F7 C2 AB C2 B4 B1 8E B2
|
|
.byte $4E, $F0, $C8, $F0, $D7, $F2, $A8, $F2, $B7, $F1, $3D, $F2, $42, $FF, $80, $C5 ; PRG:$2C10 Bytes:4E F0 C8 F0 D7 F2 A8 F2 B7 F1 3D F2 42 FF 80 C5
|
|
.byte $80, $C8, $80, $D4, $80, $D7, $81, $2B, $81, $31, $82, $AB, $82, $B1, $83, $05 ; PRG:$2C20 Bytes:80 C8 80 D4 80 D7 81 2B 81 31 82 AB 82 B1 83 05
|
|
.byte $83, $08, $83, $14, $83, $17, $C1, $22, $C1, $3D, $C1, $2B, $C1, $34, $C2, $4B ; PRG:$2C30 Bytes:83 08 83 14 83 17 C1 22 C1 3D C1 2B C1 34 C2 4B
|
|
.byte $C2, $54, $C2, $42, $C2, $5D, $B1, $8E, $B2, $4E, $B1, $E8, $B1, $F4, $F1, $28 ; PRG:$2C40 Bytes:C2 54 C2 42 C2 5D B1 8E B2 4E B1 E8 B1 F4 F1 28
|
|
.byte $F1, $37, $F2, $48, $F2, $57, $FF, $3F, $00, $20, $0F, $30, $17, $25, $0F, $30 ; PRG:$2C50 Bytes:F1 37 F2 48 F2 57 FF 3F 00 20 0F 30 17 25 0F 30
|
|
.byte $17, $17, $0F, $30, $25, $05, $0F, $30, $21, $01, $0F, $30, $27, $16, $0F, $30 ; PRG:$2C60 Bytes:17 17 0F 30 25 05 0F 30 21 01 0F 30 27 16 0F 30
|
|
.byte $27, $1A, $0F, $30, $1C, $01, $0F, $30, $27, $08, $60, $20, $50, $04, $2A, $2B ; PRG:$2C70 Bytes:27 1A 0F 30 1C 01 0F 30 27 08 60 20 50 04 2A 2B
|
|
.byte $2C, $2D, $20, $49, $04, $26, $27, $28, $29, $20, $C2, $D3, $4E, $20, $C5, $D3 ; PRG:$2C80 Bytes:2C 2D 20 49 04 26 27 28 29 20 C2 D3 4E 20 C5 D3
|
|
.byte $4E, $20, $C8, $D3, $4E, $20, $CB, $D3, $4E, $20, $CE, $D3, $4E, $20, $D1, $D3 ; PRG:$2C90 Bytes:4E 20 C8 D3 4E 20 CB D3 4E 20 CE D3 4E 20 D1 D3
|
|
.byte $4E, $20, $D4, $D3, $4E, $20, $D7, $D3, $4E, $20, $DA, $D3, $4E, $20, $DD, $D3 ; PRG:$2CA0 Bytes:4E 20 D4 D3 4E 20 D7 D3 4E 20 DA D3 4E 20 DD D3
|
|
.byte $4E, $20, $E2, $5C, $24, $21, $02, $5C, $24, $21, $42, $5C, $24, $21, $62, $5C ; PRG:$2CB0 Bytes:4E 20 E2 5C 24 21 02 5C 24 21 42 5C 24 21 62 5C
|
|
.byte $24, $21, $A2, $5C, $24, $21, $C2, $5C, $24, $22, $02, $5C, $24, $22, $22, $5C ; PRG:$2CC0 Bytes:24 21 A2 5C 24 21 C2 5C 24 22 02 5C 24 22 22 5C
|
|
.byte $24, $22, $62, $5C, $24, $22, $82, $5C, $24, $22, $C2, $5C, $24, $22, $E2, $5C ; PRG:$2CD0 Bytes:24 22 62 5C 24 22 82 5C 24 22 C2 5C 24 22 E2 5C
|
|
.byte $24, $60, $21, $02, $CF, $32, $21, $1D, $CF, $32, $20, $67, $52, $39, $23, $67 ; PRG:$2CE0 Bytes:24 60 21 02 CF 32 21 1D CF 32 20 67 52 39 23 67
|
|
.byte $52, $39, $60, $04, $08, $22, $0F, $38, $18, $38, $D8, $4C, $57, $EC, $4C, $7B ; PRG:$2CF0 Bytes:52 39 60 04 08 22 0F 38 18 38 D8 4C 57 EC 4C 7B
|
|
.byte $EC, $4C, $E2, $EC, $00, $00, $65, $10, $79, $23, $45, $33, $59, $00, $C2, $10 ; PRG:$2D00 Bytes:EC 4C E2 EC 00 00 65 10 79 23 45 33 59 00 C2 10
|
|
.byte $DC, $22, $E2, $32, $FC, $43, $1A, $53, $04, $60, $BA, $70, $A4, $FF, $06, $0A ; PRG:$2D10 Bytes:DC 22 E2 32 FC 43 1A 53 04 60 BA 70 A4 FF 06 0A
|
|
.byte $22, $C6, $22, $D8, $20, $60, $20, $90, $4C, $57, $EC, $3F, $08, $04, $0F, $30 ; PRG:$2D20 Bytes:22 C6 22 D8 20 60 20 90 4C 57 EC 3F 08 04 0F 30
|
|
.byte $2A, $0A, $4C, $7B, $EC, $4C, $E2, $EC, $00, $00, $65, $10, $79, $23, $45, $33 ; PRG:$2D30 Bytes:2A 0A 4C 7B EC 4C E2 EC 00 00 65 10 79 23 45 33
|
|
.byte $59, $00, $C2, $10, $DC, $22, $E2, $32, $FC, $43, $1A, $53, $04, $60, $BA, $70 ; PRG:$2D40 Bytes:59 00 C2 10 DC 22 E2 32 FC 43 1A 53 04 60 BA 70
|
|
.byte $A4, $C1, $E8, $C2, $4E, $C2, $51, $C1, $F7, $82, $48, $82, $54, $FF, $06, $0A ; PRG:$2D50 Bytes:A4 C1 E8 C2 4E C2 51 C1 F7 82 48 82 54 FF 06 0A
|
|
.byte $22, $0C, $22, $12, $38, $78, $B0, $78, $4C, $57, $EC, $3F, $08, $04, $0F, $30 ; PRG:$2D60 Bytes:22 0C 22 12 38 78 B0 78 4C 57 EC 3F 08 04 0F 30
|
|
.byte $21, $01, $4C, $7B, $EC, $20, $64, $46, $39, $20, $CD, $46, $39, $20, $76, $46 ; PRG:$2D70 Bytes:21 01 4C 7B EC 20 64 46 39 20 CD 46 39 20 76 46
|
|
.byte $39, $23, $64, $46, $39, $23, $0D, $46, $39, $23, $76, $46, $39, $20, $A2, $D5 ; PRG:$2D80 Bytes:39 23 64 46 39 23 0D 46 39 23 76 46 39 20 A2 D5
|
|
.byte $32, $20, $BD, $D5, $32, $00, $00, $62, $10, $7C, $23, $42, $33, $5C, $00, $74 ; PRG:$2D90 Bytes:32 20 BD D5 32 00 00 62 10 7C 23 42 33 5C 00 74
|
|
.byte $10, $6A, $23, $54, $33, $4A, $43, $0B, $53, $13, $60, $AB, $70, $B3, $FF, $0A ; PRG:$2DA0 Bytes:10 6A 23 54 33 4A 43 0B 53 13 60 AB 70 B3 FF 0A
|
|
.byte $0E, $21, $46, $21, $58, $22, $CC, $22, $D2, $20, $60, $20, $90, $4C, $57, $EC ; PRG:$2DB0 Bytes:0E 21 46 21 58 22 CC 22 D2 20 60 20 90 4C 57 EC
|
|
.byte $3F, $00, $0C, $0F, $30, $17, $2A, $0F, $30, $17, $17, $0F, $30, $23, $03, $4C ; PRG:$2DC0 Bytes:3F 00 0C 0F 30 17 2A 0F 30 17 17 0F 30 23 03 4C
|
|
.byte $7B, $EC, $4C, $E2, $EC, $20, $60, $60, $39, $20, $6F, $42, $24, $23, $60, $60 ; PRG:$2DD0 Bytes:7B EC 4C E2 EC 20 60 60 39 20 6F 42 24 23 60 60
|
|
.byte $39, $23, $6F, $42, $24, $20, $C0, $D3, $39, $20, $DF, $D3, $39, $20, $AE, $C3 ; PRG:$2DE0 Bytes:39 23 6F 42 24 20 C0 D3 39 20 DF D3 39 20 AE C3
|
|
.byte $32, $20, $B1, $C3, $32, $22, $EE, $C3, $32, $22, $F1, $C3, $32, $20, $E0, $D1 ; PRG:$2DF0 Bytes:32 20 B1 C3 32 22 EE C3 32 22 F1 C3 32 20 E0 D1
|
|
.byte $FF, $21, $01, $CF, $FF, $21, $1E, $CF, $FF, $20, $FF, $D1, $FF, $00, $00, $71 ; PRG:$2E00 Bytes:FF 21 01 CF FF 21 1E CF FF 20 FF D1 FF 00 00 71
|
|
.byte $10, $6D, $23, $51, $33, $4D, $42, $AE, $52, $B0, $61, $0E, $71, $10, $40, $DD ; PRG:$2E10 Bytes:10 6D 23 51 33 4D 42 AE 52 B0 61 0E 71 10 40 DD
|
|
.byte $50, $C1, $62, $FD, $72, $E1, $FF, $0A, $0E, $22, $06, $22, $0C, $22, $12, $22 ; PRG:$2E20 Bytes:50 C1 62 FD 72 E1 FF 0A 0E 22 06 22 0C 22 12 22
|
|
.byte $18, $20, $18, $20, $D8, $4C, $57, $EC, $3F, $08, $04, $0F, $30, $27, $07, $4C ; PRG:$2E30 Bytes:18 20 18 20 D8 4C 57 EC 3F 08 04 0F 30 27 07 4C
|
|
.byte $7B, $EC, $20, $64, $49, $39, $20, $73, $49, $39, $23, $64, $49, $39, $23, $73 ; PRG:$2E40 Bytes:7B EC 20 64 49 39 20 73 49 39 23 64 49 39 23 73
|
|
.byte $49, $39, $20, $C0, $01, $39, $20, $DF, $01, $39, $23, $00, $01, $39, $23, $1F ; PRG:$2E50 Bytes:49 39 20 C0 01 39 20 DF 01 39 23 00 01 39 23 1F
|
|
.byte $01, $39, $00, $00, $62, $10, $7C, $23, $42, $33, $5C, $00, $71, $10, $6D, $23 ; PRG:$2E60 Bytes:01 39 00 00 62 10 7C 23 42 33 5C 00 71 10 6D 23
|
|
.byte $51, $33, $4D, $43, $1D, $53, $01, $60, $BD, $70, $A1, $43, $0E, $53, $10, $60 ; PRG:$2E70 Bytes:51 33 4D 43 1D 53 01 60 BD 70 A1 43 0E 53 10 60
|
|
.byte $AE, $70, $B0, $C1, $25, $C1, $3A, $C2, $45, $C2, $5A, $91, $E2, $91, $FA, $FF ; PRG:$2E80 Bytes:AE 70 B0 C1 25 C1 3A C2 45 C2 5A 91 E2 91 FA FF
|
|
.byte $02, $06, $38, $60, $38, $90, $4C, $57, $EC, $3F, $04, $04, $0F, $30, $11, $11 ; PRG:$2E90 Bytes:02 06 38 60 38 90 4C 57 EC 3F 04 04 0F 30 11 11
|
|
.byte $3F, $1C, $04, $0F, $30, $21, $01, $4C, $89, $EC, $20, $63, $5A, $BF, $23, $63 ; PRG:$2EA0 Bytes:3F 1C 04 0F 30 21 01 4C 89 EC 20 63 5A BF 23 63
|
|
.byte $5A, $BF, $20, $82, $D7, $BD, $20, $9D, $D7, $BD, $21, $8C, $48, $BF, $22, $4C ; PRG:$2EB0 Bytes:5A BF 20 82 D7 BD 20 9D D7 BD 21 8C 48 BF 22 4C
|
|
.byte $48, $BF, $21, $AB, $C5, $BD, $21, $B4, $C5, $BD, $21, $AC, $48, $FF, $21, $CC ; PRG:$2EC0 Bytes:48 BF 21 AB C5 BD 21 B4 C5 BD 21 AC 48 FF 21 CC
|
|
.byte $08, $FF, $0B, $18, $17, $1E, $1C, $AD, $FF, $21, $EC, $48, $FF, $22, $0C, $08 ; PRG:$2ED0 Bytes:08 FF 0B 18 17 1E 1C AD FF 21 EC 48 FF 22 0C 08
|
|
.byte $2A, $2B, $2C, $2D, $FF, $FF, $FF, $FF, $22, $2C, $48, $FF, $20, $62, $01, $B9 ; PRG:$2EE0 Bytes:2A 2B 2C 2D FF FF FF FF 22 2C 48 FF 20 62 01 B9
|
|
.byte $20, $7D, $01, $C2, $23, $62, $01, $BA, $23, $7D, $01, $C3, $21, $8B, $01, $BC ; PRG:$2EF0 Bytes:20 7D 01 C2 23 62 01 BA 23 7D 01 C3 21 8B 01 BC
|
|
.byte $21, $94, $01, $C0, $22, $4B, $01, $BE, $22, $54, $01, $C1, $00, $80, $C5, $80 ; PRG:$2F00 Bytes:21 94 01 C0 22 4B 01 BE 22 54 01 C1 00 80 C5 80
|
|
.byte $C8, $80, $CB, $80, $CE, $80, $D1, $80, $D4, $80, $D7, $81, $25, $81, $28, $81 ; PRG:$2F10 Bytes:C8 80 CB 80 CE 80 D1 80 D4 80 D7 81 25 81 28 81
|
|
.byte $2B, $81, $2E, $81, $31, $81, $34, $81, $37, $81, $85, $81, $97, $81, $E5, $81 ; PRG:$2F20 Bytes:2B 81 2E 81 31 81 34 81 37 81 85 81 97 81 E5 81
|
|
.byte $F7, $82, $45, $82, $57, $82, $A5, $82, $A8, $82, $AB, $82, $AE, $82, $B1, $82 ; PRG:$2F30 Bytes:F7 82 45 82 57 82 A5 82 A8 82 AB 82 AE 82 B1 82
|
|
.byte $B4, $82, $B7, $83, $05, $83, $08, $83, $0B, $83, $0E, $83, $11, $83, $14, $83 ; PRG:$2F40 Bytes:B4 82 B7 83 05 83 08 83 0B 83 0E 83 11 83 14 83
|
|
.byte $17, $C0, $C5, $C0, $C8, $C0, $CB, $C0, $CE, $C0, $D1, $C0, $D4, $C0, $D7, $C0 ; PRG:$2F50 Bytes:17 C0 C5 C0 C8 C0 CB C0 CE C0 D1 C0 D4 C0 D7 C0
|
|
.byte $DA, $C1, $25, $C1, $28, $C1, $37, $C1, $3A, $C1, $85, $C1, $88, $C1, $97, $C1 ; PRG:$2F60 Bytes:DA C1 25 C1 28 C1 37 C1 3A C1 85 C1 88 C1 97 C1
|
|
.byte $9A, $C1, $E5, $C1, $E8, $C1, $F7, $C1, $FA, $C2, $45, $C2, $48, $C2, $57, $C2 ; PRG:$2F70 Bytes:9A C1 E5 C1 E8 C1 F7 C1 FA C2 45 C2 48 C2 57 C2
|
|
.byte $5A, $C2, $A5, $C2, $A8, $C2, $AB, $C2, $AE, $C2, $B1, $C2, $B4, $C2, $B7, $C2 ; PRG:$2F80 Bytes:5A C2 A5 C2 A8 C2 AB C2 AE C2 B1 C2 B4 C2 B7 C2
|
|
.byte $BA, $FF, $02, $4C, $57, $EC, $3F, $00, $14, $0F, $30, $21, $01, $0F, $30, $30 ; PRG:$2F90 Bytes:BA FF 02 4C 57 EC 3F 00 14 0F 30 21 01 0F 30 30
|
|
.byte $0F, $0F, $25, $25, $0F, $0F, $21, $21, $0F, $0F, $30, $26, $27, $23, $E0, $48 ; PRG:$2FA0 Bytes:0F 0F 25 25 0F 0F 21 21 0F 0F 30 26 27 23 E0 48
|
|
.byte $50, $23, $E8, $48, $A5, $23, $F0, $48, $F5, $20, $86, $14, $DA, $DF, $E3, $E5 ; PRG:$2FB0 Bytes:50 23 E8 48 A5 23 F0 48 F5 20 86 14 DA DF E3 E5
|
|
.byte $24, $24, $E5, $24, $E5, $24, $24, $DA, $DF, $E3, $E5, $24, $24, $E5, $24, $E5 ; PRG:$2FC0 Bytes:24 24 E5 24 E5 24 24 DA DF E3 E5 24 24 E5 24 E5
|
|
.byte $20, $A6, $14, $DB, $E0, $E4, $DC, $24, $24, $DC, $24, $DC, $24, $24, $DB, $E0 ; PRG:$2FD0 Bytes:20 A6 14 DB E0 E4 DC 24 24 DC 24 DC 24 24 DB E0
|
|
.byte $E4, $DC, $24, $24, $DC, $24, $DC, $20, $C6, $14, $DC, $24, $24, $DC, $24, $24 ; PRG:$2FE0 Bytes:E4 DC 24 24 DC 24 DC 20 C6 14 DC 24 24 DC 24 24
|
|
.byte $DC, $24, $DC, $24, $24, $DC, $24, $24, $DC, $24, $24, $DC, $24, $DC, $20, $E6 ; PRG:$2FF0 Bytes:DC 24 DC 24 24 DC 24 24 DC 24 24 DC 24 DC 20 E6
|
|
.byte $14, $DD, $E1, $E5, $DD, $24, $24, $DD, $E1, $DC, $24, $24, $DD, $E1, $E5, $DD ; PRG:$3000 Bytes:14 DD E1 E5 DD 24 24 DD E1 DC 24 24 DD E1 E5 DD
|
|
.byte $24, $24, $DD, $E1, $DC, $21, $06, $14, $DE, $E2, $E6, $DE, $E2, $E7, $DE, $E2 ; PRG:$3010 Bytes:24 24 DD E1 DC 21 06 14 DE E2 E6 DE E2 E7 DE E2
|
|
.byte $E6, $24, $24, $DE, $E2, $E6, $DE, $E2, $E7, $DE, $E2, $E6, $20, $44, $57, $39 ; PRG:$3020 Bytes:E6 24 24 DE E2 E6 DE E2 E7 DE E2 E6 20 44 57 39
|
|
.byte $22, $05, $57, $39, $20, $83, $CB, $DC, $20, $7C, $CD, $DC, $20, $43, $82, $DA ; PRG:$3030 Bytes:22 05 57 39 20 83 CB DC 20 7C CD DC 20 43 82 DA
|
|
.byte $DB, $21, $E3, $01, $DD, $22, $03, $02, $DE, $E2, $20, $5B, $02, $DF, $E3, $20 ; PRG:$3040 Bytes:DB 21 E3 01 DD 22 03 02 DE E2 20 5B 02 DF E3 20
|
|
.byte $7B, $01, $E0, $21, $FB, $01, $E1, $22, $1C, $01, $E6, $21, $46, $85, $E5, $DC ; PRG:$3050 Bytes:7B 01 E0 21 FB 01 E1 22 1C 01 E6 21 46 85 E5 DC
|
|
.byte $DC, $DD, $DE, $21, $4B, $0F, $DA, $39, $39, $DF, $E3, $DA, $DF, $E3, $24, $E5 ; PRG:$3060 Bytes:DC DD DE 21 4B 0F DA 39 39 DF E3 DA DF E3 24 E5
|
|
.byte $EA, $39, $39, $DF, $E3, $21, $6B, $0F, $DB, $24, $24, $E0, $DC, $DB, $E0, $DC ; PRG:$3070 Bytes:EA 39 39 DF E3 21 6B 0F DB 24 24 E0 DC DB E0 DC
|
|
.byte $24, $DC, $24, $EB, $24, $E0, $DC, $21, $8B, $0F, $DC, $24, $24, $24, $DC, $DC ; PRG:$3080 Bytes:24 DC 24 EB 24 E0 DC 21 8B 0F DC 24 24 24 DC DC
|
|
.byte $24, $DC, $24, $DC, $24, $DC, $24, $24, $DC, $21, $AB, $0F, $E8, $E9, $39, $E7 ; PRG:$3090 Bytes:24 DC 24 DC 24 DC 24 24 DC 21 AB 0F E8 E9 39 E7
|
|
.byte $DC, $DC, $24, $DD, $E1, $DC, $24, $EC, $24, $E1, $DC, $21, $C7, $13, $E2, $39 ; PRG:$30A0 Bytes:DC DC 24 DD E1 DC 24 EC 24 E1 DC 21 C7 13 E2 39
|
|
.byte $39, $E7, $EC, $24, $24, $24, $EC, $EC, $24, $DE, $E2, $E6, $EA, $39, $39, $39 ; PRG:$30B0 Bytes:39 E7 EC 24 24 24 EC EC 24 DE E2 E6 EA 39 39 39
|
|
.byte $E6, $22, $4A, $0D, $01, $24, $19, $15, $0A, $22, $0E, $1B, $24, $10, $0A, $16 ; PRG:$30C0 Bytes:E6 22 4A 0D 01 24 19 15 0A 22 0E 1B 24 10 0A 16
|
|
.byte $0E, $22, $8A, $0D, $02, $24, $19, $15, $0A, $22, $0E, $1B, $24, $10, $0A, $16 ; PRG:$30D0 Bytes:0E 22 8A 0D 02 24 19 15 0A 22 0E 1B 24 10 0A 16
|
|
.byte $0E, $22, $CA, $04, $B5, $B6, $B7, $B8, $22, $D4, $04, $B2, $B3, $B4, $CC, $23 ; PRG:$30E0 Bytes:0E 22 CA 04 B5 B6 B7 B8 22 D4 04 B2 B3 B4 CC 23
|
|
.byte $04, $02, $AB, $B8, $23, $0C, $07, $B2, $B3, $B4, $CC, $24, $AC, $B8, $23, $19 ; PRG:$30F0 Bytes:04 02 AB B8 23 0C 07 B2 B3 B4 CC 24 AC B8 23 19
|
|
.byte $04, $B2, $B3, $B4, $CC, $23, $69, $0E, $25, $01, $09, $08, $04, $24, $17, $12 ; PRG:$3100 Bytes:04 B2 B3 B4 CC 23 69 0E 25 01 09 08 04 24 17 12
|
|
.byte $17, $1D, $0E, $17, $0D, $18, $00, $FF, $02, $4C, $7E, $F1, $00, $FF, $02, $4C ; PRG:$3110 Bytes:17 1D 0E 17 0D 18 00 FF 02 4C 7E F1 00 FF 02 4C
|
|
.byte $7E, $F1, $2B, $E1, $46, $FA, $2B, $E9, $46, $FF, $2B, $F1, $46, $AF, $2B, $F1 ; PRG:$3120 Bytes:7E F1 2B E1 46 FA 2B E9 46 FF 2B F1 46 AF 2B F1
|
|
.byte $01, $A5, $2A, $24, $58, $C7, $2B, $44, $58, $C8, $2A, $43, $C8, $C5, $2A, $5C ; PRG:$3130 Bytes:01 A5 2A 24 58 C7 2B 44 58 C8 2A 43 C8 C5 2A 5C
|
|
.byte $C8, $CA, $2A, $23, $01, $C4, $2A, $3C, $01, $C9, $2B, $43, $01, $C6, $2B, $5C ; PRG:$3140 Bytes:C8 CA 2A 23 01 C4 2A 3C 01 C9 2B 43 01 C6 2B 5C
|
|
.byte $01, $CB, $2A, $4A, $0C, $2E, $24, $19, $15, $0A, $22, $0E, $1B, $24, $02, $24 ; PRG:$3150 Bytes:01 CB 2A 4A 0C 2E 24 19 15 0A 22 0E 1B 24 02 24
|
|
.byte $2F, $2A, $8F, $4A, $C7, $2A, $CF, $4A, $C8, $2A, $8E, $83, $C4, $C5, $C6, $2A ; PRG:$3160 Bytes:2F 2A 8F 4A C7 2A CF 4A C8 2A 8E 83 C4 C5 C6 2A
|
|
.byte $B5, $04, $B2, $B3, $B4, $CC, $2A, $99, $83, $C9, $CA, $CB, $00, $FF, $2B, $C0 ; PRG:$3170 Bytes:B5 04 B2 B3 B4 CC 2A 99 83 C9 CA CB 00 FF 2B C0
|
|
.byte $60, $AA, $2B, $E0, $60, $AA, $2B, $C9, $46, $FF, $2B, $D1, $46, $FF, $2B, $D1 ; PRG:$3180 Bytes:60 AA 2B E0 60 AA 2B C9 46 FF 2B D1 46 FF 2B D1
|
|
.byte $01, $55, $28, $64, $58, $C7, $29, $84, $58, $C8, $28, $83, $C8, $C5, $28, $9C ; PRG:$3190 Bytes:01 55 28 64 58 C7 29 84 58 C8 28 83 C8 C5 28 9C
|
|
.byte $C8, $CA, $28, $63, $01, $C4, $28, $7C, $01, $C9, $29, $83, $01, $C6, $29, $9C ; PRG:$31A0 Bytes:C8 CA 28 63 01 C4 28 7C 01 C9 29 83 01 C6 29 9C
|
|
.byte $01, $CB, $28, $8A, $0C, $2E, $24, $19, $15, $0A, $22, $0E, $1B, $24, $01, $24 ; PRG:$31B0 Bytes:01 CB 28 8A 0C 2E 24 19 15 0A 22 0E 1B 24 01 24
|
|
.byte $2F, $28, $CF, $4A, $C7, $29, $0F, $4A, $C8, $28, $CE, $83, $C4, $C5, $C6, $28 ; PRG:$31C0 Bytes:2F 28 CF 4A C7 29 0F 4A C8 28 CE 83 C4 C5 C6 28
|
|
.byte $F5, $04, $B2, $B3, $B4, $CC, $28, $D9, $83, $C9, $CA, $CB, $29, $A2, $45, $2E ; PRG:$31D0 Bytes:F5 04 B2 B3 B4 CC 28 D9 83 C9 CA CB 29 A2 45 2E
|
|
.byte $29, $B9, $45, $2F, $29, $A8, $0E, $0C, $15, $1E, $B8, $0C, $15, $1E, $B8, $15 ; PRG:$31E0 Bytes:29 B9 45 2F 29 A8 0E 0C 15 1E B8 0C 15 1E B8 15
|
|
.byte $0A, $17, $0D, $B8, $B8, $29, $E4, $04, $2A, $2B, $2C, $2D, $29, $EE, $04, $B5 ; PRG:$31F0 Bytes:0A 17 0D B8 B8 29 E4 04 2A 2B 2C 2D 29 EE 04 B5
|
|
.byte $B6, $B7, $B8, $29, $F8, $04, $B2, $B3, $B4, $CC, $60 ; PRG:$3200 Bytes:B6 B7 B8 29 F8 04 B2 B3 B4 CC 60
|
|
;------------------------------------------------------------
|
|
; ResourceAndLevelData
|
|
;
|
|
; Global:
|
|
; First-pass ResourceAndLevelData entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ResourceAndLevelData:
|
|
LDA $40 ; PRG:$320B Bytes:A5 40
|
|
AND #$FB ; PRG:$320D Bytes:29 FB
|
|
STA PPUCTRL ; PRG:$320F Bytes:8D 00 20
|
|
STA $40 ; PRG:$3212 Bytes:85 40
|
|
LDX PPUSTATUS ; PRG:$3214 Bytes:AE 02 20
|
|
LDY #$00 ; PRG:$3217 Bytes:A0 00
|
|
BEQ PPUCommandReadNextByte_F249 ; PRG:$3219 Bytes:F0 2E
|
|
|
|
|
|
; Branch target inside the final five bytes of the preceding raw region.
|
|
; This is part of the PPU command-processing loop continued at $F220.
|
|
PPUCommandLoop_F21B:
|
|
PHA ; PRG:$321B Bytes:48
|
|
STA PPUADDR ; PRG:$321C Bytes:8D 06 20
|
|
INY ; PRG:$321F Bytes:C8
|
|
|
|
;------------------------------------------------------------
|
|
; Resource, input, and collision code with embedded tables
|
|
; CPU $F220-$F7C0
|
|
; PRG $3220-$37C0
|
|
;
|
|
; Pass 1 recursively traced from verified entry roots in this region.
|
|
; Direct branches, jumps, and subroutine calls are decoded.
|
|
; Bytes not reached by that trace remain explicit .byte data.
|
|
;------------------------------------------------------------
|
|
|
|
;------------------------------------------------------------
|
|
; ResourceInputCollisionCode
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ResourceInputCollisionCode:
|
|
LDA $0301,Y ; PRG:$3220 Bytes:B9 01 03
|
|
STA PPUADDR ; PRG:$3223 Bytes:8D 06 20
|
|
INY ; PRG:$3226 Bytes:C8
|
|
LDA $0301,Y ; PRG:$3227 Bytes:B9 01 03
|
|
AND #$3F ; PRG:$322A Bytes:29 3F
|
|
TAX ; PRG:$322C Bytes:AA
|
|
UpdateCommandBufferLoop_F22D:
|
|
INY ; PRG:$322D Bytes:C8
|
|
LDA $0301,Y ; PRG:$322E Bytes:B9 01 03
|
|
STA PPUDATA ; PRG:$3231 Bytes:8D 07 20
|
|
DEX ; PRG:$3234 Bytes:CA
|
|
BNE UpdateCommandBufferLoop_F22D ; PRG:$3235 Bytes:D0 F6
|
|
PLA ; PRG:$3237 Bytes:68
|
|
CMP #$3F ; PRG:$3238 Bytes:C9 3F
|
|
BNE UpdateCommandBufferOnNonZero_F248 ; PRG:$323A Bytes:D0 0C
|
|
STA PPUADDR ; PRG:$323C Bytes:8D 06 20
|
|
STX PPUADDR ; PRG:$323F Bytes:8E 06 20
|
|
STX PPUADDR ; PRG:$3242 Bytes:8E 06 20
|
|
STX PPUADDR ; PRG:$3245 Bytes:8E 06 20
|
|
UpdateCommandBufferOnNonZero_F248:
|
|
INY ; PRG:$3248 Bytes:C8
|
|
PPUCommandReadNextByte_F249:
|
|
LDA $0301,Y ; PRG:$3249 Bytes:B9 01 03
|
|
BNE PPUCommandLoop_F21B ; PRG:$324C Bytes:D0 CD
|
|
LDA #$00 ; PRG:$324E Bytes:A9 00
|
|
STA $0300 ; PRG:$3250 Bytes:8D 00 03
|
|
STA $0301 ; PRG:$3253 Bytes:8D 01 03
|
|
RTS ; PRG:$3256 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F257
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F257:
|
|
LDA PPUSTATUS ; PRG:$3257 Bytes:AD 02 20
|
|
LDA $40 ; PRG:$325A Bytes:A5 40
|
|
AND #$FB ; PRG:$325C Bytes:29 FB
|
|
STA PPUCTRL ; PRG:$325E Bytes:8D 00 20
|
|
STA $40 ; PRG:$3261 Bytes:85 40
|
|
LDA #$1C ; PRG:$3263 Bytes:A9 1C
|
|
CLC ; PRG:$3265 Bytes:18
|
|
EnginePathLoop_F266:
|
|
ADC #$04 ; PRG:$3266 Bytes:69 04
|
|
DEC $01 ; PRG:$3268 Bytes:C6 01
|
|
BNE EnginePathLoop_F266 ; PRG:$326A Bytes:D0 FA
|
|
STA $02 ; PRG:$326C Bytes:85 02
|
|
STA PPUADDR ; PRG:$326E Bytes:8D 06 20
|
|
LDA #$00 ; PRG:$3271 Bytes:A9 00
|
|
STA PPUADDR ; PRG:$3273 Bytes:8D 06 20
|
|
LDX #$04 ; PRG:$3276 Bytes:A2 04
|
|
LDY #$00 ; PRG:$3278 Bytes:A0 00
|
|
LDA WorkPtr0Lo ; PRG:$327A Bytes:A5 00
|
|
EnginePathLoop_F27C:
|
|
STA PPUDATA ; PRG:$327C Bytes:8D 07 20
|
|
DEY ; PRG:$327F Bytes:88
|
|
BNE EnginePathLoop_F27C ; PRG:$3280 Bytes:D0 FA
|
|
DEX ; PRG:$3282 Bytes:CA
|
|
BNE EnginePathLoop_F27C ; PRG:$3283 Bytes:D0 F7
|
|
LDA WorkPtr1Lo ; PRG:$3285 Bytes:A5 02
|
|
ADC #$03 ; PRG:$3287 Bytes:69 03
|
|
STA PPUADDR ; PRG:$3289 Bytes:8D 06 20
|
|
LDA #$C0 ; PRG:$328C Bytes:A9 C0
|
|
STA PPUADDR ; PRG:$328E Bytes:8D 06 20
|
|
LDY #$40 ; PRG:$3291 Bytes:A0 40
|
|
LDA #$00 ; PRG:$3293 Bytes:A9 00
|
|
EnginePathLoop_F295:
|
|
STA PPUDATA ; PRG:$3295 Bytes:8D 07 20
|
|
DEY ; PRG:$3298 Bytes:88
|
|
BNE EnginePathLoop_F295 ; PRG:$3299 Bytes:D0 FA
|
|
RTS ; PRG:$329B Bytes:60
|
|
EnginePathLoop_F29C:
|
|
PHA ; PRG:$329C Bytes:48
|
|
STA PPUADDR ; PRG:$329D Bytes:8D 06 20
|
|
INY ; PRG:$32A0 Bytes:C8
|
|
LDA ($00),Y ; PRG:$32A1 Bytes:B1 00
|
|
STA PPUADDR ; PRG:$32A3 Bytes:8D 06 20
|
|
INY ; PRG:$32A6 Bytes:C8
|
|
LDA ($00),Y ; PRG:$32A7 Bytes:B1 00
|
|
ASL A ; PRG:$32A9 Bytes:0A
|
|
PHA ; PRG:$32AA Bytes:48
|
|
LDA $40 ; PRG:$32AB Bytes:A5 40
|
|
ORA #$04 ; PRG:$32AD Bytes:09 04
|
|
BCS EnginePathOnCarry_F2B3 ; PRG:$32AF Bytes:B0 02
|
|
AND #$FB ; PRG:$32B1 Bytes:29 FB
|
|
EnginePathOnCarry_F2B3:
|
|
STA PPUCTRL ; PRG:$32B3 Bytes:8D 00 20
|
|
STA $40 ; PRG:$32B6 Bytes:85 40
|
|
PLA ; PRG:$32B8 Bytes:68
|
|
ASL A ; PRG:$32B9 Bytes:0A
|
|
BCC EnginePathOnNoCarry_F2BF ; PRG:$32BA Bytes:90 03
|
|
ORA #$02 ; PRG:$32BC Bytes:09 02
|
|
INY ; PRG:$32BE Bytes:C8
|
|
EnginePathOnNoCarry_F2BF:
|
|
LSR A ; PRG:$32BF Bytes:4A
|
|
LSR A ; PRG:$32C0 Bytes:4A
|
|
TAX ; PRG:$32C1 Bytes:AA
|
|
EnginePathLoop_F2C2:
|
|
BCS EnginePathOnCarry_F2C5 ; PRG:$32C2 Bytes:B0 01
|
|
INY ; PRG:$32C4 Bytes:C8
|
|
EnginePathOnCarry_F2C5:
|
|
LDA ($00),Y ; PRG:$32C5 Bytes:B1 00
|
|
STA PPUDATA ; PRG:$32C7 Bytes:8D 07 20
|
|
DEX ; PRG:$32CA Bytes:CA
|
|
BNE EnginePathLoop_F2C2 ; PRG:$32CB Bytes:D0 F5
|
|
PLA ; PRG:$32CD Bytes:68
|
|
CMP #$3F ; PRG:$32CE Bytes:C9 3F
|
|
BNE EnginePathLoop_F2DE ; PRG:$32D0 Bytes:D0 0C
|
|
STA PPUADDR ; PRG:$32D2 Bytes:8D 06 20
|
|
STX PPUADDR ; PRG:$32D5 Bytes:8E 06 20
|
|
STX PPUADDR ; PRG:$32D8 Bytes:8E 06 20
|
|
STX PPUADDR ; PRG:$32DB Bytes:8E 06 20
|
|
EnginePathLoop_F2DE:
|
|
SEC ; PRG:$32DE Bytes:38
|
|
TYA ; PRG:$32DF Bytes:98
|
|
ADC $00 ; PRG:$32E0 Bytes:65 00
|
|
STA $00 ; PRG:$32E2 Bytes:85 00
|
|
LDA #$00 ; PRG:$32E4 Bytes:A9 00
|
|
ADC $01 ; PRG:$32E6 Bytes:65 01
|
|
STA $01 ; PRG:$32E8 Bytes:85 01
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateDispatch_F2EA
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateDispatch_F2EA:
|
|
LDX PPUSTATUS ; PRG:$32EA Bytes:AE 02 20
|
|
LDY #$00 ; PRG:$32ED Bytes:A0 00
|
|
LDA ($00),Y ; PRG:$32EF Bytes:B1 00
|
|
BNE EnginePathOnNonZero_F2F4 ; PRG:$32F1 Bytes:D0 01
|
|
RTS ; PRG:$32F3 Bytes:60
|
|
EnginePathOnNonZero_F2F4:
|
|
CMP #$60 ; PRG:$32F4 Bytes:C9 60
|
|
BNE EnginePathOnNonZero_F302 ; PRG:$32F6 Bytes:D0 0A
|
|
PLA ; PRG:$32F8 Bytes:68
|
|
STA $01 ; PRG:$32F9 Bytes:85 01
|
|
PLA ; PRG:$32FB Bytes:68
|
|
STA $00 ; PRG:$32FC Bytes:85 00
|
|
LDY #$02 ; PRG:$32FE Bytes:A0 02
|
|
BNE EnginePathLoop_F2DE ; PRG:$3300 Bytes:D0 DC
|
|
EnginePathOnNonZero_F302:
|
|
CMP #$4C ; PRG:$3302 Bytes:C9 4C
|
|
BNE EnginePathLoop_F29C ; PRG:$3304 Bytes:D0 96
|
|
LDA WorkPtr0Lo ; PRG:$3306 Bytes:A5 00
|
|
PHA ; PRG:$3308 Bytes:48
|
|
LDA WorkPtr0Hi ; PRG:$3309 Bytes:A5 01
|
|
PHA ; PRG:$330B Bytes:48
|
|
INY ; PRG:$330C Bytes:C8
|
|
LDA ($00),Y ; PRG:$330D Bytes:B1 00
|
|
TAX ; PRG:$330F Bytes:AA
|
|
INY ; PRG:$3310 Bytes:C8
|
|
LDA ($00),Y ; PRG:$3311 Bytes:B1 00
|
|
STA $01 ; PRG:$3313 Bytes:85 01
|
|
STX $00 ; PRG:$3315 Bytes:86 00
|
|
JMP ProcessResourceStateDispatch_F2EA ; PRG:$3317 Bytes:4C EA F2
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F31A
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F31A:
|
|
STA $00 ; PRG:$331A Bytes:85 00
|
|
LDX $00 ; PRG:$331C Bytes:A6 00
|
|
JSR UpdateCommandBufferRoutine_F32C ; PRG:$331E Bytes:20 2C F3
|
|
LDA WorkPtr0Lo ; PRG:$3321 Bytes:A5 00
|
|
LSR A ; PRG:$3323 Bytes:4A
|
|
LSR A ; PRG:$3324 Bytes:4A
|
|
LSR A ; PRG:$3325 Bytes:4A
|
|
LSR A ; PRG:$3326 Bytes:4A
|
|
TAX ; PRG:$3327 Bytes:AA
|
|
JSR UpdateCommandBufferRoutine_F32C ; PRG:$3328 Bytes:20 2C F3
|
|
RTS ; PRG:$332B Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateCommandBufferRoutine_F32C
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateCommandBufferRoutine_F32C:
|
|
INX ; PRG:$332C Bytes:E8
|
|
TXA ; PRG:$332D Bytes:8A
|
|
AND #$0F ; PRG:$332E Bytes:29 0F
|
|
CMP #$09 ; PRG:$3330 Bytes:C9 09
|
|
BCS EnginePathContinue_F3A0 ; PRG:$3332 Bytes:B0 6C
|
|
ASL A ; PRG:$3334 Bytes:0A
|
|
ASL A ; PRG:$3335 Bytes:0A
|
|
TAY ; PRG:$3336 Bytes:A8
|
|
STA $02 ; PRG:$3337 Bytes:85 02
|
|
LDX $0300 ; PRG:$3339 Bytes:AE 00 03
|
|
LDA $0700,Y ; PRG:$333C Bytes:B9 00 07
|
|
STA $0301,X ; PRG:$333F Bytes:9D 01 03
|
|
JSR ProcessResourceStateRoutine_F3F5 ; PRG:$3342 Bytes:20 F5 F3
|
|
INY ; PRG:$3345 Bytes:C8
|
|
LDA $0700,Y ; PRG:$3346 Bytes:B9 00 07
|
|
STA $0301,X ; PRG:$3349 Bytes:9D 01 03
|
|
JSR ProcessResourceStateRoutine_F3F5 ; PRG:$334C Bytes:20 F5 F3
|
|
INY ; PRG:$334F Bytes:C8
|
|
LDA $0700,Y ; PRG:$3350 Bytes:B9 00 07
|
|
AND #$07 ; PRG:$3353 Bytes:29 07
|
|
STA $0301,X ; PRG:$3355 Bytes:9D 01 03
|
|
STA $01 ; PRG:$3358 Bytes:85 01
|
|
TXA ; PRG:$335A Bytes:8A
|
|
SEC ; PRG:$335B Bytes:38
|
|
ADC $01 ; PRG:$335C Bytes:65 01
|
|
JSR UpdateCommandBufferRoutine_F3F7 ; PRG:$335E Bytes:20 F7 F3
|
|
TAX ; PRG:$3361 Bytes:AA
|
|
STX $0300 ; PRG:$3362 Bytes:8E 00 03
|
|
LDA #$00 ; PRG:$3365 Bytes:A9 00
|
|
STA $0301,X ; PRG:$3367 Bytes:9D 01 03
|
|
INY ; PRG:$336A Bytes:C8
|
|
LDA $0700,Y ; PRG:$336B Bytes:B9 00 07
|
|
STA $03 ; PRG:$336E Bytes:85 03
|
|
UpdateCommandBufferLoop_F370:
|
|
DEX ; PRG:$3370 Bytes:CA
|
|
LDA a:$0020,Y ; PRG:$3371 Bytes:B9 20 00
|
|
AND #$0F ; PRG:$3374 Bytes:29 0F
|
|
STA $0301,X ; PRG:$3376 Bytes:9D 01 03
|
|
DEC $01 ; PRG:$3379 Bytes:C6 01
|
|
BEQ UpdateCommandBufferOnZero_F38F ; PRG:$337B Bytes:F0 12
|
|
DEX ; PRG:$337D Bytes:CA
|
|
LDA a:$0020,Y ; PRG:$337E Bytes:B9 20 00
|
|
AND #$F0 ; PRG:$3381 Bytes:29 F0
|
|
LSR A ; PRG:$3383 Bytes:4A
|
|
LSR A ; PRG:$3384 Bytes:4A
|
|
LSR A ; PRG:$3385 Bytes:4A
|
|
LSR A ; PRG:$3386 Bytes:4A
|
|
STA $0301,X ; PRG:$3387 Bytes:9D 01 03
|
|
DEY ; PRG:$338A Bytes:88
|
|
DEC $01 ; PRG:$338B Bytes:C6 01
|
|
BNE UpdateCommandBufferLoop_F370 ; PRG:$338D Bytes:D0 E1
|
|
UpdateCommandBufferOnZero_F38F:
|
|
LDA $03 ; PRG:$338F Bytes:A5 03
|
|
AND #$01 ; PRG:$3391 Bytes:29 01
|
|
BEQ EnginePathContinue_F3A0 ; PRG:$3393 Bytes:F0 0B
|
|
LDY $02 ; PRG:$3395 Bytes:A4 02
|
|
CLC ; PRG:$3397 Bytes:18
|
|
LDA a:$0020,Y ; PRG:$3398 Bytes:B9 20 00
|
|
ADC #$B1 ; PRG:$339B Bytes:69 B1
|
|
STA $0301,X ; PRG:$339D Bytes:9D 01 03
|
|
EnginePathContinue_F3A0:
|
|
RTS ; PRG:$33A0 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdateCommandBufferRoutine_F3A1
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateCommandBufferRoutine_F3A1:
|
|
LDY #$00 ; PRG:$33A1 Bytes:A0 00
|
|
LDA ($02),Y ; PRG:$33A3 Bytes:B1 02
|
|
AND #$0F ; PRG:$33A5 Bytes:29 0F
|
|
STA $05 ; PRG:$33A7 Bytes:85 05
|
|
LDA ($02),Y ; PRG:$33A9 Bytes:B1 02
|
|
LSR A ; PRG:$33AB Bytes:4A
|
|
LSR A ; PRG:$33AC Bytes:4A
|
|
LSR A ; PRG:$33AD Bytes:4A
|
|
LSR A ; PRG:$33AE Bytes:4A
|
|
STA $04 ; PRG:$33AF Bytes:85 04
|
|
LDX $0300 ; PRG:$33B1 Bytes:AE 00 03
|
|
UpdateCommandBufferLoop_F3B4:
|
|
LDA WorkPtr0Hi ; PRG:$33B4 Bytes:A5 01
|
|
STA $0301,X ; PRG:$33B6 Bytes:9D 01 03
|
|
JSR ProcessResourceStateRoutine_F3F5 ; PRG:$33B9 Bytes:20 F5 F3
|
|
LDA WorkPtr0Lo ; PRG:$33BC Bytes:A5 00
|
|
STA $0301,X ; PRG:$33BE Bytes:9D 01 03
|
|
JSR ProcessResourceStateRoutine_F3F5 ; PRG:$33C1 Bytes:20 F5 F3
|
|
LDA $05 ; PRG:$33C4 Bytes:A5 05
|
|
STA $06 ; PRG:$33C6 Bytes:85 06
|
|
STA $0301,X ; PRG:$33C8 Bytes:9D 01 03
|
|
UpdateCommandBufferLoop_F3CB:
|
|
JSR ProcessResourceStateRoutine_F3F5 ; PRG:$33CB Bytes:20 F5 F3
|
|
INY ; PRG:$33CE Bytes:C8
|
|
LDA ($02),Y ; PRG:$33CF Bytes:B1 02
|
|
STA $0301,X ; PRG:$33D1 Bytes:9D 01 03
|
|
DEC $06 ; PRG:$33D4 Bytes:C6 06
|
|
BNE UpdateCommandBufferLoop_F3CB ; PRG:$33D6 Bytes:D0 F3
|
|
JSR ProcessResourceStateRoutine_F3F5 ; PRG:$33D8 Bytes:20 F5 F3
|
|
STX $0300 ; PRG:$33DB Bytes:8E 00 03
|
|
CLC ; PRG:$33DE Bytes:18
|
|
LDA #$20 ; PRG:$33DF Bytes:A9 20
|
|
ADC $00 ; PRG:$33E1 Bytes:65 00
|
|
STA $00 ; PRG:$33E3 Bytes:85 00
|
|
LDA #$00 ; PRG:$33E5 Bytes:A9 00
|
|
ADC $01 ; PRG:$33E7 Bytes:65 01
|
|
STA $01 ; PRG:$33E9 Bytes:85 01
|
|
DEC $04 ; PRG:$33EB Bytes:C6 04
|
|
BNE UpdateCommandBufferLoop_F3B4 ; PRG:$33ED Bytes:D0 C5
|
|
LDA #$00 ; PRG:$33EF Bytes:A9 00
|
|
STA $0301,X ; PRG:$33F1 Bytes:9D 01 03
|
|
RTS ; PRG:$33F4 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F3F5
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F3F5:
|
|
INX ; PRG:$33F5 Bytes:E8
|
|
TXA ; PRG:$33F6 Bytes:8A
|
|
;------------------------------------------------------------
|
|
; UpdateCommandBufferRoutine_F3F7
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdateCommandBufferRoutine_F3F7:
|
|
CMP #$4E ; PRG:$33F7 Bytes:C9 4E
|
|
BCC EnginePathOnNoCarry_F407 ; PRG:$33F9 Bytes:90 0C
|
|
LDX $0300 ; PRG:$33FB Bytes:AE 00 03
|
|
LDA #$00 ; PRG:$33FE Bytes:A9 00
|
|
STA $0301,X ; PRG:$3400 Bytes:9D 01 03
|
|
PLA ; PRG:$3403 Bytes:68
|
|
PLA ; PRG:$3404 Bytes:68
|
|
LDA #$01 ; PRG:$3405 Bytes:A9 01
|
|
EnginePathOnNoCarry_F407:
|
|
RTS ; PRG:$3407 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F408
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F408:
|
|
LDX #$FF ; PRG:$3408 Bytes:A2 FF
|
|
BNE EnginePathOnNonZero_F40E ; PRG:$340A Bytes:D0 02
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F40C
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F40C:
|
|
LDX #$00 ; PRG:$340C Bytes:A2 00
|
|
EnginePathOnNonZero_F40E:
|
|
STX $04 ; PRG:$340E Bytes:86 04
|
|
LDX #$00 ; PRG:$3410 Bytes:A2 00
|
|
STX $05 ; PRG:$3412 Bytes:86 05
|
|
STX $06 ; PRG:$3414 Bytes:86 06
|
|
STX $07 ; PRG:$3416 Bytes:86 07
|
|
LDA WorkPtr0Hi ; PRG:$3418 Bytes:A5 01
|
|
AND #$08 ; PRG:$341A Bytes:29 08
|
|
BNE EnginePathOnNonZero_F41F ; PRG:$341C Bytes:D0 01
|
|
INX ; PRG:$341E Bytes:E8
|
|
EnginePathOnNonZero_F41F:
|
|
LDA WorkPtr0Lo ; PRG:$341F Bytes:A5 00
|
|
STA $06,X ; PRG:$3421 Bytes:95 06
|
|
LDA WorkPtr0Hi ; PRG:$3423 Bytes:A5 01
|
|
JSR ProcessResourceStateRoutine_F429 ; PRG:$3425 Bytes:20 29 F4
|
|
RTS ; PRG:$3428 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F429
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F429:
|
|
AND #$07 ; PRG:$3429 Bytes:29 07
|
|
ASL A ; PRG:$342B Bytes:0A
|
|
ASL A ; PRG:$342C Bytes:0A
|
|
TAX ; PRG:$342D Bytes:AA
|
|
LDA $04 ; PRG:$342E Bytes:A5 04
|
|
BEQ EnginePathOnZero_F459 ; PRG:$3430 Bytes:F0 27
|
|
LDA $24,X ; PRG:$3432 Bytes:B5 24
|
|
BEQ EnginePathOnZero_F45D ; PRG:$3434 Bytes:F0 27
|
|
EnginePathLoop_F436:
|
|
CLC ; PRG:$3436 Bytes:18
|
|
LDA $27,X ; PRG:$3437 Bytes:B5 27
|
|
STA $03 ; PRG:$3439 Bytes:85 03
|
|
LDA $07 ; PRG:$343B Bytes:A5 07
|
|
JSR ProcessResourceStateRoutine_F4AE ; PRG:$343D Bytes:20 AE F4
|
|
STA $27,X ; PRG:$3440 Bytes:95 27
|
|
LDA $26,X ; PRG:$3442 Bytes:B5 26
|
|
STA $03 ; PRG:$3444 Bytes:85 03
|
|
LDA $06 ; PRG:$3446 Bytes:A5 06
|
|
JSR ProcessResourceStateRoutine_F4AE ; PRG:$3448 Bytes:20 AE F4
|
|
STA $26,X ; PRG:$344B Bytes:95 26
|
|
LDA $25,X ; PRG:$344D Bytes:B5 25
|
|
STA $03 ; PRG:$344F Bytes:85 03
|
|
LDA $05 ; PRG:$3451 Bytes:A5 05
|
|
JSR ProcessResourceStateRoutine_F4AE ; PRG:$3453 Bytes:20 AE F4
|
|
STA $25,X ; PRG:$3456 Bytes:95 25
|
|
RTS ; PRG:$3458 Bytes:60
|
|
EnginePathOnZero_F459:
|
|
LDA $24,X ; PRG:$3459 Bytes:B5 24
|
|
BEQ EnginePathLoop_F436 ; PRG:$345B Bytes:F0 D9
|
|
EnginePathOnZero_F45D:
|
|
SEC ; PRG:$345D Bytes:38
|
|
LDA $27,X ; PRG:$345E Bytes:B5 27
|
|
STA $03 ; PRG:$3460 Bytes:85 03
|
|
LDA $07 ; PRG:$3462 Bytes:A5 07
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$3464 Bytes:20 CF F4
|
|
STA $27,X ; PRG:$3467 Bytes:95 27
|
|
LDA $26,X ; PRG:$3469 Bytes:B5 26
|
|
STA $03 ; PRG:$346B Bytes:85 03
|
|
LDA $06 ; PRG:$346D Bytes:A5 06
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$346F Bytes:20 CF F4
|
|
STA $26,X ; PRG:$3472 Bytes:95 26
|
|
LDA $25,X ; PRG:$3474 Bytes:B5 25
|
|
STA $03 ; PRG:$3476 Bytes:85 03
|
|
LDA $05 ; PRG:$3478 Bytes:A5 05
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$347A Bytes:20 CF F4
|
|
STA $25,X ; PRG:$347D Bytes:95 25
|
|
LDA $25,X ; PRG:$347F Bytes:B5 25
|
|
BNE EnginePathOnNonZero_F48B ; PRG:$3481 Bytes:D0 08
|
|
LDA $26,X ; PRG:$3483 Bytes:B5 26
|
|
BNE EnginePathOnNonZero_F48B ; PRG:$3485 Bytes:D0 04
|
|
LDA $27,X ; PRG:$3487 Bytes:B5 27
|
|
BEQ EnginePathOnZero_F491 ; PRG:$3489 Bytes:F0 06
|
|
EnginePathOnNonZero_F48B:
|
|
BCS EnginePathOnCarry_F4AD ; PRG:$348B Bytes:B0 20
|
|
LDA $24,X ; PRG:$348D Bytes:B5 24
|
|
EOR #$FF ; PRG:$348F Bytes:49 FF
|
|
EnginePathOnZero_F491:
|
|
STA $24,X ; PRG:$3491 Bytes:95 24
|
|
SEC ; PRG:$3493 Bytes:38
|
|
LDA #$00 ; PRG:$3494 Bytes:A9 00
|
|
STA $03 ; PRG:$3496 Bytes:85 03
|
|
LDA $27,X ; PRG:$3498 Bytes:B5 27
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$349A Bytes:20 CF F4
|
|
STA $27,X ; PRG:$349D Bytes:95 27
|
|
LDA $26,X ; PRG:$349F Bytes:B5 26
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$34A1 Bytes:20 CF F4
|
|
STA $26,X ; PRG:$34A4 Bytes:95 26
|
|
LDA $25,X ; PRG:$34A6 Bytes:B5 25
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$34A8 Bytes:20 CF F4
|
|
STA $25,X ; PRG:$34AB Bytes:95 25
|
|
EnginePathOnCarry_F4AD:
|
|
RTS ; PRG:$34AD Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F4AE
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F4AE:
|
|
JSR ProcessResourceStateRoutine_F4F1 ; PRG:$34AE Bytes:20 F1 F4
|
|
ADC $01 ; PRG:$34B1 Bytes:65 01
|
|
CMP #$0A ; PRG:$34B3 Bytes:C9 0A
|
|
BCC EnginePathOnNoCarry_F4B9 ; PRG:$34B5 Bytes:90 02
|
|
ADC #$05 ; PRG:$34B7 Bytes:69 05
|
|
EnginePathOnNoCarry_F4B9:
|
|
CLC ; PRG:$34B9 Bytes:18
|
|
ADC $02 ; PRG:$34BA Bytes:65 02
|
|
STA $02 ; PRG:$34BC Bytes:85 02
|
|
LDA $03 ; PRG:$34BE Bytes:A5 03
|
|
AND #$F0 ; PRG:$34C0 Bytes:29 F0
|
|
ADC $02 ; PRG:$34C2 Bytes:65 02
|
|
BCC EnginePathOnNoCarry_F4CA ; PRG:$34C4 Bytes:90 04
|
|
EnginePathLoop_F4C6:
|
|
ADC #$5F ; PRG:$34C6 Bytes:69 5F
|
|
SEC ; PRG:$34C8 Bytes:38
|
|
RTS ; PRG:$34C9 Bytes:60
|
|
EnginePathOnNoCarry_F4CA:
|
|
CMP #$A0 ; PRG:$34CA Bytes:C9 A0
|
|
BCS EnginePathLoop_F4C6 ; PRG:$34CC Bytes:B0 F8
|
|
RTS ; PRG:$34CE Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F4CF
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F4CF:
|
|
JSR ProcessResourceStateRoutine_F4F1 ; PRG:$34CF Bytes:20 F1 F4
|
|
SBC $01 ; PRG:$34D2 Bytes:E5 01
|
|
STA $01 ; PRG:$34D4 Bytes:85 01
|
|
BCS EnginePathOnCarry_F4E2 ; PRG:$34D6 Bytes:B0 0A
|
|
ADC #$0A ; PRG:$34D8 Bytes:69 0A
|
|
STA $01 ; PRG:$34DA Bytes:85 01
|
|
LDA WorkPtr1Lo ; PRG:$34DC Bytes:A5 02
|
|
ADC #$0F ; PRG:$34DE Bytes:69 0F
|
|
STA $02 ; PRG:$34E0 Bytes:85 02
|
|
EnginePathOnCarry_F4E2:
|
|
LDA $03 ; PRG:$34E2 Bytes:A5 03
|
|
AND #$F0 ; PRG:$34E4 Bytes:29 F0
|
|
SEC ; PRG:$34E6 Bytes:38
|
|
SBC $02 ; PRG:$34E7 Bytes:E5 02
|
|
BCS EnginePathOnCarry_F4EE ; PRG:$34E9 Bytes:B0 03
|
|
ADC #$A0 ; PRG:$34EB Bytes:69 A0
|
|
CLC ; PRG:$34ED Bytes:18
|
|
EnginePathOnCarry_F4EE:
|
|
ORA $01 ; PRG:$34EE Bytes:05 01
|
|
RTS ; PRG:$34F0 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F4F1
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F4F1:
|
|
PHA ; PRG:$34F1 Bytes:48
|
|
AND #$0F ; PRG:$34F2 Bytes:29 0F
|
|
STA $01 ; PRG:$34F4 Bytes:85 01
|
|
PLA ; PRG:$34F6 Bytes:68
|
|
AND #$F0 ; PRG:$34F7 Bytes:29 F0
|
|
STA $02 ; PRG:$34F9 Bytes:85 02
|
|
LDA $03 ; PRG:$34FB Bytes:A5 03
|
|
AND #$0F ; PRG:$34FD Bytes:29 0F
|
|
RTS ; PRG:$34FF Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F500
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F500:
|
|
LDA #$00 ; PRG:$3500 Bytes:A9 00
|
|
STA $04 ; PRG:$3502 Bytes:85 04
|
|
CLC ; PRG:$3504 Bytes:18
|
|
LDA WorkPtr0Lo ; PRG:$3505 Bytes:A5 00
|
|
ADC #$10 ; PRG:$3507 Bytes:69 10
|
|
AND #$F0 ; PRG:$3509 Bytes:29 F0
|
|
LSR A ; PRG:$350B Bytes:4A
|
|
LSR A ; PRG:$350C Bytes:4A
|
|
TAY ; PRG:$350D Bytes:A8
|
|
LDA WorkPtr0Lo ; PRG:$350E Bytes:A5 00
|
|
AND #$07 ; PRG:$3510 Bytes:29 07
|
|
ASL A ; PRG:$3512 Bytes:0A
|
|
ASL A ; PRG:$3513 Bytes:0A
|
|
TAX ; PRG:$3514 Bytes:AA
|
|
EnginePathLoop_F515:
|
|
LDA a:$0020,Y ; PRG:$3515 Bytes:B9 20 00
|
|
BEQ EnginePathOnZero_F56B ; PRG:$3518 Bytes:F0 51
|
|
LDA $24,X ; PRG:$351A Bytes:B5 24
|
|
BEQ EnginePathLoop_F544 ; PRG:$351C Bytes:F0 26
|
|
EnginePathLoop_F51E:
|
|
SEC ; PRG:$351E Bytes:38
|
|
LDA a:$0023,Y ; PRG:$351F Bytes:B9 23 00
|
|
STA $03 ; PRG:$3522 Bytes:85 03
|
|
LDA $27,X ; PRG:$3524 Bytes:B5 27
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$3526 Bytes:20 CF F4
|
|
LDA a:$0022,Y ; PRG:$3529 Bytes:B9 22 00
|
|
STA $03 ; PRG:$352C Bytes:85 03
|
|
LDA $26,X ; PRG:$352E Bytes:B5 26
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$3530 Bytes:20 CF F4
|
|
LDA a:$0021,Y ; PRG:$3533 Bytes:B9 21 00
|
|
STA $03 ; PRG:$3536 Bytes:85 03
|
|
LDA $25,X ; PRG:$3538 Bytes:B5 25
|
|
JSR ProcessResourceStateRoutine_F4CF ; PRG:$353A Bytes:20 CF F4
|
|
BCS EnginePathOnCarry_F56F ; PRG:$353D Bytes:B0 30
|
|
LDA a:$0020,Y ; PRG:$353F Bytes:B9 20 00
|
|
BNE EnginePathOnNonZero_F574 ; PRG:$3542 Bytes:D0 30
|
|
EnginePathLoop_F544:
|
|
LDA #$FF ; PRG:$3544 Bytes:A9 FF
|
|
STA $04 ; PRG:$3546 Bytes:85 04
|
|
SEC ; PRG:$3548 Bytes:38
|
|
EnginePathLoop_F549:
|
|
TYA ; PRG:$3549 Bytes:98
|
|
BNE EnginePathContinue_F56A ; PRG:$354A Bytes:D0 1E
|
|
BCC EnginePathOnNoCarry_F55E ; PRG:$354C Bytes:90 10
|
|
LDA $24,X ; PRG:$354E Bytes:B5 24
|
|
STA $20 ; PRG:$3550 Bytes:85 20
|
|
LDA $25,X ; PRG:$3552 Bytes:B5 25
|
|
STA $21 ; PRG:$3554 Bytes:85 21
|
|
LDA $26,X ; PRG:$3556 Bytes:B5 26
|
|
STA $22 ; PRG:$3558 Bytes:85 22
|
|
LDA $27,X ; PRG:$355A Bytes:B5 27
|
|
STA $23 ; PRG:$355C Bytes:85 23
|
|
EnginePathOnNoCarry_F55E:
|
|
LDA WorkPtr0Lo ; PRG:$355E Bytes:A5 00
|
|
AND #$08 ; PRG:$3560 Bytes:29 08
|
|
BEQ EnginePathContinue_F56A ; PRG:$3562 Bytes:F0 06
|
|
DEX ; PRG:$3564 Bytes:CA
|
|
DEX ; PRG:$3565 Bytes:CA
|
|
DEX ; PRG:$3566 Bytes:CA
|
|
DEX ; PRG:$3567 Bytes:CA
|
|
BPL EnginePathLoop_F515 ; PRG:$3568 Bytes:10 AB
|
|
EnginePathContinue_F56A:
|
|
RTS ; PRG:$356A Bytes:60
|
|
EnginePathOnZero_F56B:
|
|
LDA $24,X ; PRG:$356B Bytes:B5 24
|
|
BEQ EnginePathLoop_F51E ; PRG:$356D Bytes:F0 AF
|
|
EnginePathOnCarry_F56F:
|
|
LDA a:$0020,Y ; PRG:$356F Bytes:B9 20 00
|
|
BNE EnginePathLoop_F544 ; PRG:$3572 Bytes:D0 D0
|
|
EnginePathOnNonZero_F574:
|
|
CLC ; PRG:$3574 Bytes:18
|
|
BCC EnginePathLoop_F549 ; PRG:$3575 Bytes:90 D2
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F577
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F577:
|
|
LDX #$1E ; PRG:$3577 Bytes:A2 1E
|
|
DEC $50 ; PRG:$3579 Bytes:C6 50
|
|
BPL EnginePathLoop_F583 ; PRG:$357B Bytes:10 06
|
|
LDA #$0A ; PRG:$357D Bytes:A9 0A
|
|
STA $50 ; PRG:$357F Bytes:85 50
|
|
LDX #$2E ; PRG:$3581 Bytes:A2 2E
|
|
EnginePathLoop_F583:
|
|
LDA $51,X ; PRG:$3583 Bytes:B5 51
|
|
BEQ EnginePathOnZero_F589 ; PRG:$3585 Bytes:F0 02
|
|
DEC $51,X ; PRG:$3587 Bytes:D6 51
|
|
EnginePathOnZero_F589:
|
|
DEX ; PRG:$3589 Bytes:CA
|
|
BPL EnginePathLoop_F583 ; PRG:$358A Bytes:10 F7
|
|
RTS ; PRG:$358C Bytes:60
|
|
;------------------------------------------------------------
|
|
; EnginePath_F58D
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
EnginePath_F58D:
|
|
LDA $10 ; PRG:$358D Bytes:A5 10
|
|
AND #$02 ; PRG:$358F Bytes:29 02
|
|
STA $00 ; PRG:$3591 Bytes:85 00
|
|
LDA $11 ; PRG:$3593 Bytes:A5 11
|
|
AND #$02 ; PRG:$3595 Bytes:29 02
|
|
EOR $00 ; PRG:$3597 Bytes:45 00
|
|
CLC ; PRG:$3599 Bytes:18
|
|
BEQ EnginePathOnZero_F59D ; PRG:$359A Bytes:F0 01
|
|
SEC ; PRG:$359C Bytes:38
|
|
EnginePathOnZero_F59D:
|
|
ROR $10 ; PRG:$359D Bytes:66 10
|
|
ROR $11 ; PRG:$359F Bytes:66 11
|
|
ROR $12 ; PRG:$35A1 Bytes:66 12
|
|
ROR $13 ; PRG:$35A3 Bytes:66 13
|
|
ROR $14 ; PRG:$35A5 Bytes:66 14
|
|
ROR $15 ; PRG:$35A7 Bytes:66 15
|
|
ROR $16 ; PRG:$35A9 Bytes:66 16
|
|
ROR $17 ; PRG:$35AB Bytes:66 17
|
|
RTS ; PRG:$35AD Bytes:60
|
|
;------------------------------------------------------------
|
|
; EnginePath_F5AE
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
EnginePath_F5AE:
|
|
LDA #$01 ; PRG:$35AE Bytes:A9 01
|
|
STA JOY1 ; PRG:$35B0 Bytes:8D 16 40
|
|
LDX #$00 ; PRG:$35B3 Bytes:A2 00
|
|
LDA #$00 ; PRG:$35B5 Bytes:A9 00
|
|
STA JOY1 ; PRG:$35B7 Bytes:8D 16 40
|
|
JSR ProcessResourceStateRoutine_F5BE ; PRG:$35BA Bytes:20 BE F5
|
|
INX ; PRG:$35BD Bytes:E8
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F5BE
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F5BE:
|
|
LDY #$08 ; PRG:$35BE Bytes:A0 08
|
|
EnginePathLoop_F5C0:
|
|
PHA ; PRG:$35C0 Bytes:48
|
|
LDA JOY1,X ; PRG:$35C1 Bytes:BD 16 40
|
|
STA $00 ; PRG:$35C4 Bytes:85 00
|
|
LSR A ; PRG:$35C6 Bytes:4A
|
|
ORA $00 ; PRG:$35C7 Bytes:05 00
|
|
LSR A ; PRG:$35C9 Bytes:4A
|
|
PLA ; PRG:$35CA Bytes:68
|
|
ROL A ; PRG:$35CB Bytes:2A
|
|
DEY ; PRG:$35CC Bytes:88
|
|
BNE EnginePathLoop_F5C0 ; PRG:$35CD Bytes:D0 F1
|
|
LDY $44,X ; PRG:$35CF Bytes:B4 44
|
|
STY $00 ; PRG:$35D1 Bytes:84 00
|
|
PHA ; PRG:$35D3 Bytes:48
|
|
STA $44,X ; PRG:$35D4 Bytes:95 44
|
|
LDY $46,X ; PRG:$35D6 Bytes:B4 46
|
|
AND #$3F ; PRG:$35D8 Bytes:29 3F
|
|
STA $46,X ; PRG:$35DA Bytes:95 46
|
|
PLA ; PRG:$35DC Bytes:68
|
|
ORA $00 ; PRG:$35DD Bytes:05 00
|
|
EOR $00 ; PRG:$35DF Bytes:45 00
|
|
AND #$C0 ; PRG:$35E1 Bytes:29 C0
|
|
ORA $46,X ; PRG:$35E3 Bytes:15 46
|
|
STA $46,X ; PRG:$35E5 Bytes:95 46
|
|
TYA ; PRG:$35E7 Bytes:98
|
|
AND #$0F ; PRG:$35E8 Bytes:29 0F
|
|
AND $46,X ; PRG:$35EA Bytes:35 46
|
|
BEQ EnginePathOnZero_F5F4 ; PRG:$35EC Bytes:F0 06
|
|
ORA #$F0 ; PRG:$35EE Bytes:09 F0
|
|
AND $46,X ; PRG:$35F0 Bytes:35 46
|
|
STA $46,X ; PRG:$35F2 Bytes:95 46
|
|
EnginePathOnZero_F5F4:
|
|
RTS ; PRG:$35F4 Bytes:60
|
|
EnginePathLoop_F5F5:
|
|
BMI EnginePathLoop_F600 ; PRG:$35F5 Bytes:30 09
|
|
CPX #$F4 ; PRG:$35F7 Bytes:E0 F4
|
|
BEQ EnginePathLoop_F600 ; PRG:$35F9 Bytes:F0 05
|
|
LDA #$F4 ; PRG:$35FB Bytes:A9 F4
|
|
JSR ProcessResourceStateRoutine_F6FB ; PRG:$35FD Bytes:20 FB F6
|
|
EnginePathLoop_F600:
|
|
RTS ; PRG:$3600 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F601
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F601:
|
|
LDY #$0B ; PRG:$3601 Bytes:A0 0B
|
|
LDA ($00),Y ; PRG:$3603 Bytes:B1 00
|
|
STA $02 ; PRG:$3605 Bytes:85 02
|
|
LDA #$02 ; PRG:$3607 Bytes:A9 02
|
|
STA $03 ; PRG:$3609 Bytes:85 03
|
|
LDY #$06 ; PRG:$360B Bytes:A0 06
|
|
LDA ($00),Y ; PRG:$360D Bytes:B1 00
|
|
STA $0B ; PRG:$360F Bytes:85 0B
|
|
LDY #$01 ; PRG:$3611 Bytes:A0 01
|
|
LDA ($00),Y ; PRG:$3613 Bytes:B1 00
|
|
TAX ; PRG:$3615 Bytes:AA
|
|
STA $08 ; PRG:$3616 Bytes:85 08
|
|
DEY ; PRG:$3618 Bytes:88
|
|
LDA ($00),Y ; PRG:$3619 Bytes:B1 00
|
|
BNE EnginePathLoop_F5F5 ; PRG:$361B Bytes:D0 D8
|
|
LDY #$0A ; PRG:$361D Bytes:A0 0A
|
|
LDA ($00),Y ; PRG:$361F Bytes:B1 00
|
|
TAX ; PRG:$3621 Bytes:AA
|
|
LSR A ; PRG:$3622 Bytes:4A
|
|
LSR A ; PRG:$3623 Bytes:4A
|
|
LSR A ; PRG:$3624 Bytes:4A
|
|
LSR A ; PRG:$3625 Bytes:4A
|
|
BEQ EnginePathLoop_F600 ; PRG:$3626 Bytes:F0 D8
|
|
STA $04 ; PRG:$3628 Bytes:85 04
|
|
STA $06 ; PRG:$362A Bytes:85 06
|
|
TXA ; PRG:$362C Bytes:8A
|
|
AND #$0F ; PRG:$362D Bytes:29 0F
|
|
BEQ EnginePathLoop_F600 ; PRG:$362F Bytes:F0 CF
|
|
STA $05 ; PRG:$3631 Bytes:85 05
|
|
STA $07 ; PRG:$3633 Bytes:85 07
|
|
LDY #$08 ; PRG:$3635 Bytes:A0 08
|
|
LDA ($00),Y ; PRG:$3637 Bytes:B1 00
|
|
AND #$C0 ; PRG:$3639 Bytes:29 C0
|
|
INY ; PRG:$363B Bytes:C8
|
|
ORA ($00),Y ; PRG:$363C Bytes:11 00
|
|
STA $09 ; PRG:$363E Bytes:85 09
|
|
LDY #$03 ; PRG:$3640 Bytes:A0 03
|
|
LDA ($00),Y ; PRG:$3642 Bytes:B1 00
|
|
STA $0A ; PRG:$3644 Bytes:85 0A
|
|
LDY #$02 ; PRG:$3646 Bytes:A0 02
|
|
LDA $09 ; PRG:$3648 Bytes:A5 09
|
|
CMP ($02),Y ; PRG:$364A Bytes:D1 02
|
|
BNE EnginePathOnNonZero_F6B0 ; PRG:$364C Bytes:D0 62
|
|
LDY #$00 ; PRG:$364E Bytes:A0 00
|
|
LDA $08 ; PRG:$3650 Bytes:A5 08
|
|
CMP ($02),Y ; PRG:$3652 Bytes:D1 02
|
|
BEQ EnginePathOnZero_F659 ; PRG:$3654 Bytes:F0 03
|
|
JSR ProcessResourceStateRoutine_F707 ; PRG:$3656 Bytes:20 07 F7
|
|
EnginePathOnZero_F659:
|
|
LDY #$03 ; PRG:$3659 Bytes:A0 03
|
|
LDA $0A ; PRG:$365B Bytes:A5 0A
|
|
CMP ($02),Y ; PRG:$365D Bytes:D1 02
|
|
BEQ EnginePathOnZero_F677 ; PRG:$365F Bytes:F0 16
|
|
EnginePathLoop_F661:
|
|
LDX $05 ; PRG:$3661 Bytes:A6 05
|
|
STX $07 ; PRG:$3663 Bytes:86 07
|
|
EnginePathLoop_F665:
|
|
LDX $04 ; PRG:$3665 Bytes:A6 04
|
|
EnginePathLoop_F667:
|
|
STA ($02),Y ; PRG:$3667 Bytes:91 02
|
|
INY ; PRG:$3669 Bytes:C8
|
|
INY ; PRG:$366A Bytes:C8
|
|
INY ; PRG:$366B Bytes:C8
|
|
INY ; PRG:$366C Bytes:C8
|
|
DEX ; PRG:$366D Bytes:CA
|
|
BNE EnginePathLoop_F667 ; PRG:$366E Bytes:D0 F7
|
|
CLC ; PRG:$3670 Bytes:18
|
|
ADC #$08 ; PRG:$3671 Bytes:69 08
|
|
DEC $07 ; PRG:$3673 Bytes:C6 07
|
|
BNE EnginePathLoop_F665 ; PRG:$3675 Bytes:D0 EE
|
|
EnginePathOnZero_F677:
|
|
LDY #$05 ; PRG:$3677 Bytes:A0 05
|
|
LDA ($00),Y ; PRG:$3679 Bytes:B1 00
|
|
STA $08 ; PRG:$367B Bytes:85 08
|
|
LDA #$00 ; PRG:$367D Bytes:A9 00
|
|
LDX $0B ; PRG:$367F Bytes:A6 0B
|
|
CLC ; PRG:$3681 Bytes:18
|
|
EnginePathLoop_F682:
|
|
ADC $08 ; PRG:$3682 Bytes:65 08
|
|
DEX ; PRG:$3684 Bytes:CA
|
|
BNE EnginePathLoop_F682 ; PRG:$3685 Bytes:D0 FB
|
|
LDY #$07 ; PRG:$3687 Bytes:A0 07
|
|
ADC ($00),Y ; PRG:$3689 Bytes:71 00
|
|
TAX ; PRG:$368B Bytes:AA
|
|
LDY #$01 ; PRG:$368C Bytes:A0 01
|
|
LDA #$FF ; PRG:$368E Bytes:A9 FF
|
|
STA $0A ; PRG:$3690 Bytes:85 0A
|
|
BIT $09 ; PRG:$3692 Bytes:24 09
|
|
BMI EnginePathOnNegative_F6BE ; PRG:$3694 Bytes:30 28
|
|
BVS EnginePathOnOverflowSet_F6C0 ; PRG:$3696 Bytes:70 28
|
|
LDA #$01 ; PRG:$3698 Bytes:A9 01
|
|
STA $0A ; PRG:$369A Bytes:85 0A
|
|
EnginePathLoop_F69C:
|
|
TXA ; PRG:$369C Bytes:8A
|
|
CMP ($02),Y ; PRG:$369D Bytes:D1 02
|
|
BEQ EnginePathOnZero_F6AF ; PRG:$369F Bytes:F0 0E
|
|
LDX $0B ; PRG:$36A1 Bytes:A6 0B
|
|
EnginePathLoop_F6A3:
|
|
STA ($02),Y ; PRG:$36A3 Bytes:91 02
|
|
CLC ; PRG:$36A5 Bytes:18
|
|
ADC $0A ; PRG:$36A6 Bytes:65 0A
|
|
INY ; PRG:$36A8 Bytes:C8
|
|
INY ; PRG:$36A9 Bytes:C8
|
|
INY ; PRG:$36AA Bytes:C8
|
|
INY ; PRG:$36AB Bytes:C8
|
|
DEX ; PRG:$36AC Bytes:CA
|
|
BNE EnginePathLoop_F6A3 ; PRG:$36AD Bytes:D0 F4
|
|
EnginePathOnZero_F6AF:
|
|
RTS ; PRG:$36AF Bytes:60
|
|
EnginePathOnNonZero_F6B0:
|
|
JSR ProcessResourceStateRoutine_F6FB ; PRG:$36B0 Bytes:20 FB F6
|
|
LDY #$00 ; PRG:$36B3 Bytes:A0 00
|
|
JSR ProcessResourceStateRoutine_F707 ; PRG:$36B5 Bytes:20 07 F7
|
|
LDA $0A ; PRG:$36B8 Bytes:A5 0A
|
|
LDY #$03 ; PRG:$36BA Bytes:A0 03
|
|
BNE EnginePathLoop_F661 ; PRG:$36BC Bytes:D0 A3
|
|
EnginePathOnNegative_F6BE:
|
|
BVC EnginePathOnOverflowClear_F6D4 ; PRG:$36BE Bytes:50 14
|
|
EnginePathOnOverflowSet_F6C0:
|
|
TXA ; PRG:$36C0 Bytes:8A
|
|
ADC $0B ; PRG:$36C1 Bytes:65 0B
|
|
TAX ; PRG:$36C3 Bytes:AA
|
|
DEX ; PRG:$36C4 Bytes:CA
|
|
ASL $09 ; PRG:$36C5 Bytes:06 09
|
|
BCS EnginePathLoop_F69C ; PRG:$36C7 Bytes:B0 D3
|
|
LDA #$01 ; PRG:$36C9 Bytes:A9 01
|
|
STA $0A ; PRG:$36CB Bytes:85 0A
|
|
LDA #$00 ; PRG:$36CD Bytes:A9 00
|
|
SEC ; PRG:$36CF Bytes:38
|
|
SBC $06 ; PRG:$36D0 Bytes:E5 06
|
|
STA $06 ; PRG:$36D2 Bytes:85 06
|
|
EnginePathOnOverflowClear_F6D4:
|
|
TXA ; PRG:$36D4 Bytes:8A
|
|
LDX $04 ; PRG:$36D5 Bytes:A6 04
|
|
CLC ; PRG:$36D7 Bytes:18
|
|
ADC $06 ; PRG:$36D8 Bytes:65 06
|
|
CLC ; PRG:$36DA Bytes:18
|
|
ADC $0A ; PRG:$36DB Bytes:65 0A
|
|
CMP ($02),Y ; PRG:$36DD Bytes:D1 02
|
|
BNE EnginePathOnNonZero_F6E7 ; PRG:$36DF Bytes:D0 06
|
|
RTS ; PRG:$36E1 Bytes:60
|
|
EnginePathLoop_F6E2:
|
|
LDX $04 ; PRG:$36E2 Bytes:A6 04
|
|
EnginePathLoop_F6E4:
|
|
CLC ; PRG:$36E4 Bytes:18
|
|
ADC $0A ; PRG:$36E5 Bytes:65 0A
|
|
EnginePathOnNonZero_F6E7:
|
|
STA ($02),Y ; PRG:$36E7 Bytes:91 02
|
|
INY ; PRG:$36E9 Bytes:C8
|
|
INY ; PRG:$36EA Bytes:C8
|
|
INY ; PRG:$36EB Bytes:C8
|
|
INY ; PRG:$36EC Bytes:C8
|
|
DEX ; PRG:$36ED Bytes:CA
|
|
BNE EnginePathLoop_F6E4 ; PRG:$36EE Bytes:D0 F4
|
|
CLC ; PRG:$36F0 Bytes:18
|
|
ADC $06 ; PRG:$36F1 Bytes:65 06
|
|
CLC ; PRG:$36F3 Bytes:18
|
|
ADC $06 ; PRG:$36F4 Bytes:65 06
|
|
DEC $05 ; PRG:$36F6 Bytes:C6 05
|
|
BNE EnginePathLoop_F6E2 ; PRG:$36F8 Bytes:D0 E8
|
|
RTS ; PRG:$36FA Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F6FB
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F6FB:
|
|
LDX $0B ; PRG:$36FB Bytes:A6 0B
|
|
EnginePathLoop_F6FD:
|
|
STA ($02),Y ; PRG:$36FD Bytes:91 02
|
|
INY ; PRG:$36FF Bytes:C8
|
|
INY ; PRG:$3700 Bytes:C8
|
|
INY ; PRG:$3701 Bytes:C8
|
|
INY ; PRG:$3702 Bytes:C8
|
|
DEX ; PRG:$3703 Bytes:CA
|
|
BNE EnginePathLoop_F6FD ; PRG:$3704 Bytes:D0 F7
|
|
RTS ; PRG:$3706 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F707
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F707:
|
|
LDA $08 ; PRG:$3707 Bytes:A5 08
|
|
LDX $04 ; PRG:$3709 Bytes:A6 04
|
|
EnginePathLoop_F70B:
|
|
STA ($02),Y ; PRG:$370B Bytes:91 02
|
|
INY ; PRG:$370D Bytes:C8
|
|
INY ; PRG:$370E Bytes:C8
|
|
INY ; PRG:$370F Bytes:C8
|
|
INY ; PRG:$3710 Bytes:C8
|
|
CLC ; PRG:$3711 Bytes:18
|
|
ADC #$08 ; PRG:$3712 Bytes:69 08
|
|
DEX ; PRG:$3714 Bytes:CA
|
|
BNE EnginePathLoop_F70B ; PRG:$3715 Bytes:D0 F4
|
|
DEC $07 ; PRG:$3717 Bytes:C6 07
|
|
;------------------------------------------------------------
|
|
; EnginePath_F719
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
EnginePath_F719:
|
|
BNE ProcessResourceStateRoutine_F707 ; PRG:$3719 Bytes:D0 EC
|
|
RTS ; PRG:$371B Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F71C
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F71C:
|
|
CLC ; PRG:$371C Bytes:18
|
|
LDY #$00 ; PRG:$371D Bytes:A0 00
|
|
LDA ($00),Y ; PRG:$371F Bytes:B1 00
|
|
BNE EnginePathContinue_F77C ; PRG:$3721 Bytes:D0 59
|
|
LDA ($02),Y ; PRG:$3723 Bytes:B1 02
|
|
BNE EnginePathContinue_F77C ; PRG:$3725 Bytes:D0 55
|
|
LDY #$0C ; PRG:$3727 Bytes:A0 0C
|
|
LDA ($02),Y ; PRG:$3729 Bytes:B1 02
|
|
LDY #$01 ; PRG:$372B Bytes:A0 01
|
|
ADC ($02),Y ; PRG:$372D Bytes:71 02
|
|
STA $04 ; PRG:$372F Bytes:85 04
|
|
LDA ($00),Y ; PRG:$3731 Bytes:B1 00
|
|
LDY #$0E ; PRG:$3733 Bytes:A0 0E
|
|
CLC ; PRG:$3735 Bytes:18
|
|
ADC ($00),Y ; PRG:$3736 Bytes:71 00
|
|
CMP $04 ; PRG:$3738 Bytes:C5 04
|
|
BCC EnginePathContinue_F77C ; PRG:$373A Bytes:90 40
|
|
LDY #$0C ; PRG:$373C Bytes:A0 0C
|
|
LDA ($00),Y ; PRG:$373E Bytes:B1 00
|
|
LDY #$01 ; PRG:$3740 Bytes:A0 01
|
|
CLC ; PRG:$3742 Bytes:18
|
|
ADC ($00),Y ; PRG:$3743 Bytes:71 00
|
|
STA $04 ; PRG:$3745 Bytes:85 04
|
|
LDA ($02),Y ; PRG:$3747 Bytes:B1 02
|
|
LDY #$0E ; PRG:$3749 Bytes:A0 0E
|
|
CLC ; PRG:$374B Bytes:18
|
|
ADC ($02),Y ; PRG:$374C Bytes:71 02
|
|
CMP $04 ; PRG:$374E Bytes:C5 04
|
|
BCC EnginePathContinue_F77C ; PRG:$3750 Bytes:90 2A
|
|
LDY #$0D ; PRG:$3752 Bytes:A0 0D
|
|
LDA ($02),Y ; PRG:$3754 Bytes:B1 02
|
|
LDY #$03 ; PRG:$3756 Bytes:A0 03
|
|
CLC ; PRG:$3758 Bytes:18
|
|
ADC ($02),Y ; PRG:$3759 Bytes:71 02
|
|
STA $04 ; PRG:$375B Bytes:85 04
|
|
LDA ($00),Y ; PRG:$375D Bytes:B1 00
|
|
LDY #$0F ; PRG:$375F Bytes:A0 0F
|
|
CLC ; PRG:$3761 Bytes:18
|
|
ADC ($00),Y ; PRG:$3762 Bytes:71 00
|
|
CMP $04 ; PRG:$3764 Bytes:C5 04
|
|
BCC EnginePathContinue_F77C ; PRG:$3766 Bytes:90 14
|
|
LDY #$0D ; PRG:$3768 Bytes:A0 0D
|
|
LDA ($00),Y ; PRG:$376A Bytes:B1 00
|
|
LDY #$03 ; PRG:$376C Bytes:A0 03
|
|
CLC ; PRG:$376E Bytes:18
|
|
ADC ($00),Y ; PRG:$376F Bytes:71 00
|
|
STA $04 ; PRG:$3771 Bytes:85 04
|
|
LDA ($02),Y ; PRG:$3773 Bytes:B1 02
|
|
LDY #$0F ; PRG:$3775 Bytes:A0 0F
|
|
CLC ; PRG:$3777 Bytes:18
|
|
ADC ($02),Y ; PRG:$3778 Bytes:71 02
|
|
CMP $04 ; PRG:$377A Bytes:C5 04
|
|
EnginePathContinue_F77C:
|
|
RTS ; PRG:$377C Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessResourceStateRoutine_F77D
|
|
;
|
|
; Global:
|
|
; First-pass resource/input/collision entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessResourceStateRoutine_F77D:
|
|
STA $00 ; PRG:$377D Bytes:85 00
|
|
STX $01 ; PRG:$377F Bytes:86 01
|
|
LDY #$04 ; PRG:$3781 Bytes:A0 04
|
|
LDA ($00),Y ; PRG:$3783 Bytes:B1 00
|
|
STA $03 ; PRG:$3785 Bytes:85 03
|
|
DEY ; PRG:$3787 Bytes:88
|
|
LDA ($00),Y ; PRG:$3788 Bytes:B1 00
|
|
STA $02 ; PRG:$378A Bytes:85 02
|
|
DEY ; PRG:$378C Bytes:88
|
|
LDA ($00),Y ; PRG:$378D Bytes:B1 00
|
|
STA $05 ; PRG:$378F Bytes:85 05
|
|
DEY ; PRG:$3791 Bytes:88
|
|
LDA ($00),Y ; PRG:$3792 Bytes:B1 00
|
|
STA $04 ; PRG:$3794 Bytes:85 04
|
|
DEY ; PRG:$3796 Bytes:88
|
|
LDA ($00),Y ; PRG:$3797 Bytes:B1 00
|
|
STA $06 ; PRG:$3799 Bytes:85 06
|
|
LDA #$05 ; PRG:$379B Bytes:A9 05
|
|
EnginePathLoop_F79D:
|
|
CLC ; PRG:$379D Bytes:18
|
|
ADC a:$0000,Y ; PRG:$379E Bytes:79 00 00
|
|
STA a:$0000,Y ; PRG:$37A1 Bytes:99 00 00
|
|
LDA #$00 ; PRG:$37A4 Bytes:A9 00
|
|
ADC a:$0001,Y ; PRG:$37A6 Bytes:79 01 00
|
|
STA a:$0001,Y ; PRG:$37A9 Bytes:99 01 00
|
|
LDY #$00 ; PRG:$37AC Bytes:A0 00
|
|
LDX $05 ; PRG:$37AE Bytes:A6 05
|
|
EnginePathLoop_F7B0:
|
|
LDA ($00),Y ; PRG:$37B0 Bytes:B1 00
|
|
STA ($02),Y ; PRG:$37B2 Bytes:91 02
|
|
INY ; PRG:$37B4 Bytes:C8
|
|
DEX ; PRG:$37B5 Bytes:CA
|
|
BNE EnginePathLoop_F7B0 ; PRG:$37B6 Bytes:D0 F8
|
|
LDA $06 ; PRG:$37B8 Bytes:A5 06
|
|
LDY #$02 ; PRG:$37BA Bytes:A0 02
|
|
DEC $04 ; PRG:$37BC Bytes:C6 04
|
|
BNE EnginePathLoop_F79D ; PRG:$37BE Bytes:D0 DD
|
|
RTS ; PRG:$37C0 Bytes:60
|
|
|
|
;------------------------------------------------------------
|
|
; Audio driver code and embedded tables
|
|
; CPU $F7C1-$FC77
|
|
; PRG $37C1-$3C77
|
|
;
|
|
; Pass 1 recursively traced from AudioDriverCode ($F7C1).
|
|
; Direct branches, jumps, and subroutine calls are decoded.
|
|
; Bytes not reached by that trace remain explicit .byte data.
|
|
;------------------------------------------------------------
|
|
|
|
;------------------------------------------------------------
|
|
; AudioDriverCode
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
AudioDriverCode:
|
|
LDA #$FF ; PRG:$37C1 Bytes:A9 FF
|
|
STA JOY2 ; PRG:$37C3 Bytes:8D 17 40
|
|
JSR ProcessAudioStateRoutine_F898 ; PRG:$37C6 Bytes:20 98 F8
|
|
JSR ProcessAudioStateRoutine_FA2E ; PRG:$37C9 Bytes:20 2E FA
|
|
JSR ProcessAudioStateRoutine_FACF ; PRG:$37CC Bytes:20 CF FA
|
|
JSR ProcessAudioStateRoutine_FB22 ; PRG:$37CF Bytes:20 22 FB
|
|
LDA #$00 ; PRG:$37D2 Bytes:A9 00
|
|
STA AudioRequest4 ; PRG:$37D4 Bytes:85 FF
|
|
STA AudioRequest3 ; PRG:$37D6 Bytes:85 FE
|
|
STA AudioRequest1 ; PRG:$37D8 Bytes:85 FC
|
|
STA AudioRequest0 ; PRG:$37DA Bytes:85 FB
|
|
LDY $07FE ; PRG:$37DC Bytes:AC FE 07
|
|
LDA AudioNoiseState ; PRG:$37DF Bytes:A5 F3
|
|
AND #$1C ; PRG:$37E1 Bytes:29 1C
|
|
BEQ AudioPathOnZero_F7EC ; PRG:$37E3 Bytes:F0 07
|
|
INC $07FE ; PRG:$37E5 Bytes:EE FE 07
|
|
CPY #$50 ; PRG:$37E8 Bytes:C0 50
|
|
BCC AudioPathContinue_F7F2 ; PRG:$37EA Bytes:90 06
|
|
AudioPathOnZero_F7EC:
|
|
TYA ; PRG:$37EC Bytes:98
|
|
BEQ AudioPathContinue_F7F2 ; PRG:$37ED Bytes:F0 03
|
|
DEC $07FE ; PRG:$37EF Bytes:CE FE 07
|
|
AudioPathContinue_F7F2:
|
|
STY $4011 ; PRG:$37F2 Bytes:8C 11 40
|
|
RTS ; PRG:$37F5 Bytes:60
|
|
;------------------------------------------------------------
|
|
; UpdatePulse1Routine_F7F6
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdatePulse1Routine_F7F6:
|
|
STX SQ1_VOL ; PRG:$37F6 Bytes:8E 00 40
|
|
STY SQ1_SWEEP ; PRG:$37F9 Bytes:8C 01 40
|
|
RTS ; PRG:$37FC Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_F7FD
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_F7FD:
|
|
JSR UpdatePulse1Routine_F7F6 ; PRG:$37FD Bytes:20 F6 F7
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_F800
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_F800:
|
|
LDX #$00 ; PRG:$3800 Bytes:A2 00
|
|
UpdatePulse1Loop_F802:
|
|
TAY ; PRG:$3802 Bytes:A8
|
|
LDA $FF01,Y ; PRG:$3803 Bytes:B9 01 FF
|
|
BEQ AudioPathOnZero_F813 ; PRG:$3806 Bytes:F0 0B
|
|
STA SQ1_LO,X ; PRG:$3808 Bytes:9D 02 40
|
|
LDA $FF00,Y ; PRG:$380B Bytes:B9 00 FF
|
|
ORA #$08 ; PRG:$380E Bytes:09 08
|
|
STA SQ1_HI,X ; PRG:$3810 Bytes:9D 03 40
|
|
AudioPathOnZero_F813:
|
|
RTS ; PRG:$3813 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_F814
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_F814:
|
|
LDX #$04 ; PRG:$3814 Bytes:A2 04
|
|
BNE UpdatePulse1Loop_F802 ; PRG:$3816 Bytes:D0 EA
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_F818
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_F818:
|
|
LDX #$08 ; PRG:$3818 Bytes:A2 08
|
|
BNE UpdatePulse1Loop_F802 ; PRG:$381A Bytes:D0 E6
|
|
STY $7E85 ; PRG:$381C Bytes:8C 85 7E
|
|
.byte $77, $70, $69, $62, $5B, $54, $4D, $46, $3F, $38, $31, $2A, $23, $04, $0E, $04 ; PRG:$381F Bytes:77 70 69 62 5B 54 4D 46 3F 38 31 2A 23 04 0E 04
|
|
.byte $2E, $0E, $2E, $2C, $0E, $2C, $2A, $0E, $2A, $28, $2C, $28, $26, $91, $91, $51 ; PRG:$382F Bytes:2E 0E 2E 2C 0E 2C 2A 0E 2A 28 2C 28 26 91 91 51
|
|
.byte $92, $92, $92, $53, $93, $93, $93, $54, $94, $94, $54, $54, $95, $95, $95, $55 ; PRG:$383F Bytes:92 92 92 53 93 93 93 54 94 94 54 54 95 95 95 55
|
|
.byte $95, $95, $96, $56, $96, $96, $97, $57, $97, $97, $57, $57, $98, $98, $98, $58 ; PRG:$384F Bytes:95 95 96 56 96 96 97 57 97 97 57 57 98 98 98 58
|
|
.byte $98, $99, $99, $59, $9A, $9A, $9B, $5C, $9D, $9E, $5A, $5A ; PRG:$385F Bytes:98 99 99 59 9A 9A 9B 5C 9D 9E 5A 5A
|
|
AudioPathLoop_F86B:
|
|
STY AudioPulse1State ; PRG:$386B Bytes:84 F0
|
|
LDA #$8C ; PRG:$386D Bytes:A9 8C
|
|
STA AudioPeriodOrEnvelope ; PRG:$386F Bytes:85 F4
|
|
AudioPathLoop_F871:
|
|
LDA AudioPeriodOrEnvelope ; PRG:$3871 Bytes:A5 F4
|
|
LDY #$10 ; PRG:$3873 Bytes:A0 10
|
|
AudioPathLoop_F875:
|
|
CMP $F81B,Y ; PRG:$3875 Bytes:D9 1B F8
|
|
BNE AudioPathOnNonZero_F881 ; PRG:$3878 Bytes:D0 07
|
|
LDA $F82B,Y ; PRG:$387A Bytes:B9 2B F8
|
|
LDY #$7F ; PRG:$387D Bytes:A0 7F
|
|
BNE AudioPathOnNonZero_F890 ; PRG:$387F Bytes:D0 0F
|
|
AudioPathOnNonZero_F881:
|
|
DEY ; PRG:$3881 Bytes:88
|
|
BNE AudioPathLoop_F875 ; PRG:$3882 Bytes:D0 F1
|
|
CMP #$16 ; PRG:$3884 Bytes:C9 16
|
|
BCS AudioPathContinue_F895 ; PRG:$3886 Bytes:B0 0D
|
|
AND #$03 ; PRG:$3888 Bytes:29 03
|
|
BNE AudioPathContinue_F895 ; PRG:$388A Bytes:D0 09
|
|
LDY #$A3 ; PRG:$388C Bytes:A0 A3
|
|
LDA #$2A ; PRG:$388E Bytes:A9 2A
|
|
AudioPathOnNonZero_F890:
|
|
LDX #$9F ; PRG:$3890 Bytes:A2 9F
|
|
JSR ProcessAudioStateRoutine_F7FD ; PRG:$3892 Bytes:20 FD F7
|
|
AudioPathContinue_F895:
|
|
JMP ProcessAudioStateDispatch_F9CB ; PRG:$3895 Bytes:4C CB F9
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_F898
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_F898:
|
|
LDY AudioRequest4 ; PRG:$3898 Bytes:A4 FF
|
|
LDA $F0 ; PRG:$389A Bytes:A5 F0
|
|
LSR AudioRequest4 ; PRG:$389C Bytes:46 FF
|
|
BCS AudioPathLoop_F86B ; PRG:$389E Bytes:B0 CB
|
|
LSR A ; PRG:$38A0 Bytes:4A
|
|
BCS AudioPathLoop_F871 ; PRG:$38A1 Bytes:B0 CE
|
|
LSR AudioRequest4 ; PRG:$38A3 Bytes:46 FF
|
|
BCC UpdatePulse1OnNoCarry_F8F9 ; PRG:$38A5 Bytes:90 52
|
|
STY AudioPulse1State ; PRG:$38A7 Bytes:84 F0
|
|
LDA #$2F ; PRG:$38A9 Bytes:A9 2F
|
|
STA $07F4 ; PRG:$38AB Bytes:8D F4 07
|
|
LDX #$5F ; PRG:$38AE Bytes:A2 5F
|
|
LDY #$93 ; PRG:$38B0 Bytes:A0 93
|
|
JSR UpdatePulse1Routine_F7F6 ; PRG:$38B2 Bytes:20 F6 F7
|
|
AudioPathLoop_F8B5:
|
|
LDA $07F4 ; PRG:$38B5 Bytes:AD F4 07
|
|
CMP #$C0 ; PRG:$38B8 Bytes:C9 C0
|
|
BCC AudioPathOnNoCarry_F8BD ; PRG:$38BA Bytes:90 01
|
|
LSR A ; PRG:$38BC Bytes:4A
|
|
AudioPathOnNoCarry_F8BD:
|
|
LSR A ; PRG:$38BD Bytes:4A
|
|
LSR A ; PRG:$38BE Bytes:4A
|
|
LSR A ; PRG:$38BF Bytes:4A
|
|
LSR A ; PRG:$38C0 Bytes:4A
|
|
CLC ; PRG:$38C1 Bytes:18
|
|
ADC $07F4 ; PRG:$38C2 Bytes:6D F4 07
|
|
BCC UpdatePulse1OnNoCarry_F8EA ; PRG:$38C5 Bytes:90 23
|
|
AudioPathLoop_F8C7:
|
|
JMP ProcessAudioStateDispatch_F9CF ; PRG:$38C7 Bytes:4C CF F9
|
|
AudioPathLoop_F8CA:
|
|
STY AudioPulse1State ; PRG:$38CA Bytes:84 F0
|
|
LDA #$FE ; PRG:$38CC Bytes:A9 FE
|
|
STA $07F4 ; PRG:$38CE Bytes:8D F4 07
|
|
LDX #$5C ; PRG:$38D1 Bytes:A2 5C
|
|
LDY #$BA ; PRG:$38D3 Bytes:A0 BA
|
|
JSR UpdatePulse1Routine_F7F6 ; PRG:$38D5 Bytes:20 F6 F7
|
|
AudioPathLoop_F8D8:
|
|
LDA $07F4 ; PRG:$38D8 Bytes:AD F4 07
|
|
LSR A ; PRG:$38DB Bytes:4A
|
|
LSR A ; PRG:$38DC Bytes:4A
|
|
LSR A ; PRG:$38DD Bytes:4A
|
|
BNE AudioPathOnNonZero_F8E2 ; PRG:$38DE Bytes:D0 02
|
|
LDA #$01 ; PRG:$38E0 Bytes:A9 01
|
|
AudioPathOnNonZero_F8E2:
|
|
EOR #$FF ; PRG:$38E2 Bytes:49 FF
|
|
SEC ; PRG:$38E4 Bytes:38
|
|
ADC $07F4 ; PRG:$38E5 Bytes:6D F4 07
|
|
BCC AudioPathLoop_F8C7 ; PRG:$38E8 Bytes:90 DD
|
|
UpdatePulse1OnNoCarry_F8EA:
|
|
STA $07F4 ; PRG:$38EA Bytes:8D F4 07
|
|
ROL A ; PRG:$38ED Bytes:2A
|
|
ROL A ; PRG:$38EE Bytes:2A
|
|
STA SQ1_LO ; PRG:$38EF Bytes:8D 02 40
|
|
ROL A ; PRG:$38F2 Bytes:2A
|
|
AND #$03 ; PRG:$38F3 Bytes:29 03
|
|
STA SQ1_HI ; PRG:$38F5 Bytes:8D 03 40
|
|
RTS ; PRG:$38F8 Bytes:60
|
|
UpdatePulse1OnNoCarry_F8F9:
|
|
LSR A ; PRG:$38F9 Bytes:4A
|
|
BCS AudioPathLoop_F8B5 ; PRG:$38FA Bytes:B0 B9
|
|
LSR AudioRequest4 ; PRG:$38FC Bytes:46 FF
|
|
BCS AudioPathLoop_F8CA ; PRG:$38FE Bytes:B0 CA
|
|
LSR A ; PRG:$3900 Bytes:4A
|
|
BCS AudioPathLoop_F8D8 ; PRG:$3901 Bytes:B0 D5
|
|
LSR AudioRequest4 ; PRG:$3903 Bytes:46 FF
|
|
BCC UpdatePulse1OnNoCarry_F95F ; PRG:$3905 Bytes:90 58
|
|
STY AudioPulse1State ; PRG:$3907 Bytes:84 F0
|
|
LDA #$3A ; PRG:$3909 Bytes:A9 3A
|
|
STA AudioPeriodOrEnvelope ; PRG:$390B Bytes:85 F4
|
|
LDA #$6A ; PRG:$390D Bytes:A9 6A
|
|
STA $07F4 ; PRG:$390F Bytes:8D F4 07
|
|
LDA #$82 ; PRG:$3912 Bytes:A9 82
|
|
STA SQ1_SWEEP ; PRG:$3914 Bytes:8D 01 40
|
|
UpdatePulse1Loop_F917:
|
|
LDA AudioPeriodOrEnvelope ; PRG:$3917 Bytes:A5 F4
|
|
CMP #$34 ; PRG:$3919 Bytes:C9 34
|
|
BCC UpdatePulse1OnNoCarry_F935 ; PRG:$391B Bytes:90 18
|
|
BEQ UpdatePulse1OnZero_F92B ; PRG:$391D Bytes:F0 0C
|
|
ORA #$90 ; PRG:$391F Bytes:09 90
|
|
STA SQ1_VOL ; PRG:$3921 Bytes:8D 00 40
|
|
LDA $07F4 ; PRG:$3924 Bytes:AD F4 07
|
|
SBC #$FC ; PRG:$3927 Bytes:E9 FC
|
|
BNE UpdatePulse1OnNonZero_F94D ; PRG:$3929 Bytes:D0 22
|
|
UpdatePulse1OnZero_F92B:
|
|
LDX #$FF ; PRG:$392B Bytes:A2 FF
|
|
STX $07F4 ; PRG:$392D Bytes:8E F4 07
|
|
LDY #$8C ; PRG:$3930 Bytes:A0 8C
|
|
STY SQ1_SWEEP ; PRG:$3932 Bytes:8C 01 40
|
|
UpdatePulse1OnNoCarry_F935:
|
|
LSR A ; PRG:$3935 Bytes:4A
|
|
LSR A ; PRG:$3936 Bytes:4A
|
|
ORA #$90 ; PRG:$3937 Bytes:09 90
|
|
STA SQ1_VOL ; PRG:$3939 Bytes:8D 00 40
|
|
LDA AudioPeriodOrEnvelope ; PRG:$393C Bytes:A5 F4
|
|
AND #$03 ; PRG:$393E Bytes:29 03
|
|
BNE AudioPathOnNonZero_F95C ; PRG:$3940 Bytes:D0 1A
|
|
LDA $07F4 ; PRG:$3942 Bytes:AD F4 07
|
|
LSR A ; PRG:$3945 Bytes:4A
|
|
LSR A ; PRG:$3946 Bytes:4A
|
|
LSR A ; PRG:$3947 Bytes:4A
|
|
LSR A ; PRG:$3948 Bytes:4A
|
|
SEC ; PRG:$3949 Bytes:38
|
|
SBC $07F4 ; PRG:$394A Bytes:ED F4 07
|
|
UpdatePulse1OnNonZero_F94D:
|
|
STA $07F4 ; PRG:$394D Bytes:8D F4 07
|
|
ROL A ; PRG:$3950 Bytes:2A
|
|
ROL A ; PRG:$3951 Bytes:2A
|
|
ROL A ; PRG:$3952 Bytes:2A
|
|
STA SQ1_LO ; PRG:$3953 Bytes:8D 02 40
|
|
ROL A ; PRG:$3956 Bytes:2A
|
|
AND #$07 ; PRG:$3957 Bytes:29 07
|
|
STA SQ1_HI ; PRG:$3959 Bytes:8D 03 40
|
|
AudioPathOnNonZero_F95C:
|
|
JMP ProcessAudioStateDispatch_F9CB ; PRG:$395C Bytes:4C CB F9
|
|
UpdatePulse1OnNoCarry_F95F:
|
|
LSR A ; PRG:$395F Bytes:4A
|
|
BCS UpdatePulse1Loop_F917 ; PRG:$3960 Bytes:B0 B5
|
|
LSR $FF ; PRG:$3962 Bytes:46 FF
|
|
BCC AudioPathOnNoCarry_F9D9 ; PRG:$3964 Bytes:90 73
|
|
STY $F0 ; PRG:$3966 Bytes:84 F0
|
|
LDA #$30 ; PRG:$3968 Bytes:A9 30
|
|
STA AudioPeriodOrEnvelope ; PRG:$396A Bytes:85 F4
|
|
LDA #$8A ; PRG:$396C Bytes:A9 8A
|
|
STA SQ1_SWEEP ; PRG:$396E Bytes:8D 01 40
|
|
AudioPathLoop_F971:
|
|
LDY $F4 ; PRG:$3971 Bytes:A4 F4
|
|
LDA $F83A,Y ; PRG:$3973 Bytes:B9 3A F8
|
|
UpdatePulse1Dispatch_F976:
|
|
LDX $F83A,Y ; PRG:$3976 Bytes:BE 3A F8
|
|
STX SQ1_VOL ; PRG:$3979 Bytes:8E 00 40
|
|
BNE UpdatePulse1OnNonZero_F9C3 ; PRG:$397C Bytes:D0 45
|
|
AudioPathLoop_F97E:
|
|
STY $F0 ; PRG:$397E Bytes:84 F0
|
|
LDA #$28 ; PRG:$3980 Bytes:A9 28
|
|
STA $F4 ; PRG:$3982 Bytes:85 F4
|
|
LDX #$82 ; PRG:$3984 Bytes:A2 82
|
|
LDY #$A7 ; PRG:$3986 Bytes:A0 A7
|
|
LDA #$30 ; PRG:$3988 Bytes:A9 30
|
|
JSR ProcessAudioStateRoutine_F7FD ; PRG:$398A Bytes:20 FD F7
|
|
AudioPathLoop_F98D:
|
|
LDA $F4 ; PRG:$398D Bytes:A5 F4
|
|
CMP #$25 ; PRG:$398F Bytes:C9 25
|
|
BNE AudioPathOnNonZero_F999 ; PRG:$3991 Bytes:D0 06
|
|
LDX #$5F ; PRG:$3993 Bytes:A2 5F
|
|
LDY #$F6 ; PRG:$3995 Bytes:A0 F6
|
|
BNE AudioPathOnNonZero_F9A9 ; PRG:$3997 Bytes:D0 10
|
|
AudioPathOnNonZero_F999:
|
|
CMP #$20 ; PRG:$3999 Bytes:C9 20
|
|
BNE AudioPathOnNonZero_F9A1 ; PRG:$399B Bytes:D0 04
|
|
LDY #$BC ; PRG:$399D Bytes:A0 BC
|
|
BNE AudioPathOnNonZero_F9A7 ; PRG:$399F Bytes:D0 06
|
|
AudioPathOnNonZero_F9A1:
|
|
CMP #$10 ; PRG:$39A1 Bytes:C9 10
|
|
BNE ProcessAudioStateDispatch_F9CB ; PRG:$39A3 Bytes:D0 26
|
|
LDY #$9C ; PRG:$39A5 Bytes:A0 9C
|
|
AudioPathOnNonZero_F9A7:
|
|
LDX #$48 ; PRG:$39A7 Bytes:A2 48
|
|
AudioPathOnNonZero_F9A9:
|
|
JSR UpdatePulse1Routine_F7F6 ; PRG:$39A9 Bytes:20 F6 F7
|
|
BNE ProcessAudioStateDispatch_F9CB ; PRG:$39AC Bytes:D0 1D
|
|
AudioPathLoop_F9AE:
|
|
STY $F0 ; PRG:$39AE Bytes:84 F0
|
|
LDA #$17 ; PRG:$39B0 Bytes:A9 17
|
|
STA $F4 ; PRG:$39B2 Bytes:85 F4
|
|
LDX #$5F ; PRG:$39B4 Bytes:A2 5F
|
|
LDY #$7F ; PRG:$39B6 Bytes:A0 7F
|
|
JSR UpdatePulse1Routine_F7F6 ; PRG:$39B8 Bytes:20 F6 F7
|
|
AudioPathLoop_F9BB:
|
|
LDA $F4 ; PRG:$39BB Bytes:A5 F4
|
|
AND #$07 ; PRG:$39BD Bytes:29 07
|
|
TAY ; PRG:$39BF Bytes:A8
|
|
LDA $FFC2,Y ; PRG:$39C0 Bytes:B9 C2 FF
|
|
UpdatePulse1OnNonZero_F9C3:
|
|
STA SQ1_LO ; PRG:$39C3 Bytes:8D 02 40
|
|
LDA #$08 ; PRG:$39C6 Bytes:A9 08
|
|
STA SQ1_HI ; PRG:$39C8 Bytes:8D 03 40
|
|
ProcessAudioStateDispatch_F9CB:
|
|
DEC $F4 ; PRG:$39CB Bytes:C6 F4
|
|
BNE AudioPathOnNonZero_F9D8 ; PRG:$39CD Bytes:D0 09
|
|
ProcessAudioStateDispatch_F9CF:
|
|
LDA #$00 ; PRG:$39CF Bytes:A9 00
|
|
STA $F0 ; PRG:$39D1 Bytes:85 F0
|
|
;------------------------------------------------------------
|
|
; UpdatePulse1Routine_F9D3
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdatePulse1Routine_F9D3:
|
|
LDA #$90 ; PRG:$39D3 Bytes:A9 90
|
|
STA SQ1_VOL ; PRG:$39D5 Bytes:8D 00 40
|
|
AudioPathOnNonZero_F9D8:
|
|
RTS ; PRG:$39D8 Bytes:60
|
|
AudioPathOnNoCarry_F9D9:
|
|
LSR A ; PRG:$39D9 Bytes:4A
|
|
BCS AudioPathLoop_F971 ; PRG:$39DA Bytes:B0 95
|
|
LSR $FF ; PRG:$39DC Bytes:46 FF
|
|
BCS AudioPathLoop_F97E ; PRG:$39DE Bytes:B0 9E
|
|
LSR A ; PRG:$39E0 Bytes:4A
|
|
BCS AudioPathLoop_F98D ; PRG:$39E1 Bytes:B0 AA
|
|
LSR $FF ; PRG:$39E3 Bytes:46 FF
|
|
BCS AudioPathLoop_F9AE ; PRG:$39E5 Bytes:B0 C7
|
|
LSR A ; PRG:$39E7 Bytes:4A
|
|
BCS AudioPathLoop_F9BB ; PRG:$39E8 Bytes:B0 D1
|
|
LSR $FF ; PRG:$39EA Bytes:46 FF
|
|
BCS AudioPathOnCarry_F9F2 ; PRG:$39EC Bytes:B0 04
|
|
LSR A ; PRG:$39EE Bytes:4A
|
|
BCS AudioPathOnCarry_F9FC ; PRG:$39EF Bytes:B0 0B
|
|
RTS ; PRG:$39F1 Bytes:60
|
|
AudioPathOnCarry_F9F2:
|
|
STY $F0 ; PRG:$39F2 Bytes:84 F0
|
|
LDA #$20 ; PRG:$39F4 Bytes:A9 20
|
|
STA $F4 ; PRG:$39F6 Bytes:85 F4
|
|
LDA #$8A ; PRG:$39F8 Bytes:A9 8A
|
|
BNE UpdatePulse1OnNonZero_FA04 ; PRG:$39FA Bytes:D0 08
|
|
AudioPathOnCarry_F9FC:
|
|
LDY $F4 ; PRG:$39FC Bytes:A4 F4
|
|
CPY #$19 ; PRG:$39FE Bytes:C0 19
|
|
BNE AudioPathOnNonZero_FA07 ; PRG:$3A00 Bytes:D0 05
|
|
LDA #$82 ; PRG:$3A02 Bytes:A9 82
|
|
UpdatePulse1OnNonZero_FA04:
|
|
STA SQ1_SWEEP ; PRG:$3A04 Bytes:8D 01 40
|
|
AudioPathOnNonZero_FA07:
|
|
LDA #$47 ; PRG:$3A07 Bytes:A9 47
|
|
JMP UpdatePulse1Dispatch_F976 ; PRG:$3A09 Bytes:4C 76 F9
|
|
;------------------------------------------------------------
|
|
; UpdatePulse2Routine_FA0C
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
UpdatePulse2Routine_FA0C:
|
|
STY $F1 ; PRG:$3A0C Bytes:84 F1
|
|
STX $07FF ; PRG:$3A0E Bytes:8E FF 07
|
|
LDA #$9F ; PRG:$3A11 Bytes:A9 9F
|
|
STA SQ2_VOL ; PRG:$3A13 Bytes:8D 04 40
|
|
LDA #$7F ; PRG:$3A16 Bytes:A9 7F
|
|
STA SQ2_SWEEP ; PRG:$3A18 Bytes:8D 05 40
|
|
LDA #$08 ; PRG:$3A1B Bytes:A9 08
|
|
STA SQ2_HI ; PRG:$3A1D Bytes:8D 07 40
|
|
RTS ; PRG:$3A20 Bytes:60
|
|
AudioPathLoop_FA21:
|
|
LDX #$08 ; PRG:$3A21 Bytes:A2 08
|
|
JSR UpdatePulse2Routine_FA0C ; PRG:$3A23 Bytes:20 0C FA
|
|
AudioPathLoop_FA26:
|
|
LDY $07FF ; PRG:$3A26 Bytes:AC FF 07
|
|
LDA $FFB9,Y ; PRG:$3A29 Bytes:B9 B9 FF
|
|
BNE UpdatePulse2OnNonZero_FA4E ; PRG:$3A2C Bytes:D0 20
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_FA2E
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_FA2E:
|
|
LDY $FE ; PRG:$3A2E Bytes:A4 FE
|
|
LDA $F1 ; PRG:$3A30 Bytes:A5 F1
|
|
LSR $FE ; PRG:$3A32 Bytes:46 FE
|
|
BCS AudioPathLoop_FA21 ; PRG:$3A34 Bytes:B0 EB
|
|
LSR A ; PRG:$3A36 Bytes:4A
|
|
BCS AudioPathLoop_FA26 ; PRG:$3A37 Bytes:B0 ED
|
|
LSR $FE ; PRG:$3A39 Bytes:46 FE
|
|
BCS AudioPathOnCarry_FA41 ; PRG:$3A3B Bytes:B0 04
|
|
LSR A ; PRG:$3A3D Bytes:4A
|
|
BCS AudioPathOnCarry_FA46 ; PRG:$3A3E Bytes:B0 06
|
|
RTS ; PRG:$3A40 Bytes:60
|
|
AudioPathOnCarry_FA41:
|
|
LDX #$23 ; PRG:$3A41 Bytes:A2 23
|
|
JSR UpdatePulse2Routine_FA0C ; PRG:$3A43 Bytes:20 0C FA
|
|
AudioPathOnCarry_FA46:
|
|
LDA $07FF ; PRG:$3A46 Bytes:AD FF 07
|
|
LSR A ; PRG:$3A49 Bytes:4A
|
|
TAY ; PRG:$3A4A Bytes:A8
|
|
LDA $FA5B,Y ; PRG:$3A4B Bytes:B9 5B FA
|
|
UpdatePulse2OnNonZero_FA4E:
|
|
STA SQ2_LO ; PRG:$3A4E Bytes:8D 06 40
|
|
DEC $07FF ; PRG:$3A51 Bytes:CE FF 07
|
|
BNE AudioPathOnNonZero_FA5A ; PRG:$3A54 Bytes:D0 04
|
|
LDA #$00 ; PRG:$3A56 Bytes:A9 00
|
|
STA $F1 ; PRG:$3A58 Bytes:85 F1
|
|
AudioPathOnNonZero_FA5A:
|
|
RTS ; PRG:$3A5A Bytes:60
|
|
.byte $00, $54, $00, $5F, $00, $6A, $00, $71, $00, $6A, $00, $71, $00, $7E, $00, $86 ; PRG:$3A5B Bytes:00 54 00 5F 00 6A 00 71 00 6A 00 71 00 7E 00 86
|
|
.byte $00, $7E, $10, $12, $12, $12, $15, $15, $15, $13, $13, $13, $13, $16, $16, $16 ; PRG:$3A6B Bytes:00 7E 10 12 12 12 15 15 15 13 13 13 13 16 16 16
|
|
.byte $16, $16, $14, $14, $14, $14, $17, $17, $17, $17, $15, $15, $15, $15, $18, $19 ; PRG:$3A7B Bytes:16 16 14 14 14 14 17 17 17 17 15 15 15 15 18 19
|
|
.byte $19, $1A, $1A, $1A, $1B, $1B, $1C, $1D, $1E, $1F, $13, $15, $16, $16, $18, $18 ; PRG:$3A8B Bytes:19 1A 1A 1A 1B 1B 1C 1D 1E 1F 13 15 16 16 18 18
|
|
.byte $1A, $1A, $07, $05, $05, $05, $05, $05, $06, $06, $06, $04, $04, $04, $04, $05 ; PRG:$3A9B Bytes:1A 1A 07 05 05 05 05 05 06 06 06 04 04 04 04 05
|
|
.byte $05, $05, $09, $09, $0A, $0A, $07, $07, $08, $08 ; PRG:$3AAB Bytes:05 05 09 09 0A 0A 07 07 08 08
|
|
AudioPathLoop_FAB5:
|
|
STY $F2 ; PRG:$3AB5 Bytes:84 F2
|
|
LDA #$30 ; PRG:$3AB7 Bytes:A9 30
|
|
STA $07FB ; PRG:$3AB9 Bytes:8D FB 07
|
|
UpdateNoiseLoop_FABC:
|
|
LDY $07FB ; PRG:$3ABC Bytes:AC FB 07
|
|
LDA $FA6C,Y ; PRG:$3ABF Bytes:B9 6C FA
|
|
STA NOISE_VOL ; PRG:$3AC2 Bytes:8D 0C 40
|
|
LDA $07FB ; PRG:$3AC5 Bytes:AD FB 07
|
|
LSR A ; PRG:$3AC8 Bytes:4A
|
|
TAY ; PRG:$3AC9 Bytes:A8
|
|
LDA $FA9C,Y ; PRG:$3ACA Bytes:B9 9C FA
|
|
BNE UpdateNoiseOnNonZero_FB10 ; PRG:$3ACD Bytes:D0 41
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_FACF
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_FACF:
|
|
LDY $FC ; PRG:$3ACF Bytes:A4 FC
|
|
LDA $F2 ; PRG:$3AD1 Bytes:A5 F2
|
|
LSR $FC ; PRG:$3AD3 Bytes:46 FC
|
|
BCS AudioPathLoop_FAB5 ; PRG:$3AD5 Bytes:B0 DE
|
|
LSR A ; PRG:$3AD7 Bytes:4A
|
|
BCS UpdateNoiseLoop_FABC ; PRG:$3AD8 Bytes:B0 E2
|
|
LSR $FC ; PRG:$3ADA Bytes:46 FC
|
|
BCS AudioPathOnCarry_FAE9 ; PRG:$3ADC Bytes:B0 0B
|
|
LSR A ; PRG:$3ADE Bytes:4A
|
|
BCS UpdateNoiseOnCarry_FAF0 ; PRG:$3ADF Bytes:B0 0F
|
|
LSR $FC ; PRG:$3AE1 Bytes:46 FC
|
|
BCS AudioPathOnCarry_FAFE ; PRG:$3AE3 Bytes:B0 19
|
|
LSR A ; PRG:$3AE5 Bytes:4A
|
|
BCS UpdateNoiseOnCarry_FB05 ; PRG:$3AE6 Bytes:B0 1D
|
|
RTS ; PRG:$3AE8 Bytes:60
|
|
AudioPathOnCarry_FAE9:
|
|
STY $F2 ; PRG:$3AE9 Bytes:84 F2
|
|
LDA #$20 ; PRG:$3AEB Bytes:A9 20
|
|
STA $07FB ; PRG:$3AED Bytes:8D FB 07
|
|
UpdateNoiseOnCarry_FAF0:
|
|
LDY $07FB ; PRG:$3AF0 Bytes:AC FB 07
|
|
LDA $FF50,Y ; PRG:$3AF3 Bytes:B9 50 FF
|
|
STA NOISE_VOL ; PRG:$3AF6 Bytes:8D 0C 40
|
|
LDA $FF70,Y ; PRG:$3AF9 Bytes:B9 70 FF
|
|
BNE UpdateNoiseOnNonZero_FB10 ; PRG:$3AFC Bytes:D0 12
|
|
AudioPathOnCarry_FAFE:
|
|
STY $F2 ; PRG:$3AFE Bytes:84 F2
|
|
LDA #$09 ; PRG:$3B00 Bytes:A9 09
|
|
STA $07FB ; PRG:$3B02 Bytes:8D FB 07
|
|
UpdateNoiseOnCarry_FB05:
|
|
LDY $07FB ; PRG:$3B05 Bytes:AC FB 07
|
|
LDA $FF90,Y ; PRG:$3B08 Bytes:B9 90 FF
|
|
STA NOISE_VOL ; PRG:$3B0B Bytes:8D 0C 40
|
|
LDA #$04 ; PRG:$3B0E Bytes:A9 04
|
|
UpdateNoiseOnNonZero_FB10:
|
|
STA NOISE_LO ; PRG:$3B10 Bytes:8D 0E 40
|
|
LDA #$08 ; PRG:$3B13 Bytes:A9 08
|
|
STA NOISE_HI ; PRG:$3B15 Bytes:8D 0F 40
|
|
DEC $07FB ; PRG:$3B18 Bytes:CE FB 07
|
|
BNE AudioPathOnNonZero_FB21 ; PRG:$3B1B Bytes:D0 04
|
|
LDA #$00 ; PRG:$3B1D Bytes:A9 00
|
|
STA $F2 ; PRG:$3B1F Bytes:85 F2
|
|
AudioPathOnNonZero_FB21:
|
|
RTS ; PRG:$3B21 Bytes:60
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_FB22
|
|
;
|
|
; Global:
|
|
; First-pass audio-driver entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the audio naming pass.
|
|
;
|
|
; Parameters:
|
|
; Audio workspace and APU register state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_FB22:
|
|
LDA $FB ; PRG:$3B22 Bytes:A5 FB
|
|
BNE AudioPathLoop_FB2B ; PRG:$3B24 Bytes:D0 05
|
|
LDA $F3 ; PRG:$3B26 Bytes:A5 F3
|
|
BNE AudioPathOnNonZero_FB6E ; PRG:$3B28 Bytes:D0 44
|
|
RTS ; PRG:$3B2A Bytes:60
|
|
AudioPathLoop_FB2B:
|
|
STA $F3 ; PRG:$3B2B Bytes:85 F3
|
|
LDY #$00 ; PRG:$3B2D Bytes:A0 00
|
|
STY $F8 ; PRG:$3B2F Bytes:84 F8
|
|
UpdatePulse1Loop_FB31:
|
|
INY ; PRG:$3B31 Bytes:C8
|
|
LSR A ; PRG:$3B32 Bytes:4A
|
|
BCC UpdatePulse1Loop_FB31 ; PRG:$3B33 Bytes:90 FC
|
|
LDA $FC64,Y ; PRG:$3B35 Bytes:B9 64 FC
|
|
TAY ; PRG:$3B38 Bytes:A8
|
|
LDA $FC65,Y ; PRG:$3B39 Bytes:B9 65 FC
|
|
STA $F5 ; PRG:$3B3C Bytes:85 F5
|
|
LDA $FC66,Y ; PRG:$3B3E Bytes:B9 66 FC
|
|
STA $F6 ; PRG:$3B41 Bytes:85 F6
|
|
LDA $FC67,Y ; PRG:$3B43 Bytes:B9 67 FC
|
|
STA $F7 ; PRG:$3B46 Bytes:85 F7
|
|
LDA $FC68,Y ; PRG:$3B48 Bytes:B9 68 FC
|
|
STA $FA ; PRG:$3B4B Bytes:85 FA
|
|
LDA $FC69,Y ; PRG:$3B4D Bytes:B9 69 FC
|
|
STA $F9 ; PRG:$3B50 Bytes:85 F9
|
|
LDA $FC6A,Y ; PRG:$3B52 Bytes:B9 6A FC
|
|
STA $07F2 ; PRG:$3B55 Bytes:8D F2 07
|
|
LDA #$01 ; PRG:$3B58 Bytes:A9 01
|
|
STA $07EE ; PRG:$3B5A Bytes:8D EE 07
|
|
STA $07F0 ; PRG:$3B5D Bytes:8D F0 07
|
|
STA $07F1 ; PRG:$3B60 Bytes:8D F1 07
|
|
STA $07F3 ; PRG:$3B63 Bytes:8D F3 07
|
|
LDA #$7F ; PRG:$3B66 Bytes:A9 7F
|
|
STA SQ1_SWEEP ; PRG:$3B68 Bytes:8D 01 40
|
|
STA SQ2_SWEEP ; PRG:$3B6B Bytes:8D 05 40
|
|
AudioPathOnNonZero_FB6E:
|
|
DEC $07EE ; PRG:$3B6E Bytes:CE EE 07
|
|
BNE AudioPathOnNonZero_FBBD ; PRG:$3B71 Bytes:D0 4A
|
|
AudioPathLoop_FB73:
|
|
LDY $F8 ; PRG:$3B73 Bytes:A4 F8
|
|
INC $F8 ; PRG:$3B75 Bytes:E6 F8
|
|
LDA ($F6),Y ; PRG:$3B77 Bytes:B1 F6
|
|
BEQ UpdatePulse2OnZero_FB84 ; PRG:$3B79 Bytes:F0 09
|
|
CMP #$01 ; PRG:$3B7B Bytes:C9 01
|
|
BNE AudioPathOnNonZero_FB95 ; PRG:$3B7D Bytes:D0 16
|
|
LDA $10 ; PRG:$3B7F Bytes:A5 10
|
|
LSR A ; PRG:$3B81 Bytes:4A
|
|
BCC AudioPathLoop_FB73 ; PRG:$3B82 Bytes:90 EF
|
|
UpdatePulse2OnZero_FB84:
|
|
LDA $F3 ; PRG:$3B84 Bytes:A5 F3
|
|
AND #$1C ; PRG:$3B86 Bytes:29 1C
|
|
BNE AudioPathLoop_FB2B ; PRG:$3B88 Bytes:D0 A1
|
|
LDA #$00 ; PRG:$3B8A Bytes:A9 00
|
|
STA $F3 ; PRG:$3B8C Bytes:85 F3
|
|
JSR UpdatePulse1Routine_F9D3 ; PRG:$3B8E Bytes:20 D3 F9
|
|
STA SQ2_VOL ; PRG:$3B91 Bytes:8D 04 40
|
|
RTS ; PRG:$3B94 Bytes:60
|
|
AudioPathOnNonZero_FB95:
|
|
JSR ProcessAudioStateRoutine_FF41 ; PRG:$3B95 Bytes:20 41 FF
|
|
STA $07EE ; PRG:$3B98 Bytes:8D EE 07
|
|
TXA ; PRG:$3B9B Bytes:8A
|
|
AND #$3E ; PRG:$3B9C Bytes:29 3E
|
|
JSR ProcessAudioStateRoutine_F814 ; PRG:$3B9E Bytes:20 14 F8
|
|
BEQ AudioPathOnZero_FBAA ; PRG:$3BA1 Bytes:F0 07
|
|
LDY #$1F ; PRG:$3BA3 Bytes:A0 1F
|
|
STY $07EF ; PRG:$3BA5 Bytes:8C EF 07
|
|
BNE AudioPathOnNonZero_FBAF ; PRG:$3BA8 Bytes:D0 05
|
|
AudioPathOnZero_FBAA:
|
|
LDY #$00 ; PRG:$3BAA Bytes:A0 00
|
|
STY $07EF ; PRG:$3BAC Bytes:8C EF 07
|
|
AudioPathOnNonZero_FBAF:
|
|
LDX #$84 ; PRG:$3BAF Bytes:A2 84
|
|
LDA $07EE ; PRG:$3BB1 Bytes:AD EE 07
|
|
CMP #$10 ; PRG:$3BB4 Bytes:C9 10
|
|
BCS UpdatePulse2OnCarry_FBBA ; PRG:$3BB6 Bytes:B0 02
|
|
LDX #$82 ; PRG:$3BB8 Bytes:A2 82
|
|
UpdatePulse2OnCarry_FBBA:
|
|
STX SQ2_VOL ; PRG:$3BBA Bytes:8E 04 40
|
|
AudioPathOnNonZero_FBBD:
|
|
LDA $F3 ; PRG:$3BBD Bytes:A5 F3
|
|
AND #$1C ; PRG:$3BBF Bytes:29 1C
|
|
BEQ AudioPathOnZero_FBD1 ; PRG:$3BC1 Bytes:F0 0E
|
|
LDY $07EF ; PRG:$3BC3 Bytes:AC EF 07
|
|
BEQ UpdatePulse2OnZero_FBCB ; PRG:$3BC6 Bytes:F0 03
|
|
DEC $07EF ; PRG:$3BC8 Bytes:CE EF 07
|
|
UpdatePulse2OnZero_FBCB:
|
|
LDA $FF9A,Y ; PRG:$3BCB Bytes:B9 9A FF
|
|
STA SQ2_VOL ; PRG:$3BCE Bytes:8D 04 40
|
|
AudioPathOnZero_FBD1:
|
|
LDY $F9 ; PRG:$3BD1 Bytes:A4 F9
|
|
BEQ AudioPathContinue_FC04 ; PRG:$3BD3 Bytes:F0 2F
|
|
DEC $07F0 ; PRG:$3BD5 Bytes:CE F0 07
|
|
BNE AudioPathContinue_FC04 ; PRG:$3BD8 Bytes:D0 2A
|
|
UpdatePulse1Loop_FBDA:
|
|
LDY $F9 ; PRG:$3BDA Bytes:A4 F9
|
|
INC $F9 ; PRG:$3BDC Bytes:E6 F9
|
|
LDA ($F6),Y ; PRG:$3BDE Bytes:B1 F6
|
|
BNE AudioPathOnNonZero_FBED ; PRG:$3BE0 Bytes:D0 0B
|
|
LDY $F9 ; PRG:$3BE2 Bytes:A4 F9
|
|
INC $F9 ; PRG:$3BE4 Bytes:E6 F9
|
|
LDA ($F6),Y ; PRG:$3BE6 Bytes:B1 F6
|
|
STA SQ1_SWEEP ; PRG:$3BE8 Bytes:8D 01 40
|
|
BNE UpdatePulse1Loop_FBDA ; PRG:$3BEB Bytes:D0 ED
|
|
AudioPathOnNonZero_FBED:
|
|
JSR ProcessAudioStateRoutine_FF41 ; PRG:$3BED Bytes:20 41 FF
|
|
STA $07F0 ; PRG:$3BF0 Bytes:8D F0 07
|
|
TXA ; PRG:$3BF3 Bytes:8A
|
|
AND #$3E ; PRG:$3BF4 Bytes:29 3E
|
|
JSR ProcessAudioStateRoutine_F800 ; PRG:$3BF6 Bytes:20 00 F8
|
|
BNE AudioPathOnNonZero_FBFF ; PRG:$3BF9 Bytes:D0 04
|
|
LDX #$10 ; PRG:$3BFB Bytes:A2 10
|
|
BNE UpdatePulse1OnNonZero_FC01 ; PRG:$3BFD Bytes:D0 02
|
|
AudioPathOnNonZero_FBFF:
|
|
LDX #$06 ; PRG:$3BFF Bytes:A2 06
|
|
UpdatePulse1OnNonZero_FC01:
|
|
STX SQ1_VOL ; PRG:$3C01 Bytes:8E 00 40
|
|
AudioPathContinue_FC04:
|
|
LDY $FA ; PRG:$3C04 Bytes:A4 FA
|
|
BEQ AudioPathContinue_FC2B ; PRG:$3C06 Bytes:F0 23
|
|
DEC $07F1 ; PRG:$3C08 Bytes:CE F1 07
|
|
BNE AudioPathContinue_FC2B ; PRG:$3C0B Bytes:D0 1E
|
|
INC $FA ; PRG:$3C0D Bytes:E6 FA
|
|
LDA ($F6),Y ; PRG:$3C0F Bytes:B1 F6
|
|
JSR ProcessAudioStateRoutine_FF41 ; PRG:$3C11 Bytes:20 41 FF
|
|
STA $07F1 ; PRG:$3C14 Bytes:8D F1 07
|
|
CLC ; PRG:$3C17 Bytes:18
|
|
ADC #$FE ; PRG:$3C18 Bytes:69 FE
|
|
CMP #$0E ; PRG:$3C1A Bytes:C9 0E
|
|
BCC UpdateTriangleOnNoCarry_FC20 ; PRG:$3C1C Bytes:90 02
|
|
LDA #$0E ; PRG:$3C1E Bytes:A9 0E
|
|
UpdateTriangleOnNoCarry_FC20:
|
|
ASL A ; PRG:$3C20 Bytes:0A
|
|
ASL A ; PRG:$3C21 Bytes:0A
|
|
STA TRI_LINEAR ; PRG:$3C22 Bytes:8D 08 40
|
|
TXA ; PRG:$3C25 Bytes:8A
|
|
AND #$3E ; PRG:$3C26 Bytes:29 3E
|
|
JSR ProcessAudioStateRoutine_F818 ; PRG:$3C28 Bytes:20 18 F8
|
|
AudioPathContinue_FC2B:
|
|
LDA $F3 ; PRG:$3C2B Bytes:A5 F3
|
|
AND #$43 ; PRG:$3C2D Bytes:29 43
|
|
BEQ AudioPathContinue_FC64 ; PRG:$3C2F Bytes:F0 33
|
|
DEC $07F3 ; PRG:$3C31 Bytes:CE F3 07
|
|
BNE AudioPathContinue_FC64 ; PRG:$3C34 Bytes:D0 2E
|
|
LDY $07F2 ; PRG:$3C36 Bytes:AC F2 07
|
|
INC $07F2 ; PRG:$3C39 Bytes:EE F2 07
|
|
LDA ($F6),Y ; PRG:$3C3C Bytes:B1 F6
|
|
JSR ProcessAudioStateRoutine_FF41 ; PRG:$3C3E Bytes:20 41 FF
|
|
STA $07F3 ; PRG:$3C41 Bytes:8D F3 07
|
|
TXA ; PRG:$3C44 Bytes:8A
|
|
AND #$3E ; PRG:$3C45 Bytes:29 3E
|
|
BEQ AudioPathContinue_FC64 ; PRG:$3C47 Bytes:F0 1B
|
|
AND #$20 ; PRG:$3C49 Bytes:29 20
|
|
BNE AudioPathOnNonZero_FC55 ; PRG:$3C4B Bytes:D0 08
|
|
LDA #$02 ; PRG:$3C4D Bytes:A9 02
|
|
LDX #$00 ; PRG:$3C4F Bytes:A2 00
|
|
LDY #$28 ; PRG:$3C51 Bytes:A0 28
|
|
BNE UpdateNoiseOnNonZero_FC5B ; PRG:$3C53 Bytes:D0 06
|
|
AudioPathOnNonZero_FC55:
|
|
LDA #$00 ; PRG:$3C55 Bytes:A9 00
|
|
LDX #$02 ; PRG:$3C57 Bytes:A2 02
|
|
LDY #$08 ; PRG:$3C59 Bytes:A0 08
|
|
UpdateNoiseOnNonZero_FC5B:
|
|
STA NOISE_VOL ; PRG:$3C5B Bytes:8D 0C 40
|
|
STX NOISE_LO ; PRG:$3C5E Bytes:8E 0E 40
|
|
STY NOISE_HI ; PRG:$3C61 Bytes:8C 0F 40
|
|
AudioPathContinue_FC64:
|
|
RTS ; PRG:$3C64 Bytes:60
|
|
.byte $0C, $16, $20, $1C, $24, $12, $28, $08, $07, $F7, $FF, $00, $00, $93, $FC, $3F ; PRG:$3C65 Bytes:0C 16 20 1C 24 12 28 08 07 F7 FF 00 00 93 FC 3F
|
|
.byte $1C, $60, $07 ; PRG:$3C75 Bytes:1C 60 07
|
|
|
|
;------------------------------------------------------------
|
|
; Audio data with embedded sequence helper code
|
|
; CPU $FC78-$FFF9
|
|
; PRG $3C78-$3FF9
|
|
;
|
|
; Pass 1 recursively traced from verified entry roots in this region.
|
|
; Direct branches, jumps, and subroutine calls are decoded.
|
|
; Bytes not reached by that trace remain explicit .byte data.
|
|
;------------------------------------------------------------
|
|
|
|
AudioDataTables:
|
|
.byte $FB, $FE, $00, $00, $05, $FD, $3E, $1B, $4E, $07, $69, $FD, $3D, $00, $CA, $FD ; PRG:$3C78 Bytes:FB FE 00 00 05 FD 3E 1B 4E 07 69 FD 3D 00 CA FD
|
|
.byte $6E, $00, $AD, $FE, $27, $00, $CA, $FF, $15, $09, $1F, $42, $8C, $44, $4C, $84 ; PRG:$3C88 Bytes:6E 00 AD FE 27 00 CA FF 15 09 1F 42 8C 44 4C 84
|
|
.byte $44, $27, $42, $8C, $44, $4C, $84, $44, $2B, $43, $6A, $84, $AA, $92, $52, $02 ; PRG:$3C98 Bytes:44 27 42 8C 44 4C 84 44 2B 43 6A 84 AA 92 52 02
|
|
.byte $16, $4A, $02, $88, $02, $05, $00, $42, $84, $66, $4C, $84, $84, $60, $66, $44 ; PRG:$3CA8 Bytes:16 4A 02 88 02 05 00 42 84 66 4C 84 84 60 66 44
|
|
.byte $4C, $88, $84, $AA, $64, $6A, $A4, $A4, $64, $6A, $44, $4C, $88, $C4, $62, $AA ; PRG:$3CB8 Bytes:4C 88 84 AA 64 6A A4 A4 64 6A 44 4C 88 C4 62 AA
|
|
.byte $A2, $88, $48, $02, $08, $62, $02, $A2, $02, $21, $5B, $5A, $5B, $9A, $5A, $60 ; PRG:$3CC8 Bytes:A2 88 48 02 08 62 02 A2 02 21 5B 5A 5B 9A 5A 60
|
|
.byte $66, $44, $AE, $6A, $65, $64, $65, $A4, $5C, $64, $6A, $44, $AE, $6A, $63, $62 ; PRG:$3CD8 Bytes:66 44 AE 6A 65 64 65 A4 5C 64 6A 44 AE 6A 63 62
|
|
.byte $A2, $A2, $AE, $6E, $02, $2E, $6A, $02, $AA, $02, $27, $80, $E0, $E0, $E0, $E0 ; PRG:$3CE8 Bytes:A2 A2 AE 6E 02 2E 6A 02 AA 02 27 80 E0 E0 E0 E0
|
|
.byte $E0, $E0, $E0, $E0, $E0, $E0, $E0, $A0, $10, $10, $10, $10, $11, $42, $A6, $60 ; PRG:$3CF8 Bytes:E0 E0 E0 E0 E0 E0 E0 A0 10 10 10 10 11 42 A6 60
|
|
.byte $AA, $AA, $6C, $AA, $A6, $5E, $60, $A6, $84, $6A, $88, $88, $AE, $52, $02, $10 ; PRG:$3D08 Bytes:AA AA 6C AA A6 5E 60 A6 84 6A 88 88 AE 52 02 10
|
|
.byte $4E, $02, $88, $02, $45, $45, $C4, $00, $42, $A0, $5A, $A0, $A0, $66, $A2, $A0 ; PRG:$3D18 Bytes:4E 02 88 02 45 45 C4 00 42 A0 5A A0 A0 66 A2 A0
|
|
.byte $5A, $5A, $9A, $AA, $62, $AA, $AA, $A6, $48, $02, $08, $48, $02, $AE, $02, $00 ; PRG:$3D28 Bytes:5A 5A 9A AA 62 AA AA A6 48 02 08 48 02 AE 02 00
|
|
.byte $95, $0C, $8C, $02, $2E, $AE, $02, $22, $A2, $02, $42, $9A, $A0, $A6, $AA, $AC ; PRG:$3D38 Bytes:95 0C 8C 02 2E AE 02 22 A2 02 42 9A A0 A6 AA AC
|
|
.byte $AA, $A6, $A0, $A2, $AA, $84, $AA, $09, $53, $4F, $CC, $80, $E0, $E0, $E0, $E0 ; PRG:$3D48 Bytes:AA A6 A0 A2 AA 84 AA 09 53 4F CC 80 E0 E0 E0 E0
|
|
.byte $E0, $A0, $11, $10, $10, $10, $10, $42, $10, $10, $10, $10, $42, $10, $10, $10 ; PRG:$3D58 Bytes:E0 A0 11 10 10 10 10 42 10 10 10 10 42 10 10 10
|
|
.byte $11, $66, $0C, $04, $26, $0C, $04, $26, $0C, $04, $26, $0C, $04, $26, $0C, $04 ; PRG:$3D68 Bytes:11 66 0C 04 26 0C 04 26 0C 04 26 0C 04 26 0C 04
|
|
.byte $6A, $10, $08, $2A, $10, $08, $2A, $10, $08, $2A, $10, $08, $2A, $10, $08, $6A ; PRG:$3D78 Bytes:6A 10 08 2A 10 08 2A 10 08 2A 10 08 2A 10 08 6A
|
|
.byte $0E, $04, $2A, $0E, $04, $2A, $0E, $04, $2A, $0E, $04, $2A, $0E, $04, $6E, $12 ; PRG:$3D88 Bytes:0E 04 2A 0E 04 2A 0E 04 2A 0E 04 2A 0E 04 6E 12
|
|
.byte $08, $2E, $12, $08, $2E, $12, $12, $0E, $0E, $0C, $0C, $08, $08, $00, $5A, $60 ; PRG:$3D98 Bytes:08 2E 12 08 2E 12 12 0E 0E 0C 0C 08 08 00 5A 60
|
|
.byte $66, $6A, $44, $6A, $66, $60, $5C, $64, $6A, $6E, $48, $6E, $6A, $64, $62, $6A ; PRG:$3DA8 Bytes:66 6A 44 6A 66 60 5C 64 6A 6E 48 6E 6A 64 62 6A
|
|
.byte $44, $48, $4E, $48, $44, $6A, $66, $6E, $48, $4E, $18, $18, $16, $16, $12, $12 ; PRG:$3DB8 Bytes:44 48 4E 48 44 6A 66 6E 48 4E 18 18 16 16 12 12
|
|
.byte $0E, $0E, $60, $66, $88, $44, $A6, $60, $62, $64, $66, $6A, $A2, $6A, $8C, $4A ; PRG:$3DC8 Bytes:0E 0E 60 66 88 44 A6 60 62 64 66 6A A2 6A 8C 4A
|
|
.byte $89, $44, $6A, $8E, $4C, $88, $6E, $92, $50, $4E, $4C, $60, $62, $64, $66, $6A ; PRG:$3DD8 Bytes:89 44 6A 8E 4C 88 6E 92 50 4E 4C 60 62 64 66 6A
|
|
.byte $A7, $60, $66, $8C, $48, $84, $66, $A0, $62, $66, $6A, $68, $6A, $6E, $44, $48 ; PRG:$3DE8 Bytes:A7 60 66 8C 48 84 66 A0 62 66 6A 68 6A 6E 44 48
|
|
.byte $D6, $42, $44, $44, $6E, $92, $4C, $44, $44, $6A, $8E, $4C, $48, $66, $68, $6A ; PRG:$3DF8 Bytes:D6 42 44 44 6E 92 4C 44 44 6A 8E 4C 48 66 68 6A
|
|
.byte $6C, $6E, $48, $85, $01, $44, $6E, $44, $6A, $6E, $44, $44, $6E, $44, $60, $62 ; PRG:$3E08 Bytes:6C 6E 48 85 01 44 6E 44 6A 6E 44 44 6E 44 60 62
|
|
.byte $66, $6A, $68, $6A, $64, $66, $6A, $AE, $44, $49, $44, $6A, $6A, $44, $6A, $6A ; PRG:$3E18 Bytes:66 6A 68 6A 64 66 6A AE 44 49 44 6A 6A 44 6A 6A
|
|
.byte $44, $66, $66, $44, $66, $66, $6A, $64, $66, $6A, $6E, $44, $8C, $4A, $49, $00 ; PRG:$3E28 Bytes:44 66 66 44 66 66 6A 64 66 6A 6E 44 8C 4A 49 00
|
|
.byte $9A, $66, $A0, $66, $9A, $66, $A0, $66, $5C, $48, $46, $44, $6A, $62, $9C, $6A ; PRG:$3E38 Bytes:9A 66 A0 66 9A 66 A0 66 5C 48 46 44 6A 62 9C 6A
|
|
.byte $A2, $6A, $A2, $44, $AA, $44, $A6, $48, $AE, $48, $9A, $66, $A0, $66, $9A, $66 ; PRG:$3E48 Bytes:A2 6A A2 44 AA 44 A6 48 AE 48 9A 66 A0 66 9A 66
|
|
.byte $A0, $66, $9A, $66, $A0, $66, $9A, $66, $A0, $66, $9C, $6A, $A2, $6A, $9C, $6A ; PRG:$3E58 Bytes:A0 66 9A 66 A0 66 9A 66 A0 66 9C 6A A2 6A 9C 6A
|
|
.byte $A2, $6A, $66, $6E, $48, $66, $44, $4C, $62, $6A, $48, $62, $6A, $48, $66, $64 ; PRG:$3E68 Bytes:A2 6A 66 6E 48 66 44 4C 62 6A 48 62 6A 48 66 64
|
|
.byte $66, $68, $6A, $6E, $44, $66, $62, $61, $62, $44, $6A, $62, $44, $6A, $60, $44 ; PRG:$3E78 Bytes:66 68 6A 6E 44 66 62 61 62 44 6A 62 44 6A 60 44
|
|
.byte $66, $60, $44, $66, $5C, $6A, $64, $5C, $6A, $64, $66, $48, $6E, $66, $48, $6E ; PRG:$3E88 Bytes:66 60 44 66 5C 6A 64 5C 6A 64 66 48 6E 66 48 6E
|
|
.byte $62, $44, $6A, $62, $44, $6A, $60, $44, $66, $60, $44, $66, $5C, $6A, $64, $5C ; PRG:$3E98 Bytes:62 44 6A 62 44 6A 60 44 66 60 44 66 5C 6A 64 5C
|
|
.byte $6A, $64, $A2, $62, $27, $45, $67, $84, $AA, $60, $AE, $60, $84, $88, $62, $AA ; PRG:$3EA8 Bytes:6A 64 A2 62 27 45 67 84 AA 60 AE 60 84 88 62 AA
|
|
.byte $48, $84, $AE, $66, $84, $66, $88, $4D, $84, $44, $8C, $57, $8C, $4A, $48, $44 ; PRG:$3EB8 Bytes:48 84 AE 66 84 66 88 4D 84 44 8C 57 8C 4A 48 44
|
|
.byte $8E, $6A, $8C, $6A, $8E, $8C, $4A, $88, $6E, $44, $48, $00, $5B, $A0, $66, $44 ; PRG:$3EC8 Bytes:8E 6A 8C 6A 8E 8C 4A 88 6E 44 48 00 5B A0 66 44
|
|
.byte $6E, $6B, $84, $4C, $56, $54, $5D, $A2, $6A, $48, $6A, $67, $AE, $48, $8E, $5B ; PRG:$3ED8 Bytes:6E 6B 84 4C 56 54 5D A2 6A 48 6A 67 AE 48 8E 5B
|
|
.byte $A0, $66, $44, $6E, $6B, $84, $4C, $56, $4C, $5D, $A2, $6A, $48, $44, $67, $AE ; PRG:$3EE8 Bytes:A0 66 44 6E 6B 84 4C 56 4C 5D A2 6A 48 44 67 AE
|
|
.byte $48, $4C, $4E, $26, $2E, $08, $13, $00, $03, $57, $00, $00, $00, $D4, $00, $C8 ; PRG:$3EF8 Bytes:48 4C 4E 26 2E 08 13 00 03 57 00 00 00 D4 00 C8
|
|
.byte $00, $BD, $00, $B2, $00, $A8, $00, $9F, $00, $96, $00, $8D, $00, $85, $00, $7E ; PRG:$3F08 Bytes:00 BD 00 B2 00 A8 00 9F 00 96 00 8D 00 85 00 7E
|
|
.byte $00, $70, $01, $AB, $01, $7C, $01, $67, $01, $52, $01, $3F, $01, $2D, $01, $1C ; PRG:$3F18 Bytes:00 70 01 AB 01 7C 01 67 01 52 01 3F 01 2D 01 1C
|
|
.byte $01, $0C, $00, $FD, $00, $EE, $00, $E1, $01, $FC, $01, $C4, $04, $08, $10, $20 ; PRG:$3F28 Bytes:01 0C 00 FD 00 EE 00 E1 01 FC 01 C4 04 08 10 20
|
|
.byte $40, $18, $30, $05, $0A, $14, $28, $50, $1E ; PRG:$3F38 Bytes:40 18 30 05 0A 14 28 50 1E
|
|
;------------------------------------------------------------
|
|
; ProcessAudioStateRoutine_FF41
|
|
;
|
|
; Global:
|
|
; First-pass AudioDataTables entry point or directly called helper.
|
|
;
|
|
; Local:
|
|
; Exact semantic role is deferred to the semantic naming pass.
|
|
;
|
|
; Parameters:
|
|
; Zero-page pointers, object state, or PPU state; exact contract unresolved.
|
|
;
|
|
; Returns:
|
|
; Register and flag effects are defined by the decoded instructions.
|
|
;------------------------------------------------------------
|
|
ProcessAudioStateRoutine_FF41:
|
|
TAX ; PRG:$3F41 Bytes:AA
|
|
ROR A ; PRG:$3F42 Bytes:6A
|
|
TXA ; PRG:$3F43 Bytes:8A
|
|
ROL A ; PRG:$3F44 Bytes:2A
|
|
ROL A ; PRG:$3F45 Bytes:2A
|
|
ROL A ; PRG:$3F46 Bytes:2A
|
|
AND #$07 ; PRG:$3F47 Bytes:29 07
|
|
CLC ; PRG:$3F49 Bytes:18
|
|
ADC $F5 ; PRG:$3F4A Bytes:65 F5
|
|
TAY ; PRG:$3F4C Bytes:A8
|
|
LDA $FF34,Y ; PRG:$3F4D Bytes:B9 34 FF
|
|
RTS ; PRG:$3F50 Bytes:60
|
|
.byte $10, $15, $16, $16, $16, $15, $15, $17, $17, $17, $16, $16, $18, $18, $18, $16 ; PRG:$3F51 Bytes:10 15 16 16 16 15 15 17 17 17 16 16 18 18 18 16
|
|
.byte $16, $1A, $1A, $1A, $16, $16, $1C, $1C, $1C, $16, $16, $1E, $1E, $1E, $16, $16 ; PRG:$3F61 Bytes:16 1A 1A 1A 16 16 1C 1C 1C 16 16 1E 1E 1E 16 16
|
|
.byte $0A, $0A, $0A, $0A, $08, $08, $08, $08, $08, $08, $08, $08, $09, $09, $09, $09 ; PRG:$3F71 Bytes:0A 0A 0A 0A 08 08 08 08 08 08 08 08 09 09 09 09
|
|
.byte $09, $09, $07, $07, $07, $07, $07, $07, $07, $07, $08, $08, $08, $08, $08, $08 ; PRG:$3F81 Bytes:09 09 07 07 07 07 07 07 07 07 08 08 08 08 08 08
|
|
.byte $10, $11, $1C, $1A, $18, $16, $14, $12, $11, $50, $51, $51, $51, $51, $51, $51 ; PRG:$3F91 Bytes:10 11 1C 1A 18 16 14 12 11 50 51 51 51 51 51 51
|
|
.byte $51, $51, $52, $52, $52, $52, $52, $52, $53, $53, $53, $53, $53, $54, $54, $54 ; PRG:$3FA1 Bytes:51 51 52 52 52 52 52 52 53 53 53 53 53 54 54 54
|
|
.byte $54, $55, $55, $55, $56, $56, $56, $56, $57, $01, $01, $01, $BE, $01, $01, $01 ; PRG:$3FB1 Bytes:54 55 55 55 56 56 56 56 57 01 01 01 BE 01 01 01
|
|
.byte $8E, $00, $FE, $00, $00, $FE, $00, $00, $FE, $6B, $6B, $AA, $6F, $6F, $AE, $03 ; PRG:$3FC1 Bytes:8E 00 FE 00 00 FE 00 00 FE 6B 6B AA 6F 6F AE 03
|
|
.byte $05, $00, $00, $95, $5D, $49, $9C, $63, $4F, $A2, $03, $00, $9D, $27, $A2, $84 ; PRG:$3FD1 Bytes:05 00 00 95 5D 49 9C 63 4F A2 03 00 9D 27 A2 84
|
|
.byte $A2, $84, $A6, $88, $A6, $88, $03, $0D, $01, $01, $A0, $60, $00, $20, $A0, $60 ; PRG:$3FE1 Bytes:A2 84 A6 88 A6 88 03 0D 01 01 A0 60 00 20 A0 60
|
|
.byte $00, $20, $20, $20, $20, $21, $00, $4F, $0F ; PRG:$3FF1 Bytes:00 20 20 20 20 21 00 4F 0F
|
|
|
|
;------------------------------------------------------------
|
|
; VectorTable
|
|
; CPU $FFFA-$FFFF
|
|
; PRG $3FFA-$3FFF
|
|
; NMI, RESET, IRQ/BRK vectors
|
|
; Pass 1 preserves this range exactly with .incbin.
|
|
;------------------------------------------------------------
|
|
VectorTable:
|
|
.word NMIHandler ; PRG:$3FFA Bytes:F1 C1
|
|
.word ResetEntry ; PRG:$3FFC Bytes:96 C1
|
|
.word IRQHandler ; PRG:$3FFE Bytes:96 C1
|