Este es el code que copie de ayuda de Flash:
Código ActionScript :
var keyListener_obj:Object = new Object(); keyListener_obj.onKeyDown = function() { switch (Key.getCode()) { case Key.SPACE : gotoAndStop("menu"); // no logre que me tome la tecla "m" break; case Key.LEFT : if(currentFrame()<>1){ prevFrame();} break; case Key.RIGHT : nextFrame(); break; } }; Key.addListener(keyListener_obj);
A su la vez, hay un video insertado en cada fotograma (video 1, video2, etc) que al finalizar su reproducción pasa al siguiente fotograma. Código encontrado en tutorial de eldervaz. http://www.eldervaz.com/guia_flv2.htm
Código ActionScript :
var conexion:NetConnection = new NetConnection(); conexion.connect(null); var stream:NetStream = new NetStream(conexion); mi_video.attachVideo(stream); stream.play("1.flv"); stream.setBufferTime(10); onEnterFrame = function () { bu_cargado.text = stream.bufferLength; bu_total.text = Math.round(stream.bytesTotal/1024)/1000+" mb"; }; stream.onStatus = function(infoObject:Object) { if (infoObject.code == "NetStream.Play.Stop") { gotoAndStop("video2"); } if (infoObject.code == "NetStream.Play.StreamNotFound") { trace("encontro error"); } };
El problema es que se me superponen ambas instrucciones, si se presiona la flecha de pasar mientras esta el video en reproducción. La solucion que se me ocurre es deshabilitar la función de que al terminar el video pase de fotograma si presiono una flecha antes, alguna pista de como hacerlo ??
Gracias de antemano!!!