Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
Talahaski
Enchanter


Joined: 10 Oct 2000
Posts: 656
Location: USA

PostPosted: Sat Apr 19, 2008 11:02 pm   

mudreader
 
Does anybody have an alternative to the mudreader that will work with CMUD?
_________________
Talahaski


dartmud.com 2525
Reply with quote
Dharkael
Enchanter


Joined: 05 Mar 2003
Posts: 593
Location: Canada

PostPosted: Sun Apr 20, 2008 1:01 am   
 
Roll your own using the ActiveX Object Sapi.SpVoice
The interface is described here
If you already have mudreader you probably have the necessary DLLs to make it work.
If not download the Microsoft Text-to-Speech Package

Code:
#var sapi %comcreate("Sapi.SpVoice")
#call @sapi.Speak("Stuff and Junk")

It doesn't sound very good out of the box but if you read the first link I gave you can probably tune it till it sounds better.

Good luck.

EDIT:
You'll probably want to change the call to @sapi.Speak to an asynchronous call, that way you're session is not blocked waiting for the voice to finish speaking.
Change the call to Asynchronous by passing 1 as the second param to the Speak method.
_________________
-Dharkael-
"No matter how subtle the wizard, a knife between the shoulder blades will seriously cramp his style."
Reply with quote
Talahaski
Enchanter


Joined: 10 Oct 2000
Posts: 656
Location: USA

PostPosted: Sun Apr 20, 2008 10:56 pm   
 
When i call the alias I get a floating point error


alias xSpeak
Script:
#var sapi %comcreate("Sapi.SpVoice")
#call @sapi.Speak(%params)

I made sure i had all the text to speech stuff installed.
_________________
Talahaski


dartmud.com 2525
Reply with quote
Dharkael
Enchanter


Joined: 05 Mar 2003
Posts: 593
Location: Canada

PostPosted: Sun Apr 20, 2008 11:21 pm   
 
What do you get when you enter this at the command line?
Code:
#var sapi %comcreate("Sapi.SpVoice")
#call @sapi.Speak("Test",1)
_________________
-Dharkael-
"No matter how subtle the wizard, a knife between the shoulder blades will seriously cramp his style."
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Sun Apr 20, 2008 11:31 pm   
 
You don't need to make the connection every time, too. Change the first line to

#if (!@sapi) {#var sapi %comcreate("Sapi.SpVoice")}

or remove it.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Talahaski
Enchanter


Joined: 10 Oct 2000
Posts: 656
Location: USA

PostPosted: Sun Apr 20, 2008 11:40 pm   
 
That worked. I changed the alias to include the ,1


#var sapi %comcreate("Sapi.SpVoice")
#call @sapi.Speak(%param,1)

Thanks for all the help!
_________________
Talahaski


dartmud.com 2525
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net