Difference between revisions of "Lua:speak"

From Cheat Engine
Jump to navigation Jump to search
(Samples)
Line 25: Line 25:
  
 
===Samples===
 
===Samples===
ToDo
+
Simple speak: 
 +
<pre>
 +
speak("Say hello to my little friend.")
 +
</pre>
  
 +
Read text from a file ''text.txt'' from the same directory as the table: 
 +
<pre>
 +
speak(TrainerOrigin.."test.txt", SPF_IS_FILENAME)
 +
</pre>
 
{{LuaSeeAlso}}
 
{{LuaSeeAlso}}
  
 
=== Related Functions ===
 
=== Related Functions ===
 
* [[speakEnglish]]
 
* [[speakEnglish]]

Revision as of 08:14, 19 June 2017

function speak(text, waittilldone OPTIONAL)

function speak(text, flags)

Function Parameters

Parameter Type Description
text String Text that should be spoken.
waittilldone Boolean If true, the next LUA instruction will not execute until the text is spoken.
flags Bit-field https://msdn.microsoft.com/en-us/library/speechplatform_speakflags.aspx

Samples

Simple speak:

speak("Say hello to my little friend.")

Read text from a file text.txt from the same directory as the table:

speak(TrainerOrigin.."test.txt", SPF_IS_FILENAME)

See also

Related Functions