<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE muclient>
<!-- Saved on Saturday, November 05, 2005, 8:53 PM -->
<!-- MuClient version 3.68 -->

<!-- Plugin "jfw" generated by Plugin Wizard -->

<muclient>
<plugin
   name="sapi"
   author="Tyler Spivey"
   id="f4a3e103c1d8715efa157b25"
   language="VBscript"
   purpose="speaks incoming text using sapi."
   date_written="2005-11-05 20:53:14"
   requires="3.68"
   version="1.0"
   >

</plugin>


<!--  Get our standard constants -->

<include name="constants.vbs"/>

<!--  Triggers  -->
<aliases>
  <alias
   script="togglespeaking"
   match="sapi"
   enabled="y"
   group="speech"
   omit_from_command_history="y"
   omit_from_log="y"
   omit_from_output="y"
   sequence="100"
  >
  </alias>
</aliases>

<triggers>
</triggers>

<!--  Script  -->


<script>
<![CDATA[

dim s
dim speak 'do we want to speak?
sub toggleSpeaking (name, line, wc)
if speak = 1 then
speak = 0
s.speak "jfw auto speak off.", 0
else
speak = 1
s.speak "jfw auto speak on.",0
end if
end sub

sub OnPluginInstall
set s = createobject("Sapi.SpVoice")
s.speak "sapi speech is ready to rock!",1
speak = 1

end sub
sub OnPluginBroadcast (msg, id, name, text)
if msg = 223 then
s.speak text,1
end if
end sub
]]>
</script>


</muclient>
