1 플래시Flash 강좌 FLASH CS3에서 액션스크립트 수정 Wed May 04, 2011 8:56 pm
Admin
Admin
Adobe 플레시 CS3에선 숫자만으로 인스턴트 네임이 들어가지 않는다는데...
기존에 사용하던 소스가 다 숫자로 되어있어서...
그래서 m1...이렇게 인스턴트 네임을 바꿨답니다...이렇게 했을 경우 액션스크립트를 어떻게 변형해야 하는지???
link = new Array();
link[1] = "../4000/01.php";
link[2] =
"../2000/05.php";
link[3] = "../8000/03.php";
link[4] =
"../8000/03.php";
frame = new Array();
frame[1] = "_self";
frame[2] =
"_self";
frame[3] = "_self";
frame[4] = "_self";
numOfMenu = 4;
gap = 4000;
maxHeight =71;
minHeight =31;
_global.over = 1;
for (i=1; i<=numOfMenu; i++)
{
this[i].bg._yscale =
this[i].bg._height;
this[i].bg.on-RollOver = function()
{
_global.over =
this._parent._name;
clearInterval(id);
};
this[i].bg.on-RollOut
= this[i].bg.on-DragOut=function () {
id = setInterval(aa,
gap);
};
this[i].bg.on-Release = function()
{
getURL(link[this._parent._name],
frame[this._parent._name]);
};
this[i].on-EnterFrame =
function() {
if (over == this._name)
{
this.nextFrame();
this.bg.targetY =
maxHeight;
} else
{
this.prevFrame();
this.bg.targetY =
minHeight;
}
this.temp =
this.temp*0.1+(this.bg.targetY-this.bg._height)*0.1;
this.bg._height
+= this.temp;
if (this._name != 1) {
this._Y
=
this._parent[this._name-1].bg._height+this._parent[this._name-1]._Y;
}
};
}
id
= setInterval(aa, gap);
function aa() {
if (over == numOfMenu)
{
_global.over = 1;
} else
{
_global.over++;
}
}
원 소스 입니다...제발좀 부탁 드립니다.
휴~~~ 액션스크립트는 넘 어려워^^ 에궁~~~~~~~~~~~]
기존에 사용하던 소스가 다 숫자로 되어있어서...
그래서 m1...이렇게 인스턴트 네임을 바꿨답니다...이렇게 했을 경우 액션스크립트를 어떻게 변형해야 하는지???
link = new Array();
link[1] = "../4000/01.php";
link[2] =
"../2000/05.php";
link[3] = "../8000/03.php";
link[4] =
"../8000/03.php";
frame = new Array();
frame[1] = "_self";
frame[2] =
"_self";
frame[3] = "_self";
frame[4] = "_self";
numOfMenu = 4;
gap = 4000;
maxHeight =71;
minHeight =31;
_global.over = 1;
for (i=1; i<=numOfMenu; i++)
{
this[i].bg._yscale =
this[i].bg._height;
this[i].bg.on-RollOver = function()
{
_global.over =
this._parent._name;
clearInterval(id);
};
this[i].bg.on-RollOut
= this[i].bg.on-DragOut=function () {
id = setInterval(aa,
gap);
};
this[i].bg.on-Release = function()
{
getURL(link[this._parent._name],
frame[this._parent._name]);
};
this[i].on-EnterFrame =
function() {
if (over == this._name)
{
this.nextFrame();
this.bg.targetY =
maxHeight;
} else
{
this.prevFrame();
this.bg.targetY =
minHeight;
}
this.temp =
this.temp*0.1+(this.bg.targetY-this.bg._height)*0.1;
this.bg._height
+= this.temp;
if (this._name != 1) {
this._Y
=
this._parent[this._name-1].bg._height+this._parent[this._name-1]._Y;
}
};
}
id
= setInterval(aa, gap);
function aa() {
if (over == numOfMenu)
{
_global.over = 1;
} else
{
_global.over++;
}
}
원 소스 입니다...제발좀 부탁 드립니다.
휴~~~ 액션스크립트는 넘 어려워^^ 에궁~~~~~~~~~~~]