tepples wrote:
...the called subroutine increases the program counter on the stack to skip the data after using it.
Yeah, that makes sense. I guess that's actually the most compact way to create arguments for a function.
Of course, Dragon Warrior IV is
not doing that:
Code:
1F:C52F:A9 00 LDA #$00
1F:C531:85 1F STA $001F = #$00
1F:C533:8D 0A 05 STA $050A = #$00
1F:C536:8D 0B 05 STA $050B = #$00
1F:C539:8D 08 05 STA $0508 = #$00
1F:C53C:8D 09 05 STA $0509 = #$00
1F:C53F:8D 13 05 STA $0513 = #$02
1F:C542:60 RTS
I'm don't know if those two JSRs ever get executed, they could be vestigial code, but they do indeed look like code and not data to me. (They both point to very valid looking subroutines, like the one above.) Also it certainly does use BRK elsewhere in a functional way (seems to happen when talking text is gradually appearing).