Difference between revisions of "Lua:playSound"

From Cheat Engine
Jump to navigation Jump to search
m (Created page with 'If you wish to play [http://www.freeslotsland.eu/ Real Money Free Slots], the one thing that you're going to need to be careful about is the fact that you have to ensure that you…')
 
(Created page with ''''function''' playSound(''stream'', ''waittilldone'') '''function''' playSound(''tablefile'', ''waittilldone'') Plays a sound file ===Function Parameters=== {|width="85%" cell…')
Line 1: Line 1:
If you wish to play [http://www.freeslotsland.eu/ Real Money Free Slots], the one thing that you're going to need to be careful about is the fact that you have to ensure that you have a smart phone which is going to be appropriate making use of Best Free Slots Online and can not freeze once in a while.
+
'''function''' playSound(''stream'', ''waittilldone'')
 +
'''function''' playSound(''tablefile'', ''waittilldone'')
 +
 
 +
Plays a sound file
 +
 
 +
===Function Parameters===
 +
{|width="85%" cellpadding="10%" cellpadding="5%" cellspacing="0" border="0"
 +
!align="left"|Parameter
 +
!align="left"|Type
 +
!style="width: 60%;background-color:white;" align="left"|Description
 +
|-
 +
|stream
 +
|[[Stream]]
 +
|A Stream object, can be [[MemoryStream]] or [[FileStream]]
 +
|-
 +
|tablefile
 +
|[[TableFile]]
 +
|A [[TableFile]] object, a file added and stored in the cheat table
 +
|-
 +
|waittilldone
 +
|Boolean
 +
|If true, the next LUA instruction will not execute until the sound is done playing
 +
|}
 +
 
 +
===Samples===
 +
 
 +
Calling from LUA
 +
 
 +
<pre>playSound(findTableFile('protected.wav'))</pre>
 +
 
 +
Calling from an AA Script:
 +
 
 +
<pre>[enable]
 +
luacall(playSound(findTableFile('protected.wav')))
 +
globals+1034:
 +
  dd 1
 +
 
 +
[disable]
 +
luacall(playSound(findTableFile('cleared.wav')))
 +
globals+1034:
 +
  dd 2
 +
</pre>
 +
 
 +
== See also ==
 +
* [[findTableFile]]
 +
* [[Stream]]
 +
* [[FileStream]]
 +
* [[MemoryStream]]

Revision as of 00:36, 23 December 2015

function playSound(stream, waittilldone) function playSound(tablefile, waittilldone)

Plays a sound file

Function Parameters

Parameter Type Description
stream Stream A Stream object, can be MemoryStream or FileStream
tablefile TableFile A TableFile object, a file added and stored in the cheat table
waittilldone Boolean If true, the next LUA instruction will not execute until the sound is done playing

Samples

Calling from LUA

playSound(findTableFile('protected.wav'))

Calling from an AA Script:

[enable]
luacall(playSound(findTableFile('protected.wav')))
globals+1034:
  dd 1

[disable]
luacall(playSound(findTableFile('cleared.wav')))
globals+1034:
  dd 2

See also