GetSoundBPM: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Spams the chatbox - Undo revision 33668 by Zver-CR (talk))
Line 17: Line 17:
<section name="Client" class="client" show="true">
<section name="Client" class="client" show="true">
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
local sound = playSound ( "http://radio02-cn03.akadostream.ru:8114/nrj192.mp3" )
-- not done yet
 
addEventHandler ( "onClientRender", root,
function ( )
local bpm = getSoundBPM ( sound )
outputChatBox ( string.format ( "BPM: %i", bpm or 0 ) )
end
)
</syntaxhighlight>
</syntaxhighlight>
</section>
</section>

Revision as of 08:55, 3 October 2012