Jump to content

Home

Secret of Monkey Island - CD Talkie Edition Project


Espiox

Recommended Posts

For now mkspeech only supports mp3, but it is VERY easy to add other formats...

 

I think the remaining major task is to choose the correct line when the result is ambiguous.

See the missing.txt that is created for reference on what is not unique.

Link to comment
Share on other sites

  • Replies 383
  • Created
  • Last Reply

Another little update at the same URL. Now quotes are translated as well as \xFE\x08 is ignored.

 

Coverage is now up to 3946 lines!

 

There are not many real strings left now.

 

I haven't used cocomonk22 modified version which actually should increase the coverage even more as those lines with variables are separated.

Is it available somewhere? Or are there some detailed instructions which scripts to modify etc.? (Especially with redistribution in mind...)

Link to comment
Share on other sites

I haven't used cocomonk22 modified version which actually should increase the coverage even more as those lines with variables are separated.

Is it available somewhere? Or are there some detailed instructions which scripts to modify etc.? (Especially with redistribution in mind...)

 

Check your PMs.

Link to comment
Share on other sites

I haven't used cocomonk22 modified version which actually should increase the coverage even more as those lines with variables are separated.

Is it available somewhere? Or are there some detailed instructions which scripts to modify etc.? (Especially with redistribution in mind...)

Well. There is the speech project talkie patch. I guess, you can use that, if you remove all speech references from it before using the tools here.
Link to comment
Share on other sites

Well. There is the speech project talkie patch. I guess, you can use that, if you remove all speech references from it before using the tools here.

 

That's exactly what cocomonk22 sent me; a hack-only version of the MISP patcher.

Link to comment
Share on other sites

Without variables in the string table (with cocomonk22 et al. changes) it's now 4436 of 4573 available samples assigned.

 

I would call this a pretty neat coverage :)

 

The only real problem now are the false positive matches that are listed in the missing.txt....

Link to comment
Share on other sites

As said it would be good if there would be some volunteers that add the correct lines in mapping.txt. This is something *I* really don't want to do .....

 

If there is more than one volunteer, the work should be split up. Like line 1-2200 for person one and 2200-end for person two.

 

EDIT: You may want to edit the first posting, to reflect the current state of affairs.

Link to comment
Share on other sites

As said it would be good if there would be some volunteers that add the correct lines in mapping.txt. This is something *I* really don't want to do .....

I don't really understand what's to do here...

 

I've ran mkspeech.exe with this result:

 

Read 4573 entries.

Could not open mapping.txt

Could not find SLP_71_gh-room_9_1.mp3

Wrote 4121 samples, 1194 missing.

 

What I got is an mi1new.txt, a missing.txt and the monster.so3

 

What now?

Link to comment
Share on other sites

What I got is an mi1new.txt, a missing.txt and the monster.so3

 

What now?

 

Next step is to integrate the mi1new.txt into the original game files (make sure you have a backup...):

scummtr -cw -g monkeycdalt -if mi1new.txt -H

 

When putting the monster.so3 in the MI1 game folder and you run it via ScummVM you should hear voices (just to make sure everything works for you).

 

You will notice right from the beginning that there are some errors as "Hi!" as a string occurs multiple of times and thus there is no way(*) to automatically detect which "Hi!" is used.

 

When you look at the "missing.txt" you should see something like:

Multiple hits for line "Hi!": HRM_80_fort_25_1.mp3 - Add  584,0=975 to mapping.txt
Multiple hits for line "Hi!": GUY_38_lookout_28_1.mp3 - Add  584,0=2306 to mapping.txt
Multiple hits for line "Hi!": HRM_20_main-beach_48_1.mp3 - Add  584,0=2604 to mapping.txt
Multiple hits for line "Hi!": GUY_20_main-beach_58_1.mp3 - Add  584,0=4134 to mapping.txt

 

Probably four times.

So it's about finding out, which "Hi!" is the correct in all the four places.

 

When adding "584,0=4134" to mapping.txt, the next call of "mkspeech" should pick the last sample for that particular line (not sure if this is the right association - this is just an example).

 

Finally you need to call scummtr again, to integrate the new text file (and make sure to use the new moster.so3 too).

 

P.S.:

I think a little problem occurs depending on the version we use as the patches from cocomonk22 change the order of strings a bit.

I haven't put any thought on how to make it a bit more robust in that regard....

But if the version is defined properly for the file, it will not be hard to convert it later...

 

(*) There might be a way, but it would probably involve modifying (or rebuilding) scummtr to get the room ids. Unfortunately I have not found the source code for scummtr so this does not seem to be an option..... well having scummtr source would also allow to build a single application that performs ALL steps :-(

Link to comment
Share on other sites

Would it be possible to offer this thing as a "patch"? That way only people who own the SE will be able to pull this off, and there's no piracy involved (which would occur when sharing the actual speech files). Maybe a batch-file that pulls the speech files out of the SE's PAK, converts them accordingly (and possibly combines split lines into a single file) and re-inserts them into the CD-version of the game using ScummSpeaks.

 

This would allow to share this project without running into legal trouble.

 

that would be great if you could do that. It would help people (Especialy Me) to not have to buy a new one.

Link to comment
Share on other sites

that would be great if you could do that. It would help people (Especialy Me) to not have to buy a new one.

 

Yes, we're going to offer this as a patch... but what do you mean "not have to buy a new one"?

Link to comment
Share on other sites

that would be great if you could do that. It would help people (Especialy Me) to not have to buy a new one.

 

Well actually that's the aim. For now the only thing needed is MISE, as it contains the original enhanced CD version.

 

With my both tools unxwb-mi and mkspeech (maybe I'll integrate the relevant unxwb part in mkspeech at a later point), it's already possible to get a basic speech version of the classic enhanced MI version. The mapping file also is unproblematic to redistribute.

 

And finally a batch file that is being worked on by Espiox will make it hopefully relatively easy to generate your own version without many manual steps.

 

I think the only problem are the patches by cocomonk22, where I am not sure on what their legal status is and if they can be redistributed freely.

Link to comment
Share on other sites

I get a problem when I disable the subtitles: Those multi-part lines don't work anymore... only the first part is played.

 

Also some lines overlap (for example when talking to the one-eyed pirate in the Scumm Bar).

 

Edit:

And sorry, I still don't get how to put together a "mapping.txt". This is how the first few lines of my missing.txt look like:

 

Missing "jungle", add 1,0=sampleno
Missing "rowboat and oars", add 2,0=sampleno
Missing "jungle", add 3,0=sampleno
Missing "jungle", add 4,0=sampleno
Missing "jungle", add 5,0=sampleno
Multiple hits for line "It's a gross old bottle.": GUY_1_beach_1_1.mp3 - Add  6,0=228 to mapping.txt
Multiple hits for line "It's a gross old bottle.": GUY_1_beach_1_1.mp3 - Add  6,0=230 to mapping.txt
Multiple hits for line "I don't want it.": GUY_1_beach_1_2.mp3 - Add  6,1=229 to mapping.txt
Multiple hits for line "I don't want it.": GUY_1_beach_1_2.mp3 - Add  6,1=231 to mapping.txt
Multiple hits for line "I don't want it.": GUY_30_store_38_2.mp3 - Add  6,1=3923 to mapping.txt
Multiple hits for line "I don't want it.": GUY_30_store_58_1.mp3 - Add  6,1=3953 to mapping.txt
Multiple hits for line "I don't want it.": GUY_30_store_62_1.mp3 - Add  6,1=3964 to mapping.txt
Missing "bottle", add 7,0=sampleno
Missing "note", add 8,0=sampleno
Missing "Herman Toothrot", add 9,0=sampleno
Missing "beach", add 13,0=sampleno
Missing "beach", add 14,0=sampleno
Missing "crack", add 15,0=sampleno

 

So, the first 5 entries are probably lines, that aren't spoken but only text. So I don't add them to the mapping.txt, because they don't need to be associated with any audio-files, right?

 

The 6th entry is looking for the correct "It's a gross old bottle"-audio, but since those are obviously linked to the same audio-file, I just pick on of them and add 6,0=228 to the mapping.txt. Entry 6,1 (I guess ",1" is the response when trying to "pick it up") is looking for the correct "I don't want it", which should be a little easier, since I know it's said by Guybrush on the beach. So I'll add 6,1=229 to the mapping.txt, since that's the correct Guybrush line.

 

But what if I don't know where that line occurs? How am I supposed to know, which sample is the correct one? (Okay, sometimes the surrounding lines give clues about the place, as do the name of the audio-files)

 

And, do I only have to add stuff to the mappings.txt that's listed as "multiple hits" in the missing.txt?

Link to comment
Share on other sites

Why can't the patches I made be redistributed freely?

 

Oh I did not say that. I just wondered if there is an "official" place for them as it seems to be a bit... hidden... please if there are no objections, we should put all relevant links in the first posting.

 

I get a problem when I disable the subtitles: Those multi-part lines don't work anymore... only the first part is played.

 

Hmm that's bad... I am not sure if there is a way to fix it.

I guess we could either go back to merging the samples (which would bring the text and speech out of sync....), look if ScummVM would accept a patch that fixes this behavior or modify the game code so that only single lines are used.... (or find out if the tag field might be useful here too)

 

Also some lines overlap (for example when talking to the one-eyed pirate in the Scumm Bar).

 

Yes, I noticed that too. Not sure what to do here either. Maybe the "tags" field can be used to prevent this?!

 

So, the first 5 entries are probably lines, that aren't spoken but only text. So I don't add them to the mapping.txt, because they don't need to be associated with any audio-files, right?

 

Right. Those can be ignored.

 

But what if I don't know where that line occurs? How am I supposed to know, which sample is the correct one? (Okay, sometimes the surrounding lines give clues about the place, as do the name of the audio-files)

 

First: The second number ".,X=..." is used to determine the section when there are multiple lines in one row. Like "Hi!" "My name is Guybrush Threepwood!"

 

And yes, the main task is to find out where a line is said and which is the correct one. For some the context might give a hint, for other there is probably no other way but playing the game to the point where it is said.

 

And, do I only have to add stuff to the mappings.txt that's listed as "multiple hits" in the missing.txt?

 

In theory, yes. There might be fields with a missing sample where the proper sample exists and has to be determined.... but I think it should not happen that often.

 

I would say the priority should be to find the right matches for the ambiguous lines, as those are also the ones which will sound *wrong*. When there is no sample played it's not as strange as when the wrong one is played ....

Link to comment
Share on other sites

I think there's more problems... even with the subtitles on, the timing in some scenes is completely off, for example with the Fettucini Brothers.

 

Hmm strange, this particular scene seems to work fine here.

I'm using the latest SVN build of ScummVM btw....

 

Anyway, if somebody has some inside knowledge of the exact tag definition that (s)he is willing to share, we could probably fix some of the problems....

Link to comment
Share on other sites

Hmm strange, this particular scene seems to work fine here.

I'm using the latest SVN build of ScummVM btw....

 

Anyway, if somebody has some inside knowledge of the exact tag definition that (s)he is willing to share, we could probably fix some of the problems....

 

Probably not what you're asking, but I know how lip-synch tags are stored in SCUMM V5.

 

Warning! Techno-babble ahead

 

Tags are 16-bit words stored in big-endian format.

 

Text:

Ignoring the \xFF\x0A bits, your first four values are four bytes for the speech offset (little-endian), and the last four values are four bytes (little-endian) representing the number of lip-synch tags as modified by this formula:

 

(numtags << 1) + 8

 

e.g. To play a sample at offset 0x1234 with 2 lip-synch tags:

 

\xFF\x0A\x34\x12\xFF\x0A\x00\x00\xFF\x0A\x0C\x00\xFF\x0A\x00\x00

 

 

Compressed MONSTER.SOU:

The number of tags are stored for each sound, as part of the table at the start of the file. The tags themselves are written before the MP3/OGG/FLAC data (e.g. for a sound at 0x1234 with two tags, 0x1234 to 0x1238 stores the tags, and 0x1238 onwards stores the sound data).

 

 

Tag format:

Each tag is just a time position in the sound file being played (I'm not sure what measurement the position is in, maybe milliseconds, maybe not). Whenever the next tag's position is encountered, the talking animation is toggled on or off.

 

e.g. if there are three tags, with values 120, 240, 640, the animation timeline will play like this:

0-120: talking

120-240: not talking

240-640: talking

640-end: not talking

 

 

I think one problem is that the old SCUMM games did not support multiple speech sounds per line. Check Indiana Jones and the Fate of Atlantis, and I'm sure you'll find that all multi-line speech just uses the one sound file, and the subtitles are frequently out of synch with the sound.

 

Sorry I'm late to the party!

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.


×
×
  • Create New...