Sakkhra Caves

Further work on the script extractor, thanks again to Vehek for his tips to transform font table indexes into ShiftJIS characters.

Tasks now:

  • Find out the routine termination sequence for the dialog codes
  • Extract dialog options from the dialog code, and find out how they are mapped to each conversation

This is the output for dialog 16, somewhere within the hex there should be a meaningful termination sequence

Dialog 16

Charset:  ????はいえ熱夢アイエラフキンジミーディスナウトヨルリテム名前仕事治す部族さようならおかり、バタ。ニャの魔法がにオド谷言葉を話力与た長間冒れてだもっくこやろる決し手放で弟子ち大き傷負倒発見へ連来ばわ中と呼んまず彼探出帰酋本当感謝ぞ村戦士総娘東あそ者耳入ほ仲精霊不思議居場所知教遠住石都西クカ恐ぬ道沿行け通じ南隠里約束誰突止め助ロ会聞チョコパ捧げ物強授ポ私目戻自分生ッ祈師つ今使必要ぐ我!ズ苦痛取除…機嫌丈夫ど友み報告加護

94 26 02 0B 8D 8D B1 90 AB B8 BC 02 BD 02 BE 02 BF 02 C0 02 C1 02 C2 02 C3 02 C4 42 B9 C5 02 C6 82 C7 82 C8 02 C9 82 CA C2 C4 A9 10 96 4D 8D 9A AD 00

おかえり、アバタール。

8C 2F 8E

インターニャの魔法が、お前にイーオドンの谷の言葉を話す力を与えた。

01 01

アバタールよ。お前は長い間、熱に冒されていたのだ。だが、もう、すっかりよくなった。

01

お前に、このトーテムをやろう。この谷にいる間は、決して手放すでない。

C0 A9 10 BE 8A 81 00 C9 B6 BC 82 96 F0 8E BE 01 82 00

インターニャの弟子たちが、大きな傷を負って倒れているお前を発見して、ここへ連れて来た。

01

インターニャ、お前の傷を治した。だが、しばらくは熱に冒されて、うわ言を言っていた。夢の話だ。

8C 2F 8E B6 BD 82 96 59 8F BE 02 83 84 85 00

お前は夢の中で、アイエラとラフキンとジミーの名を呼んでいた。まずは、彼らを探し出すことだ。

8C 2F 8E B6 BE 82 96 2E 90 BE 03 00 9B 87 00 96 BB 8F

お前がアイエラを連れて帰ってくれたことを、酋長は本当によろこんで感謝していたぞ。

8C 2B 90

この村の戦士たちが、総出でアイエラを探している。アイエラは酋長の娘なのだ。

01

アイエラをさらったのはウラリ族だ。

BE 89 00 8C 2F 8E B6 BF 82 96 DC 90 BE 04 88 00

この村の東にある、ヨラルー族の村に、そのような名前の者がいると、インターニャの耳に入っている。

01

ラフキン、ほかの仲間を探すのに、とても力になると、精霊たちは言う。

8C 2F 8E B6 C0 82 96 44 91 BE

?インターニャ、不思議な夢を見た。夢は、ラフキンが、ジミーの居場所を知っていると教えてくれた。

8C 2F 8E B6 C1 82 96 86 91 BE 06 00

とても遠くに住んでいる部族だ。石の都ナウアトラの西だ。

8C 2F 8E B6 C2 82 96 FD 91 BE 07 86 00

ナウアトラ族は、彼らの石の都を、ティクティカトルと呼んでいる。

01 01

ナウアトラの西には、ディスキキの村がある。

8C 2F 8E B6 C3 82 96 7A 92 BE 08 87 00

恐れを知らぬ戦士の部族だ。この村から道に沿って東へ行け。

01 01

道はヨラルーの村に通じている。その南が、ナウアトラだ。

8C 2F 8E B6 C4 82 96 5E 93 BE 09 00

ウラリ族は隠れ里に住んでいる。精霊たちも、その場所を教えてはくれない。

01

だが、精霊は約束してくれた。ぐかがかならず、ウラリの村を我き!ズ、アイエラを苦け出すとな。

01

アイエラを苦けたければ酋長のア痛痛ンに取って話を除け。

8C 2F 8E B6 C5 82 96 27 94 BE 0A 00

このトーテムに…機嫌ラトルか丈インドを夫ど友にすると、み力な魔法の力をお前に報けてくれる。

01

ヨ告を夫ど友にすると、お前を加の護の前に?してくれる。

01 01

このほかのトーテムは、??の力で探すのだ。

8C 2F 8E B6 C6 82 96 67 94 BE 0B 00

?まれたときから、ずっとインターニャと呼ばれている。

8C 2F 8E B6 C7 82 96 D5 94 BE 0C 00

クーラ?ク族の?とう?をしている。精霊の言葉を除き、傷?いた者や、熱に冒された者を治す。

9B AD 00 96 D2 94 BE 8D 81 00 8C 2F 8E B6 C8 82 96 3A 96 BE 0D 00 AE 24 1D 1D 25 1D 96 A2 95

加には、なんでも治す、大きな力がある。さいわい、?のお前には、その力を?う??がない。

01

もし、インターニャの苦けがいるときは、お前にやったトーテムを?い、す?に帰ってくるのだ。

9B AD 00 96 9F 95 BE 8A 00 8C 37 96 A2 1D 1D 25 1D

精霊よ、?に力を与えたまえ?

01 01 01

クク?の精霊よ、これなるアバタールの??を?り?き、その傷をいやしたまえ??

01

精霊の??はよかった。もう大??だ。

8C 2F 8E B6 C9 82 96 F7 96 BE 0E 00

インターニャは、?の部族にも?だちがいる。?んな、インターニャにいろいろ??してくれる。

01

ここはクーラ?ク族の村だ。酋長はア痛痛ン。まだ取ってないなら、あいさ??らいしておけよ。

8C 2F 8E B6 CA 82 96 29 97

精霊の??を?っているぞ、アバータール。

9A AD 00 88 B8 CB 82 CC 82 CD C2 B9 CE 02 CF 02 D0 02 D1 02 D2 02 D3 C2 9B 81 00 96 46 97 BE 88 00 9B B5 00 96 C9 98 9B B6 00 9B B7 00 AB 00 96 97 97

前仕事治す部族さ

01

ィようナなはらいおいおかり、ムバタウ。ームニ

8C C6 98 C2 B0 10 96 1F 98

ャの魔法よがムにィなオド谷ムさ

01

テウ言葉をキ話タウ。ーさ

01 01

ャの魔法ラはら前仕事治す部族、力与ムたバ長らな与間。ーな谷ーいニ

9A B7 00 9A B6 00 8C C6 98 9B B6 00 96 A8 98

がムにィよフキン冒いキれてら間だもンミ名話族ナっいくこバ間谷ニ

01 01

ううはやナンら前仕事治す部族、ろる葉をタ名ド族ナら決バ間谷ーいニ

8C C6 98

う話はう話はら前仕事治す部族さ

8C 0D 99

部よエラよしナタ手ウテウ、放もでミいー。間谷弟らテキ放いなム谷葉ーニ

C9 B6 CB 82 96 43 99 BE 01 00

子話ち名大よャのき治さ傷負よャのき治倒

9A B5 00 8C 0D 99 B6 CC 82 96 E7 9A BE 02 00

ャの魔法ラよ発見なオド谷ニタウへ話う話連来ばわ部ら発見て言葉ナバ間谷ニ

01 9B B6 00 9B B7 00 AB 00 96 39 9A

ャのき治よ発見ナ。をよ中とよ力アイはら呼力ムにんら前仕事治す部族よ放へまならずイ、谷彼タウ。ーニャの魔法よがムにィらャの魔法よ探出よ帰、放酋バム谷葉ーニ

8C E4 9A

本弟当て感与ら放い部族よ謝ぞて村彼戦族だなオド谷ニ

01 01

放い部族よ謝ぞはらャの魔法よ発見て言葉ナバ間。ーニ

01 01

士よ総ナらジミーデ弟がムにフキン間なよれてら娘リいな。間い。ーニ

BE 84 00 8C 0D

Advertisements

14 thoughts on “Sakkhra Caves

    1. Hi!!!

      Unfortunately I haven’t been able to resume working on this one… I put the progress online so that if anyone’s interested he can pick up and continue. I may work back on it after I finish Ananias and Lune.

      1. Did you figure out how to get variable width font to work in the game? If not, that would be the crucial step to make. You can post a Help Ad in romhacking.net if you need to, im sure someone can offer to help in that aspect. This way you can then do single hex value letters afterwards.

      2. Hmmm as far as I remember the main challenge that involved hardcore hacking would be replacing the current text rendering routine, based on big 2×2 tiles per character, to a single character one more suited for long english sentences. Surprisingly, text doesn’t seem to be compressed in the ROM, they probably didn’t see it as something needed.

        I never got to that part though, I remember I was working on something to extract the script from the ROM so that the translator could work on it, but I failed to decipher the meaning of the bytes that were between the sentences.

        I think I posted something there (on romhacking.net) back when I started the project, but as you might know they prefer answering to specific issues rather than shouting for general help 🙂

      3. Hey was talking to someone about the VWF font work and he said he will take a look at it this weekend. This will solve your 2×2 font problem by making it 1×2 instead 🙂 I will let you know what happens.

  1. Go to http://www.romhacking.net. You can post a help ad to ask someone to add in Variable Width Font in your game. That will solve your problem. Also post a forum topic in the board2 site. Someone might be able to help you out also there

  2. Hi, Mrrichard999 said that you looking to add a proportional font to this translation. I’ve read your posts and it looks like you were on the way to understanding how the dialogue works. I’m kinda having to figure it out too in order to find a good way to implement a new font drawing routine.

    Not sure if you’ve continued to examine it since your last post, but the game seems to use a lot of scripting codes mixed in with the dialogue. It also draws the letters that it needs in the beginning of these blocks. Hence that big random dump of letters at the top. The character values seem to be referenced relative to it.

    01 means a newline. The game also seems aware enough to put a button pause if the number of lines exceeds the window (4 lines of text).

    An example of a code would be the “8C 2F 8E” near the top. This is a jump that goes to $AC:8E2F in text. Which happens to be the “C9 B6 BC 82…” part near the top. This is likely positioned after the “Welcome back” text so it can jump straight to the dialogue options instead of repeating Intanya’s first dialogue.

    “C0 A9 10” sets a flag value in RAM to mark that you’ve already talked to him once.

    “BE” seems to mark off dialogue options somehow, which I’m currently looking at to figure out how it exactly works.

    Anything between “88” and “D0” is treated as a subroutine jump, so it may be necessary to log what each one does. So far, it seems like each one also uses the next 2 bytes. So basically, trios of bytes for special behavior.

    If I had to guess, “00” is how it ultimately ends a block of dialogue.

    I’ll continue to look at it to discover the best way to modifying the font drawing. One alternative might be to just convert the text to 8×8 chars, since there’s already a table with those chars in it. Then it’d just be a matter of loading the table into memory once, and just reference that. But I’m not sure how wordy the game is, or if it’ll need more space for things like inventory screens.

  3. Not sure if my first comment went through or not, but it was just saying that I think I’ve figured out some of those codes that are mixed in with the dialogue. They’re for jumping to different subroutines, and mostly seem to operate in trios of bytes.

    So for example, the “8C 2F 8E” after Intanya’s “Welcome back” line is for jumping straight to the dialogue options and bypassing his intro speech.

    I was messing around with the font drawing and it seems like the game actually already has built-in support for single-byte characters. I noticed this when it draws the copyright splash screen text and how it tries to check if an incoming character value is between 20 and 88.

    Though this only works out-of-the-box for the intro. If you try to use it in dialogue, the character set has already been swapped with kanji. But it still recognizes single bytes, and also seems like it may have the auto-newline functionality built in as well.

    I’m gonna try modifying the pointers that point to the kanji and have it load a font I drew from the PC version of Savage Empire instead.

    It won’t be a proportional font, but maybe cutting dialogue down to 8×8 tiles would still be a benefit. And of course, if you need even more space than what you’d get by replacing the 2-byte text with 1-byte, you can always just move it and have it read from somewhere else.

  4. And right after I wrote that last message, I think I’ve got it working. Here’s a sample pic.

    I guess without the proportional code, I’ll have to re-center the letters. But that was relatively painless to implement, which now makes me feel awkward for spending all those hours yesterday and today looking at it.

    The dialogue options may have to be reworked or moved, since I think even with doubling the byte space, you’ll need more room. (i.e. “Dream” would need 5 bytes but the single kanji uses 2)

    1. wow, your findings are pretty sweet!

      I think there’s been a slight misunderstanding about what I intended, I don’t think I ever wanted to do proportional fonts, but rather changing the text output routine so that it worked with single letter sprites instead of 2×2 sprites kanji; just getting that to work I think would be pretty cool.

      I’ll check your other messages tomorrow, and see if I can figure them out 🙂

      Edit: Just saw the screenshot.. Amazing!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s