Hello all, I posted this a few days ago and just wanted to know if you could
load it, but I found a problem that I do not understand. I just saved this
file, which was previously MX2004, as Flash 8 in the authoring environment.
I have exported for Player 7/AS 2.0, but for some reason it will no longer
play in player 7. Can you see if there is anything in my code that would
cause this? Thanks in advance.
System.security.allowDomain("www.live365.com");
var up:Boolean = false;
var reloadInt:Number;
function createLoaderText(output){
_root.createEmptyMovieClip("loader_mc",1000);
loader_mc.createTextField("p_txt",1100,60,6,160,20);
loader_mc.p_txt.text = output;
var loadingFmt:TextFormat = new TextFormat();
loadingFmt.font = "My Font";
loadingFmt.color = 0xFF9900;
loadingFmt.bold = true;
loader_mc.p_txt.embedFonts = true;
loader_mc.p_txt.setTextFormat(loadingFmt);
loader_mc.onEnterFrame = function(){
if(up == false){
this.p_txt._alpha -= 5;
if(this.p_txt._alpha <= 0){
up = true;
}
}else{
this.p_txt._alpha += 5;
if(this.p_txt._alpha >= 100){
up = false;
}
}
}
}
var radio:Sound = new Sound();
var volume:Number = 50;
var marker:MovieClip = volume_mc.slider_mc;
var volTrackFactor = volume_mc.track_mc._width/100;
var stopped:Boolean = false;
var trackLoaded:Boolean;
var stopped:Boolean = false;
vumeter_mc.stop();
function playRadio(){
if(!loader_mc){
createLoaderText("loading");
}
mute_mc.gotoAndStop(1);
volume_mc.slider_mc._x = volume_mc.track_mc._x +
volume_mc.track_mc._width/2 - 10;
if (typeof radio == "object") {
radio.stop();
delete radio;
}
stopped = false;
radio = new Sound(this);
radio.setVolume(volume);
radio.loadSound("http://www.live365.com/play/signonsandiego/pro ",true);
stop1_btn.enabled = true;
stop1_btn._alpha = 100;
play1_btn.enabled = false;
play1_btn._alpha = 30;
var lastPosition = 0;
vumeter_mc.onEnterFrame = function(){
if(radio.position > 1 && stopped==false && radio.position >
lastPosition){
lastPosition = radio.position;
clearInterval(reloadInt);
loader_mc.removeMovieClip();
vumeter_mc.play();
//delete this.onEnterFrame;
}else{
if(!loader_mc){
createLoaderText("buffering");
}
vumeter_mc.gotoAndStop(1);
}
}
reload();
}
play1_btn.onRelease = playRadio;
stop1_btn.onRelease = stopPlay;
function stopPlay(){
delete vumeter_mc.onEnterFrame;
clearInterval(reloadInt);
loader_mc.removeMovieClip();
mute_mc.gotoAndStop(1);
vumeter_mc.gotoAndStop(1);
stopped = true;
radio.stop();
play1_btn.enabled = true;
play1_btn._alpha = 100;
stop1_btn.enabled = false;
stop1_btn._alpha = 30;
}
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com