Ver Mensaje Individual
  #1 (permalink)  
Antiguo 26/10/2012, 04:36
irenebb
 
Fecha de Ingreso: octubre-2012
Mensajes: 2
Antigüedad: 11 años, 6 meses
Puntos: 0
Ayuda¿donde pongo ._root para funcione script dentro de un MC?

Hola:
necesito ayuda con este script, de este menú que se mueve tipo "Mac", porque antes estaba en la línea principal de tiempo, pero lo necesitaba meter dentro de un clip de película, pero si lo meto no me funciona.
Supongo que es por la ruta, que tendría que subir un nivel, y supongo que tengo que meter ._root , pero no sé dónde¿?!!!
Pego mi script por si por favor me podeis ayudar!!!
GRACIAS!

centerx = Stage.width / 0.8;
centery = Stage.height / 1.25;
menucount = 6;
miwidth = this["btn0" + menucount - 1]._width;
miborder = 10;
AnchMen = 0;
onEnterFrame = function ()
{
var _loc7 = 0;
for (var _loc2 = 0; _loc2 < menucount; ++_loc2)
{
var _loc3 = this["btn0" + _loc2]._xmouse;
var _loc5 = this["btn0" + _loc2]._ymouse;
var _loc4 = Math.sqrt(_loc3 * _loc3 + _loc5 * _loc5);
if (_loc4 < 70)
{
this["btn0" + _loc2]._xscale = this["btn0" + _loc2]._yscale = this["btn0" + _loc2]._yscale + (200 - _loc4 - this["btn0" + _loc2]._yscale) / 3;
}
else
{
this["btn0" + _loc2]._xscale = this["btn0" + _loc2]._yscale = this["btn0" + _loc2]._yscale + (100 - this["btn0" + _loc2]._yscale) / 3;
} // end else if
_loc7 = _loc7 + this["btn0" + _loc2]._width;
} // end of for
_loc7 = _loc7 + (menucount - 1) * miborder;
var _loc6 = Math.round((centerx - _loc7) / 2);
_loc6 = _loc6 + Math.round((this.btn00._width + miborder) / 2);
for (var _loc2 = 1; _loc2 < menucount; ++_loc2)
{
x = _loc2 - 1;
_loc6 = _loc6 + (this["btn0" + x]._width / 2 + miborder + this["btn0" + _loc2]._width / 2);
this["btn0" + _loc2]._x = _loc6;
this["btn0" + _loc2]._y = centery;
} // end of for
this.btn00._x = this.btn01._x - this.btn00._width / 2 - this.btn01._width / 2 - miborder;
this.btn00._y = centery;
};