Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: Le Woltaire on Mon 26/02/2007 06:51:17

Title: Auto number speech file for translations
Post by: Le Woltaire on Mon 26/02/2007 06:51:17
Hi,

I'm making a voice acting for one of my games.
All my games are written in german.
But I want to make a voice acting for the english translation.
So I add the "&number" at the beginning of each translated dialogue line in the translation source.

This works quite well, but is a bit...let's say annoying, with over 4000 numbers to add...

Is there a possiblility to auto number the translated speechlines in the translation source? Or could this be added for future versions because it could help to make voice packs for foreign languages and also help developers, who don't create their game in english.
Title: Re: Auto number speech file for translations
Post by: Pumaman on Mon 26/02/2007 19:06:10
The easiest thing to do is to use the "Auto-number speech files" option, and then generate the translation source afterwards.

This will mean that your original German texts have te &number in them too, but if there is no speech file they'll just be ignored.
Title: Re: Auto number speech file for translations
Post by: Le Woltaire on Mon 26/02/2007 20:31:11
Well, I didn't get exactly what you mean...

My situation is this:

-The game was made in german.
-Then it was released and translated into english by another person.
-So I have a already finished translation file.
-Now I would like to make a english voice acting afterwards.
-If I use the "auto-number speech file" option I have to update my already finished translation source.
-This means I lose all english dialogue and have to recopy it into the txt file
-I'm looking for a possibility to update a translation source just by adding "&number" at the beginning of any ENGLISH dialogue line.
-I wouldn't mind if it would also include the german lines...
-But I guess I have to add them by hand...
Title: Re: Auto number speech file for translations
Post by: Pumaman on Mon 26/02/2007 20:40:04
I'm sure somebody here with a bit of perl wizardry could create you a script that adds a &number to every other line...
Title: Re: Auto number speech file for translations
Post by: Le Woltaire on Tue 27/02/2007 16:17:31
I just found someone, who writes a PERL script for my problem, so never mind...
Thank you.
Title: Re: Auto number speech file for translations
Post by: strazer on Tue 27/02/2007 16:49:33
When it's finished, would you mind uploading the script here for anyone with the same problem?
Title: Re: Auto number speech file for translations
Post by: jkohen on Thu 01/03/2007 20:04:49
Hi, I created a small Perl script to add audio indexes to game translations. You can find it at the Spectral Adventures forums (http://www.razyboard.com/system/morethread-addingdubindexestotranslations-le_woltaire-1740405-4320824-0.html).

Now, reading the full thread I have a better idea... if you could use AGS's autonumbering to create a blank translation, then it would be trivial to use Perl to fill-in the blank stub with the translated text you already have. I think this would be more useful and give better results, as the script wolud know what character is saying what (and, LW, you know why this would be very interesting), wouldn't it?.

Can we try that?
Title: Re: Auto number speech file for translations
Post by: Le Woltaire on Thu 01/03/2007 20:58:46
Sure.
I'm absolutely interested.

I thought it would be more complicated to make a script in PERL that uses a blank translation source and recopies finished material of an already existing one.

Especially because the finished translation source has been updated a dozen of times. So nothing is really at the right position...

But perhaps I'm wrong...
The PERL script has to compare the German lines and add the English lines to the right position in the blank translation source under the specific German lines and add the voice number at the beginning.

This is only useful if the speechref txt that I get from AGS gets modified in the same way I think. Because I only see German lines and their characters in the speechref
but as my voices are English it would be easier for me if I could see the characters name and the English speech in the summary.

Otherwise if I just work with the numbered translation source I will confuse with too many same numbers and I'd prefer if every speech number only appeared once.

(Besides of that I couldn't autonumber my speech file because AGS always used to crash in the middle of the process when I tried. But now I made another test and it suddenly worked.)

But you're right blashyrkh: Our heuristic approach to filter all parser related words out of the numbering progress was pretty complicated...let's make another email session about this or maybe we can discuss it here or at my forum to improve the script...
Title: Re: Auto number speech file for translations
Post by: Le Woltaire on Thu 01/03/2007 21:32:49
I have to correct myself:

I cannot finish the autonumbering process.
AGS crashes after numbering some rooms.
I get a unfinished speechref file.

But: I have to use AGS v2.62 at the moment because I failed to update my games into newer versions. Perhaps it's a version related problem...So it's unnecessary to concern about this.

I will go on with the numbered translation file. So our heuristic script was useful after all, at least for me...

A big thanks to blashyrkh for everything from my side.
In my opinion he's the best software developer of north eastern Argentinia between N58°/N60° and W34°/W35°.
Title: Re: Auto number speech file for translations
Post by: jkohen on Thu 01/03/2007 21:40:18
Hey, I'm flattered. That's a pretty big area if you think about it. I think most of it falls in the ocean, though. I heard dolphins are very clever. Do we have dolphins here? I think not, fortunately.

By the way, Argentina lies South from the Ecuator :)
Title: Re: Auto number speech file for translations
Post by: Le Woltaire on Thu 01/03/2007 21:49:19
Oh...
I have a big world map above my head were I'm working right now.
I misread some info from there.
I guess it's something like -N58°/-N60° and -W34°/-W35° I meant...
There you see how dumb I am.
I even don't understand how our planet works.
Title: Re: Auto number speech file for translations
Post by: jkohen on Thu 08/03/2007 21:32:44
I just wrote a cool Perl script to ease dubbing your translated games.

If you decide to add voices to your game after it's been translated, I'm told the translations stop to work, or you can't easily create dubs, or your pet dies. This script automates the process of merging old translations with new translation templates containing dub indexes. It also translates your speechref files, for easier reference.

Let me know what you think, or if you find bugs or something nasty.

Please see it at the Spectral Adventures forums (http://www.razyboard.com/system/morethread-dubtranslator-le_woltaire-1740405-4343398-0.html).

PS: It won't resurrect dead pets.