These last weeks I've been messing around with Power Pro Kun Pocket 1, and I've found where the first dialogue that is displayed in the game is shown, and its pointer. I wanted to find the text routine, to try to understand better how it displays the text on screen, and to try to accommodate a fourth line of text on a textbox or a future VWF hack. (As an additional note, I figured some of the "events" that the text routine is able to read, like new lines of dialogue, changing text speed, displaying player name, using bold characters, among other stuff).
Examples of the textboxes.
The offset of the first dialogue (leftmost screenshot) is 0x54000, and its pointer is located in the same bank (15), at offset 0x541F5 (pointer is "00 40"). Text seems to be splitted between different banks, and at least for the first "cutescene", all the pointers are stored one after another (offsets from 0x541F5 to 0x541FF).
From this point, I haven't been able to find where the "code" that manages the text lies in the ROM. I've been trying to find said routine for more almost two weeks, with a very basic use of BGB's debugger (as I am not proficient with it).
Text is represented in 1 byte per character (I was able to create a table for it by modifying the values of the first dialogue) and some of the kanji are represented with 2 bytes ("FD XX", "FD 1D" being "今" as an example). There also are functions or "events" that take up to 2 or 3 bytes, that are used for managing the flow of the dialogue box, like:
"FE 0A": Text speed 1 (fastest).
"FE 0B": Text speed 2 (almost fastest).
"FE 00": Line break.
"FE 32": Wait 1 second to continue displaying text.
"FF FF": Next "cutescene" (change of background + continue from next pointer).
WindHex + table I created for the game.
I have been able to see that every time an "FF FF" instruction is read by the text routine ("FF FF" being like a "load next background from the index, then read the next pointer), Banks are changed back and forth as can be seen in the explanation below:
Any clues or possible ideas on how can I use the debugger to be able to pinpoint where the text routine is/is being loaded from? Or maybe the procedure I'm trying to follow is not the best one? I think that the text logic is stored at bank 56, as every time it needs to load a new resource, goes to bank 56 and changes to another bank (or as can be seen in the croquis above, when the user says "yes" to the creation of the character with these details, it goes from bank 6 to bank 56 and changes to 15 (where the first text for that cutescene is), and the same happens when loading the next cutescene).
Thanks in advance,