inputMic = Microphone

I want to call particular frame on using microphone.

example:

Suppose i speak in the microphone and the volume is >10 and <20.
the command

gotoAndPlay(“Fire”);

must play.

Please help.

it’d help maybe if you posted example and tutorials you have found.

the only examples I have found on this are cs3

Here is the example:

function init()
{
createEmptyMovieClip(“micAudio”, 3);
micAudio.attachAudio(Microphone.get());
inputMic = Microphone.get();
inputMic.setUseEchoSuppression(0);
inputMic.setRate(8);
inputMic.setSilenceLevel(0);
inputMic.setGain(40);
gainlevel._y = 85;
inputSound = new Sound(micAudio);
inputSound.setVolume(0);
nosignalmax = 100;
maxrecord = 2500;
amprunlevel = 50;
records = new Array();
} // End of the function
Function.prototype.executeLater = function ()
{
var func = this;
var _loc4 = arguments.shift();
var _loc3 = arguments.shift();
var args = arguments;
var intervalId = setInterval(function (obj)
{
func.apply(obj, args);
clearInterval(intervalId);
}, _loc4, _loc3);
};
MovieClip.prototype.dolevel = function ()
{
};
MovieClip.prototype.dosound = function (levelamp)
{
if (levelamp > 40 && levelamp < 49 && this.accions == 0)
{
this.gotoAndPlay(“level1”);
this.accions = 1;
} // end if
if (levelamp > 50 && levelamp < 59 && this.accions == 0)
{
this.gotoAndPlay(“level2”);
this.accions = 1;
} // end if
if (levelamp > 60 && levelamp < 79 && this.accions == 0)
{
this.gotoAndPlay(“level3”);
this.accions = 1;
} // end if
if (levelamp > 80 && levelamp < 90 && this.accions == 0)
{
this.gotoAndPlay(“level4”);
this.accions = 1;
} // end if
if (levelamp > 95 && this.accions == 0)
{
this.gotoAndPlay(“level5”);
this.accions = 1;
_root.total = _root.total - 1;
if (_root.total == 0)
{
pesada.gotoAndPlay(2);
_root.total = -1;
} // end if
if (_root.total != 0 && _root.total != -1)
{
_root.texteFinal._visible = 0;
sombra.play();
} // end if
if (_root.total == -2)
{
_root.texteFinal._visible = 100;
_root.texteFinal.play();
} // end if
} // end if
};
init();
stop ();