View Single Post
Old 03-31-11, 10:44 AM   #283
MiTon
Sparky
 
Join Date: Apr 2010
Location: Germany
Posts: 157
Downloads: 270
Uploads: 2
Default

Quote:
Originally Posted by marcus55 View Post
That works

I modified some orders with words simpler to pronounce and more problems.
teleport to bridge Not worked not(my bad/poor english?), then I modified it and that works!

This was my fault look here: http://www.subsim.com/radioroom/show...&postcount=277

(I do not know why, but not means to launch this order...)
ex:
teleport to bridge =>> teleport to deck

I also modified some other orders, to make them a little more real...
All Stop =>> engine stop

etc..etc...

Did you alter the SHSpeech_Grammar.xml accordingly? You always have to have a corresponding "Grammarfile" or your commands will not be reocgnized.

In this file(SHSpeech_Commands.xsl) I also modified it:


<order><!-- teleport to radio -->
<phrase>teleport to radio</phrase>
<commandText>Teleport_To_Radar</commandText>
</order>

<order><!-- teleport to radio -->
<phrase>teleport to radio</phrase>
<commandText>Teleport_To_Radio</commandText>
</order>

There is no "Teleport_To_Radio" in the Speech Recognition.py or in Game Commands.txt, so this command will do nothing!!
You shouldn't change anything inside <commandText>....</commandText> unless you know what you are doing.

And added these lines:

<order><!-- teleport to radar-->
<phrase>teleport to radio</phrase>
<commandText>Teleport_To_Radar</commandText>
</order>

You coppied a working command, why?? If you want to add more phrases to be recognized, make sure they are in SHSpeech_Grammar.xml and then add them like this.

<order><!-- teleport to radar-->
<phrase>teleport to radio</phrase>
<phrase>NEW PHRASE</phrase>
<commandText>Teleport_To_Radar</commandText>
</order>


And then, I modified or added some other orders, maintaining everything seems to work thank you for this(they) very well mod
I recommend you to read:

http://www.subsim.com/radioroom/show...1&postcount=91

http://www.subsim.com/radioroom/show...1&postcount=92

http://www.subsim.com/radioroom/show...&postcount=249

and the CustomizingTutorial_english.pdf in the mods Documentation folder. (Will rework it and make things more clear in the next release)

Greets

MiTon

Last edited by MiTon; 03-31-11 at 11:18 AM.
MiTon is offline   Reply With Quote