Ugh, IDA, why are you ignoring the data bank register in this disassembly?? Maybe half the memory references in my disassembly are completely bogus because IDA "helpfully" mapped them into memory, but in the completely wrong place...
I gave up and split the auto-generated WRAM segment from $7E0000-$7FFFFF into two segments from $7E0000-$7EFFFF and $7F0000-$7FFFFF. This way I can automatically fix references into the second bank instead of rewriting them all manually, and IDA will even keep track of the RAM address's name if/when I name them.
I also threw together a small tool for testing how dialogue will look before inserting it in-game!
You can play around with it here, if you'd like:
https://raspberry.rosenthalcastle.org/itadaki-street-2/bigtext-vwf.php
Well, I found which memory address is used for indexing which dialogue line is spoken by AI players.
Unfortunately, because I didn't finish tagging things in my disassembly, I can't cross-reference where the breakpoint I set fired with it, because that section of code is untagged...
I guess I know what I'll be doing today.
Oh wow, this is neat.
So, when choosing AI characters you can play against, there are actually two different lines that can appear! I didn't notice that there were multiple lines until I was reading through what @WTCGames@twitter.com had translated so far.
If you choose most characters, you get the first line ("Player # will be ____, right?")... but if you choose Konomi, you get the second ("I'll join as player #, alright?")
I guess Konomi really does host the whole game!
When IS2 draws a dialogue box on screen, it uses a particular 3-byte memory address for loading the window parameters from; and since all window parameters are in the same bank, it never updates the bank byte in that address.
I've moved all my custom code out into a new bank, though, including window parameters, so I have a hack in place that saves, replaces, and restores that bank byte when it loads custom text...
@Raspberryfloof That does look like a considerable improvement.
@Raspberryfloof is that a... 23 bit computer?
@Fuego It's the Super Nintendo! ^^
This is completely wrong! "word_7Fxxxx" should be "word_00xxxx" (or "word_7Exxxx", since memory is mirrored there for the first 0x8000 bytes).
I don't look forward to fixing all these auto-generated references...
https://awoo.space/media/FKxqWOjNoopvGWMinVE