如何链接到框架Adobe Flash CS6动作脚本3

时间:2015-08-25 04:30:39

标签: actionscript-3 flash adobe

我需要帮助我的adobe flash赋值,我还是adobe flash的新手:(如何告诉用户他们输入错误的关键字如何将它们链接到框架。



var i:int = 0;
var names:Array = new Array("html","head","body");
var frames:Array = new Array("6","7","8");

searchhtmlll.text ="";

searchhtml.addEventListener(MouseEvent.CLICK, fl_MouseClickHandler_2);

function fl_MouseClickHandler_2(event:MouseEvent):void
{
	findInArray(searchhtmlll.text);
	gotoAndStop(frames[i]);
}

function findInArray(str:String):int
{
	for(i = 0; i < names.length; i++)
	{
		if(names[i] == str)
		{
			return i;
		}
	}
	return 0;
}
&#13;
&#13;
&#13;

0 个答案:

没有答案