[Flashcoders] Tween AS3 issue with Firefox

2009-03-25 Thread Reina Lyn Ben
has anyone had the same problem. I have a website up..
http://kozonline.com/epk the animation is created in AS3, when I use
firefox, the animation/transition freezes, I've found solutions online like
creating a variable and store the tween there instead of being dependent on
the garbage Collector feature that tween have. When I test the site on IE,
it animates fine and finishes the tween..

-- 
Reina Lyn Ben
Interactive Web Devsigner
www.ReinaLynBen.com
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Error #2037: Functions called in incorrect sequence, or earlier call was unsuccessful.

2009-03-05 Thread Reina Lyn Ben
I'm trying to play more than one song in a music player. the music player is
in an exported movieclip and the links are in another movieclip.. but I kept
getting this error.. i did my research and found scripts online but no step
by step esplanation.. here is my code:

THIS IS MY CODE TO THE MUSIC PLAYER:
//var song:Sound = new Sound;
var sndChan:SoundChannel = new SoundChannel;
//var songReq:URLRequest;
var songPlaying:Boolean = false;
var pos:Number;
aPlayBtn.addEventListener(MouseEvent.CLICK, playSong);
aPlayBtn.buttonMode = true;
aStopBtn.addEventListener(MouseEvent.CLICK, stopSong);
aStopBtn.buttonMode = true;
aPauseBtn.addEventListener(MouseEvent.CLICK, pauseSong);
function playSong(e:Event):void {
 if (songPlaying == false) {
  songPlaying = true;
  sndChan = MovieClip(root).audio.song.play(pos);
  aPlayBtn.removeEventListener(MouseEvent.CLICK, playSong);
  aPlayBtn.buttonMode = false;
 }
}
function playSongI():void {
 if (songPlaying == false) {
  songPlaying = true;
  sndChan = MovieClip(root).audio.song.play(pos);
  aPlayBtn.removeEventListener(MouseEvent.CLICK, playSong);
  aPlayBtn.buttonMode = false;
 }
}

function stopSong(e:Event):void {
 sndChan.stop();
 songPlaying = false;
 aPlayBtn.addEventListener(MouseEvent.CLICK, playSong);
 aPlayBtn.buttonMode = true;
 pos = 0;
}
function stopSongI():void {
 sndChan.stop();
 songPlaying = false;
 aPlayBtn.addEventListener(MouseEvent.CLICK, playSong);
 aPlayBtn.buttonMode = true;
 pos = 0;
}
function pauseSong(e:Event):void {
 pos = sndChan.position;
 sndChan.stop();
 songPlaying = false;
 aPlayBtn.addEventListener(MouseEvent.CLICK, playSong);
}



AND THIS IS MY CODE TO THE MUSIC LIST:
var audioPlayer:aPlayer = new aPlayer();
audioPlayer.x = 50;
audioPlayer.y = 20;
var song:Sound = new Sound;
var songReq:URLRequest;
//BUTTONS HOLDING LOCATION OF SONGS--
btnStream01.addEventListener(MouseEvent.CLICK, onClick);
btnStream01.songURL = "audio/01 An Offer You Can't Refuse.mp3";
btnStream02.addEventListener(MouseEvent.CLICK, onClick);
btnStream03.songURL = "audio/02 Cruise.mp3";
btnStream03.addEventListener(MouseEvent.CLICK, onClick);
btnStream03.songURL = "audio/03 So Many Girlz featuring P. Murray.mp3";
btnStream04.addEventListener(MouseEvent.CLICK, onClick);
btnStream04.songURL = "audio/04 Damn I'm Cooo.mp3";
//---
function onClick(e:Event):void {
 addChild(audioPlayer);
 songReq = new URLRequest(e.currentTarget.songURL);
 song.load(songReq);
 this.audioPlayer.playSongI();

 audioPlayer.aClosePlayer.addEventListener(MouseEvent.CLICK,
closePlayerFunction);
 audioPlayer.aClosePlayer.buttonMode = true;
}
function closePlayerFunction(e:Event):void {
 removeChild(audioPlayer);
 this.audioPlayer.stopSongI();
}

-- 
____________

Reina Lyn Ben
Flash Web Devsigner

Web Portfolio:  www.ReinaLynBen.com <http://www.reinalynben.com/>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] accessing a function from a movieclip

2009-03-02 Thread Reina Lyn Ben
can any one help me with this code:
MovieClip(root).con_video.AVplayer.startVideo();
I am trying to access a function from a movieclip. This code is not located
on the stage or root, it is located at con_video.  (^^,)

Thanks,
Rein

-- 


Reina Lyn Ben
Flash Web Devsigner

Web Portfolio:  www.ReinaLynBen.com <http://www.reinalynben.com/>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders