I have sample code for NetConnection in as3 :
var good:Boolean;
nc = new NetConnection();
nc.connect("rtmp://ip:port/MyDemo/");
nc.addEventListener(NetStatusEvent.NET_STATUS,getStream);
function getStream(e:NetStatusEvent):Void
{
good=e.info.code == "NetConnection.Connect.Success";
if(good)
{
var responder = new Responder(adder);
nc.call("addSomething",responder,2,3);
}
}
function adder (obj:Object):Void
{
trace("Total = "+obj.toString());
}
i have a method "addSomething" in my Test.java which extends ApplicationAdapter class.
My question is that can i use this code in actions of an fla file using as2 or not. If yes than how ?
If not than what changes have to made to use this code in as2 ?
Thanks