Guys, sorry I can take a couple days to get back. Full time job, full time dad, other obligations, etc. With something I find really unfamiliar and challenging like this, I need at least a couple hours to totally focus on what I'm doing, along with being in the right mental state. It's not like script and graphics stuff that I can work on in much smaller chunks of time or in a less than ideal condition.
But I have some great news to report.
Log comparsion is also a good approach, but logs should be as equal as possible to make it easier for you. Write Erdrick and move cursor to End or something, pause emulator and make a savestate. Then manually change the last character in ram to a different byte and save to another savestate while still paused. Don't unpause, disable breakpoints, load save, launch log, hold confirm button, press frame advance hotkey several times for tracer to do his stuff. Save log, and do the same with another savestate, then compare 2 logs. Search for where instructions begin to differ.
This advice from Cyneprepou4uk was extremely helpful. Thank you! I was able to use it to create logs that exactly matched other than the points of divergence. And voila, I found the code:
f15769 A:B7 X:00 Y:70 S:EC P:NvUBdIzC $BB26:20 FB BB JSR $BBFB
f15769 A:B7 X:00 Y:70 S:EA P:NvUBdIzC $BBFB:A2 00 LDX #$00
f15769 A:B7 X:00 Y:70 S:EA P:nvUBdIZC $BBFD:B5 09 LDA $09,X @ $0009 = #$29
f15769 A:29 X:00 Y:70 S:EA P:nvUBdIzC $BBFF:C9 00 CMP #$00
f15769 A:29 X:00 Y:70 S:EA P:nvUBdIzC $BC01:D0 07 BNE $BC0A
f15769 A:29 X:00 Y:70 S:EA P:nvUBdIzC $BC0A:C9 29 CMP #$29
f15769 A:29 X:00 Y:70 S:EA P:nvUBdIZC $BC0C:F0 05 BEQ $BC13
f15769 A:29 X:00 Y:70 S:EA P:nvUBdIZC $BC13:E8 INX
f15769 A:29 X:01 Y:70 S:EA P:nvUBdIzC $BC14:B5 09 LDA $09,X @ $000A = #$36
f15769 A:36 X:01 Y:70 S:EA P:nvUBdIzC $BC16:C9 36 CMP #$36
f15769 A:36 X:01 Y:70 S:EA P:nvUBdIZC $BC18:F0 05 BEQ $BC1F
f15769 A:36 X:01 Y:70 S:EA P:nvUBdIZC $BC1F:E8 INX
f15769 A:36 X:02 Y:70 S:EA P:nvUBdIzC $BC20:B5 09 LDA $09,X @ $000B = #$28
f15769 A:28 X:02 Y:70 S:EA P:nvUBdIzC $BC22:C9 28 CMP #$28
f15769 A:28 X:02 Y:70 S:EA P:nvUBdIZC $BC24:F0 05 BEQ $BC2B
f15769 A:28 X:02 Y:70 S:EA P:nvUBdIZC $BC2B:E8 INX
f15769 A:28 X:03 Y:70 S:EA P:nvUBdIzC $BC2C:B5 09 LDA $09,X @ $000C = #$36
f15769 A:36 X:03 Y:70 S:EA P:nvUBdIzC $BC2E:C9 36 CMP #$36
f15769 A:36 X:03 Y:70 S:EA P:nvUBdIZC $BC30:F0 05 BEQ $BC37
f15769 A:36 X:03 Y:70 S:EA P:nvUBdIZC $BC37:E8 INX
f15769 A:36 X:04 Y:70 S:EA P:nvUBdIzC $BC38:B5 09 LDA $09,X @ $000D = #$2D
f15769 A:2D X:04 Y:70 S:EA P:nvUBdIzC $BC3A:C9 2D CMP #$2D
f15769 A:2D X:04 Y:70 S:EA P:nvUBdIZC $BC3C:F0 05 BEQ $BC43
f15769 A:2D X:04 Y:70 S:EA P:nvUBdIZC $BC43:E8 INX
f15769 A:2D X:05 Y:70 S:EA P:nvUBdIzC $BC44:B5 09 LDA $09,X @ $000E = #$27
f15769 A:27 X:05 Y:70 S:EA P:nvUBdIzC $BC46:C9 27 CMP #$27
f15769 A:27 X:05 Y:70 S:EA P:nvUBdIZC $BC48:F0 05 BEQ $BC4F
f15769 A:27 X:05 Y:70 S:EA P:nvUBdIZC $BC4F:E8 INX
Breakpoint 0 Hit at $BC50: $000F:ECR---
This time I don't have to ask if this is the right stuff because I used it to replace the ERDRICK/erdrick comparison with ROTO/roto.
And it works, hallelujah!
But the best part wasn't the result, it was the feeling as if scales had fallen from my eyes when I analyzed the flow of code and actually understood what it was doing with the CMP and BEQ commands.
I'm sure i'll be drowning in confusion a thousand times over with this stuff as time goes on, but that epiphany feeling was huge. I really appreciate everyone's support through this process of discovery.
While entering a name, set read breakpoint to 0009, and forbid every location where it triggers. Then confirm entered name, and one of the new breakpoint hits is gonna be what you are looking for.
Cyneprepou4uk, I'm still very foggy on the forbid concept. I don't really understand what I would have plugged in as forbid breakpoints according to your method. What exactly is being forbidden? You say to forbid every location where it triggers? I really don't understand that at all, and a longer explanation would be appreciated so that I can use this technique in the future.
Which is why I'm not understanding what part of the process is there some miscommunication. Thinking we must be overlooking some basic part of the debugging procedure that Chicken Knife is getting tripped up on (and we take for granted).
And to answer this question, storall, the biggest problem for me was simply being confronted by appx 150,000 lines of almost completely unfamiliar code in trace logs with only the vaguest idea of what I was looking for. The comparison process where all the timing stuff matches was really helpful, but after finding what I wanted (essentially right before and after the first breakpoint trigger) the location of it seemed kind of obvious. It was a million miles away from obvious before I found it, so what can I say? Like most of the other things I've learned so far in romhacking, before you understand it, it seems impossible. And after you understand it, it seems kind of easy and you can't believe you found it so difficult.
Anyway, I think I want to take a look at the next thing: disabling the code that causes you to earn an extra 25% gold and experience from defeating monsters in the English version. To approach this, I imagine I would initiate the trace log recording exactly after defeating enemies and earning the reward, but more specificity there would probably help. I could probably set up matching trace logs between the Japanese and English versions for comparison purposes, although I wouldn't have the luxury of doing the save state thing for a perfect syncing of trace logs. Next, I'm not sure what the code would look like that does this, but I imagine some kind of arithmetic is involved. Any advice or tips would be helpful. If everyone remains feeling generous, I'd love a similar kind of support that helps me along with the investigative process without handing me the answer.
Thank you all again!