How do I use Audio Analyser?

Get help using Construct 2

Post » Wed Sep 17, 2014 2:26 pm

I've been trying to use audio analyser to make a background like Super Hexagon. I'm using Construct 2 r180. To preview, I am using Chrome Canary.
The event is
Code: Select all
System > General > Compare 2 Values > First value: round(Audio.AnalyserRMSLevel("pew", 0)) | Comparison: > Greater than | Second value: -22

The action is
Code: Select all
System > Layers & Layout >  Set layer background color > Layer: 0 | Color: rgb(random(255), random(255), random(255))

I found that Audio.AnalyserRMSLevel("pew", 0) always outputs 0, regardless if the music is off or on.
Then I used the Audio analyser sample project and imported the same music and changed the play audio action to play my music, and then I imported the code from above, and it worked exactly how I wanted it to.
Posts: 1
Reputation: 427

Post » Thu Sep 25, 2014 8:05 pm

You have to add Analyzer then you should succeed:
Code: Select all
System > On start of layout | Audio > Add analyzer effect to tag "pew" (FFT size 512, smoothing 0)
Posts: 6
Reputation: 608

Return to How do I....?

Who is online

Users browsing this forum: wandererabove and 4 guests