Foros del Web » Creando para Internet » Flash y Actionscript »

Problema Con ActionScript

Estas en el tema de Problema Con ActionScript en el foro de Flash y Actionscript en Foros del Web. Hola gentee bueno tengo un problema al crear un menu carrusel, por cierto estoy inventando un poco y viendo como puedo crear un carrusel con ...
  #1 (permalink)  
Antiguo 20/10/2010, 14:00
 
Fecha de Ingreso: octubre-2010
Ubicación: San juan Argentina
Mensajes: 95
Antigüedad: 13 años, 6 meses
Puntos: 0
Exclamación Problema Con ActionScript

Hola gentee bueno tengo un problema al crear un menu carrusel, por cierto estoy inventando un poco y viendo como puedo crear un carrusel con iconos distintos, sale un error ( TypeError: Error #1010: Un término no está definido y no tiene propiedades.
at Sint_fla::MainTimeline/frame1() )
SI ALGUIEN ME PUEDE AYUDAR MUCHISIMAS GRACIAS

Código:
 import flash.events.Event;

Boton1.visible = false;

var menu_Clavijo:Array = new Array("Inicio","Productos","Diseño Web");
var total:Number = menu_Clavijo.length;
var center_x:Number = 470;
var center_y:Number = 360;
var i:Number = 0;
var page:Number;
var main_menu:MovieClip = new MovieClip();
stage.addChild(main_menu);

for (i = 0; i < total; i++)
{
    var btn = new Boton();
    btn.name = "Boton_Clavijo" + i;
    btn.x = center_x;
    btn.y = center_y;

    btn.scaleX = 0;
    btn.scaleY = 0;
    btn.alpha = 0;
    btn.item_no = i;

    btn.Clavijo_icono.gotoAndStop( i + 1 );
    btn.addEventListener( MouseEvent.ROLL_OVER, btn_over );
    btn.addEventListener( MouseEvent.ROLL_OUT, btn_out );
    btn.addEventListener( MouseEvent.CLICK, btn_click );

    var each_substring:Array = menu_Clavijo[i].split("|");
    btn.Boton_Clavijo.fm_label.text = each_substring[0];
    btn.item_url = each_substring[1];
    menu_Clavijo.addChild(btn);
    
}

function btn_over(e:MouseEvent):void
{
    e.target.over = true;
}

function btn_out(e:MouseEvent):void
{
    e.target.over = false;
}

function btn_click(e:MouseEvent):void
{
    var mc = e.target.parent;
}


var boton:Boton;

var ejeX:Number = stage.stageWidth/ 2;
var ejeY:Number = stage.stageHeight/ 2;
var amplitudX:Number = 180;
var amplitudY:Number = 45;

var cantidad:int = 4;
var difAngular:Number = ( Math.PI * 2) / 4;

for (i = 0; i < cantidad; i++ ) {
    boton = new Boton ();
    boton.angulo = difAngular * i;
    
    boton.x =Math.cos (boton.angulo) * amplitudX + ejeX;
    boton.y =Math.sin (boton.angulo) * amplitudY + ejeY;
    boton.addEventListener ( Event.ENTER_FRAME, orbitarObjetos );
    addChild ( boton );
    
}

var incrAngulo:Number;

function orbitarObjetos (event:Event ):void {
    
    incrAngulo = ((stage.mouseX - ejeX) / ejeX ) * 0.1;
    
    event.target.angulo += incrAngulo;
    
    event.target.x = Math.cos ( event.target.angulo ) * amplitudX + ejeX
    event.target.y = Math.sin ( event.target.angulo ) * amplitudY + ejeY
    event.target.scaleX = 1 + Math.sin ( event.target.angulo) * 0.4;
    event.target.scaleY = event.target.scaleX;
  #2 (permalink)  
Antiguo 20/10/2010, 14:02
 
Fecha de Ingreso: octubre-2010
Ubicación: San juan Argentina
Mensajes: 95
Antigüedad: 13 años, 6 meses
Puntos: 0
Respuesta: Problema Con ActionScript

La verdad qe no entiendo mucho actionscript estos son codigos que saque y fui modificando dependiendo de la variable ! Si alguien se interesa ayudar mas internamente que me deje su mail en mensaje ; gracias
  #3 (permalink)  
Antiguo 20/10/2010, 14:04
Avatar de mortiprogramador
Colaborador
 
Fecha de Ingreso: septiembre-2009
Ubicación: mortuoria
Mensajes: 3.805
Antigüedad: 14 años, 8 meses
Puntos: 214
Respuesta: Problema Con ActionScript

Hola
el termino no definido generalmente es porque se esta intentando
acceder a un objeto que no existe en ese momento en la línea
de tiempo
en tu lugar, pondria partes en comentarios hasta encontrar
cual es la del inconveniente
revisa eso
saludos
__________________
"Si consigues ser algo más que un hombre, si te entregas a un ideal, si nadie puede detenerte, te conviertes en algo muy diferente."
Visita piggypon.com
  #4 (permalink)  
Antiguo 20/10/2010, 18:56
 
Fecha de Ingreso: octubre-2010
Ubicación: San juan Argentina
Mensajes: 95
Antigüedad: 13 años, 6 meses
Puntos: 0
Respuesta: Problema Con ActionScript

Muchas gracias morti pero al no entende mucho , como qe me congelo JA pero bue gracias por tu respuesta !

Etiquetas: actionscript
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 11:28.