Global Messages as voice in AGS 2.72

Started by agentbauer, Tue 19/05/2009 21:01:57

Previous topic - Next topic

agentbauer

It might sound stupid, but I have a problem with the global messages.

I want the Narrator to say the global messages. But I don't know, how I can do this?

I already added the MP3 files named as NARR1, NARR2, etc. in the Speech folder. But I get only the text displayed....

Roger Wilco Rules
NEW HOMEPAGE: http://spacequestiv5.pytalhost.at
Space Quest IV.5 Version 3.00 is finally done, check it out:
http://www.bigbluecup.com/yabb/index.php?topic=40735.msg538357;boardseen#new

Khris

How are you making AGS display the text? Using Display?
AFAIK, only Say & dialog script lines can have voices.

agentbauer

Yes, for example.

DisplayMessage(500);

Well, that would be a problem, if there is no possibility to get the global messages as voice, I will have to use playsound(500);
But that is not a very satisfying solution....
Roger Wilco Rules
NEW HOMEPAGE: http://spacequestiv5.pytalhost.at
Space Quest IV.5 Version 3.00 is finally done, check it out:
http://www.bigbluecup.com/yabb/index.php?topic=40735.msg538357;boardseen#new

Trent R

Which is one reason CJ is updating the Audio system in the next version, but you would have to update to 3.2 when it comes out, and there must be some reason you're still stuck back in 2.72.


~Trent
To give back to the AGS community, I can get you free, full versions of commercial software. Recently, Paint Shop Pro X, and eXPert PDF Pro 6. Please PM me for details.


Current Project: The Wanderer
On Hold: Hero of the Rune

GarageGothic

#4
QuoteHow are you making AGS display the text? Using Display?
AFAIK, only Say & dialog script lines can have voices.

No, Display also supports voice. The question however, is whether DisplayMessage does.

First of all, have you managed to get narrator speech to play when using normal Display (not DisplayMessage) function? If not, you should try setting "game.narrator_speech = NARRATOR;" at the start of your game. Otherwise the game expects the player character to be the speaker and looks for his name in the audio files.

Now, as for global messages, MAYBE you could put "&1 " (and so on) at the beginning of the message itself, but as I said, I don't know if the DisplayMessage function supports audio and I don't have AGS 2.72 installed so  I can't check. But if that doesn't work, here's a workaround:

Code: ags
Display("&1 %s", Game.GlobalMessages[500]);


This should play the file NARR1.mp3 while displaying global message 500. If you number all the narrator's lines to correspond to the message numbers, you could write a small function to do this:

Code: ags
function DisplayNarrator(int message) {
  Display("&%d %s", message, Game.GlobalMessages[message]);
  }


Put that in the global script, import it in the global header, and then call it whenever you need to display/play a narrator message. E.g. "DisplayNarrator(500);"

agentbauer

I still use AGS 2.72 because the game I update was progammed in it.
And importing the game into AGS 3.00 was a mess.
So I stayed with AGS 2.72 for that game. My next will use the newest version.

@ GaraceGothic
Thats a good idea, I never tried this!
Thanks!
Roger Wilco Rules
NEW HOMEPAGE: http://spacequestiv5.pytalhost.at
Space Quest IV.5 Version 3.00 is finally done, check it out:
http://www.bigbluecup.com/yabb/index.php?topic=40735.msg538357;boardseen#new

SMF spam blocked by CleanTalk