cookiecaper
Programmer
Hey dudes,
I have this ActionScript:
// Create a NetConnection object
var netConn:NetConnection = new NetConnection();
// Create a local streaming connection
netConn.connect(null);
// Create a NetStream object and define an onStatus() function
var netStream:NetStream = new NetStream(netConn);
netStream.onStatus = function(infoObject) {
status_txt.text += "Status (NetStream)" + newline;
status_txt.text += "Level: "+infoObject.level + newline;
status_txt.text += "Code: "+infoObject.code + newline;
if (infoObject.code == "NetStream.Play.StreamNotFound")
{
playother();
}
};
// Attach the NetStream video feed to the Video object
my_video.attachVideo(netStream);
// Set the buffer time
netStream.setBufferTime(2);
// Begin playing the FLV file
netStream.play("file:///c:/videojile.flv");
function playother() {
var netSonn:NetConnection = new NetConnection();
status_txt.text += "readyok" + newline;
netSonn.connect(null);
status_txt.text += "readsdok" + newline;
// Create a NetStream object and define an onStatus() function
var hat:NetStream = new NetStream(netSonn);
status_txt.text += "readyqqaqa" + newline;
hat.onStatus = function (infoObject){
status_txt.text += "Status (NetStream)" + newline;
status_txt.text += "Level: "+infoObject.level + newline;
status_txt.text += "Code: "+infoObject.code + newline; }
// Attach the NetStream video feed to the Video object
_root.fdg.attachVideo(hat);
status_txt.text += "reaaeexxk" + newline;
// Set the buffer time
hat.setBufferTime(2);
status_txt.text += "reaadffeeefsseexxk" + newline;
// Begin playing the FLV file
hat.play("file:///c:/out.flv");
status_txt.text += "reaaeexadfafdaxk" + newline;
};
It works in Flash Debugger but it doesn't work in the real player. wtf
I have this ActionScript:
// Create a NetConnection object
var netConn:NetConnection = new NetConnection();
// Create a local streaming connection
netConn.connect(null);
// Create a NetStream object and define an onStatus() function
var netStream:NetStream = new NetStream(netConn);
netStream.onStatus = function(infoObject) {
status_txt.text += "Status (NetStream)" + newline;
status_txt.text += "Level: "+infoObject.level + newline;
status_txt.text += "Code: "+infoObject.code + newline;
if (infoObject.code == "NetStream.Play.StreamNotFound")
{
playother();
}
};
// Attach the NetStream video feed to the Video object
my_video.attachVideo(netStream);
// Set the buffer time
netStream.setBufferTime(2);
// Begin playing the FLV file
netStream.play("file:///c:/videojile.flv");
function playother() {
var netSonn:NetConnection = new NetConnection();
status_txt.text += "readyok" + newline;
netSonn.connect(null);
status_txt.text += "readsdok" + newline;
// Create a NetStream object and define an onStatus() function
var hat:NetStream = new NetStream(netSonn);
status_txt.text += "readyqqaqa" + newline;
hat.onStatus = function (infoObject){
status_txt.text += "Status (NetStream)" + newline;
status_txt.text += "Level: "+infoObject.level + newline;
status_txt.text += "Code: "+infoObject.code + newline; }
// Attach the NetStream video feed to the Video object
_root.fdg.attachVideo(hat);
status_txt.text += "reaaeexxk" + newline;
// Set the buffer time
hat.setBufferTime(2);
status_txt.text += "reaadffeeefsseexxk" + newline;
// Begin playing the FLV file
hat.play("file:///c:/out.flv");
status_txt.text += "reaaeexadfafdaxk" + newline;
};
It works in Flash Debugger but it doesn't work in the real player. wtf