How to make custom subtitles in a mod ?

Avatar
NykO18
183 Posts
Posted Feb 20, 2008

Ok, here's the story.
I'm making a single player mod based on Portal. I'm somewhere near the end of the development and I'm now trying to implement voices in it. I already managed to make the voices, the game sound manifest file, with all the Game Sounds entries, I did some VCDs with FacePoser, and everything works perfectly in-game. I even managed to do some internationalization, with french and english voices depending on your Steam account's language.

But there's a problem : there's absolutely no subtitles when the VCDs are playing. I have a closecaption_english.txt in the resource directory of the mod that looks like this :

"lang"
{
   "Language" "english"
   "Tokens"
   {
      "mymod.level_01_welcome-1" "Here are my damn subtitles"
   }
}

But it does nothing.
All I know is that the captions are found by the game, because if I delete it, I get an error in the console saying that the caption was not found for "mymod.level_01_welcome-1". I also checked that subtitles were working, and it's the case. Portal voices are dubbed, but not mines.

So... well...
If someone have an idea, feel free to share.

PS: Here is the GameSound entry :

"mymod.level_01_welcome-1"
{
   "channel"      "CHAN_VOICE"
   "volume"      "1.0"
   "soundlevel"   "SNDLVL_NONE"
   "wave"         "vo/speaker/level_01_welcome-1.wav"
}

And the VCD file :

actor "Aperture_AI"
{
   channel "audio"
   {
      event speak "mymod.level_01_welcome-1"
      {
         time 0.283333 4.171020
         param "mymod.level_01_welcome-1"
         fixedlength
         cctype "cc_master"
         cctoken ""
      }
   }
}
Advertisement
Registered users don't see ads! Register now!
Avatar
NykO18
183 Posts
Posted Feb 20, 2008
Replied 1 hour later
Hm, Ok.
Someone on Steampowered.com explained that captions must be compiled in order to be displayed in the game.
This page explains what to do : http://developer.valvesoftware.com/wiki/Closed_Captions

But unfortunately, captioncompiler.exe keeps crashing, regardless of the method I use to compile. I'm wondering if it's compatible with the Beta SDK, if not, I think it will soon become a real pain in the a** to use Hammer with the Beta SDK, then restart steam, delete the Beta, compile the captions and redownload the Beta, over and over.

Avatar
rellikpd
1,053 Posts
Posted Feb 20, 2008
Replied 1 hour later

NykO18 wrote:

i was going to offer to try to compile them for you. i just downloaded the compiler... and ran it.. and it crashed so.. nevermind

Avatar
NykO18
183 Posts
Posted Feb 21, 2008
Replied 13 hours later

rellikpd wrote:
i was going to offer to try to compile them for you. i just downloaded the compiler... and ran it.. and it crashed so.. nevermind

Are you using the Beta SDK ?
Because if not, that could be a little problem..
Voica-acting is good, but when english is not your mother tongue, captions are always a plus. Damnit, I hope they'll fix this before my mod's development finishes.

Avatar
Hurricaaane
189 Posts
Posted Feb 23, 2008
Replied 2 days later
Add -engine ep1 to your source SDK configuration and try again. It works with me, but Friends Network just crashed before I could tell you.
Avatar
NykO18
183 Posts
Posted Mar 24, 2008
Replied 30 days later
There we are !
The Orange Box captioncompiler.exe was released with the March 24th update of the SDK.
And it seems to work perfectly, thanks Valve.
Advertisement
Registered users don't see ads! Register now!
Avatar
rellikpd
1,053 Posts
Posted Mar 24, 2008
Replied 43 minutes later

NykO18 wrote:
There we are !
The Orange Box captioncompiler.exe was released with the March 24th update of the SDK.
And it seems to work perfectly, thanks Valve.

WORD TO YOUR MOTHER!