News:

11 March 2016 - Forum Rules

Main Menu

Kanji array supporting dumper

Started by yugisokubodai, November 04, 2021, 09:42:38 AM

Previous topic - Next topic

yugisokubodai

I wonder is there any dumper out there which supports Kanji array?
Say, the game uses the Kanji trigger bytes as

0A=<kanji1>
0B=<kanji2>

Then we have
0A5E=王
0A5F=子

Then the Rom has this string: 0A5E5F
I'd like to dump it out as 王子, not 王<$5F>

It seems that Romjuice has this function, but it sucks.
兵法の勝ちを取りても
世の海を渡りかねたる
石の船かな

mziab

Maybe you should give abcde a spin. AFAIR it supports everything romjuice does and more.

FAST6191

Personally I would replace the flag, dump it twice with the differing tables and then merge relevant parts.

yugisokubodai

Quote from: mziab on November 04, 2021, 02:13:19 PM
Maybe you should give abcde a spin. AFAIR it supports everything romjuice does and more.
Thank you mziab. I gave it a try but I didn't find any Kanji array support in the document.
Btw I've coded the game to force write Kanji array to normal Kanji table, like 0A1234 will be force written to 0A12 and 0A34. This way I can dump the text correctly from Ram memory.
兵法の勝ちを取りても
世の海を渡りかねたる
石の船かな

Vehek

It doesn't work the same way as romjuice's kanji arrays, but I think you'd use the table switching function.
In this, alternate table entries don't include the trigger byte. Instead of 0A5E=王, the entry in the kanji table would be just 5E=王.

abw

Quote from: yugisokubodai on November 04, 2021, 07:37:42 PM
Thank you mziab. I gave it a try but I didn't find any Kanji array support in the document.
abcde's documentation refers to this as table switching rather than kanji arrays (since in general it has nothing to do with kanji, even though that's what some specific games might happen to use it for). It's not clear from your example how your game decides to switch from kanji back to the original table, but if it just keeps going until it can't match another byte, then using 2 table files should work:


@main
!0A=,<@kanji>:0



@kanji
5E=王
5F=子

yugisokubodai

This game uses multi Kanji tables, which triggers by 0A, 0B, 0C....
For example

0A00 = kanji table 1 entry 1
0A01 = kanji table 1 entry 2
0A02 = kanji table 1 entry 3
...
0B00 = kanji table 2 entry 1
0B01 = kanji table 2 entry 2

In Rom, if 2 or more Kanjis are the same table, the table trigger byte is stored once only. For example, 0B0400506 is equivalent to 0B04 0B05 0B06

Abcd is frustrating. I alread coded my own thing though.
兵法の勝ちを取りても
世の海を渡りかねたる
石の船かな

KingMike

Per game coding issues why I long ago just began making my own dumper/inserter programs, so they can do EXACTLY what they need to do.

But I realize that's not an option for a lot of people.
"My watch says 30 chickens" Google, 2018

abw

None of that sounds like a problem for abcde.

If someone is in a position where they're comfortable writing their own extraction and/or insertion utilities and prefers to do so, then I'm certainly not going to stop them :D.