Hi guys over the past few days I've been researching Stratus in CS5 in the hope to be able to spawn some sort of multiplayer game from it. The main problem I have run into is using .send(), I can't figure out how to use the correctly. This is what I understood would work but it does not seem to register that anything has happened:
function sendMsg (event:MouseEvent):void
myString = textInput.text;
function msg (myMsg:String):void
myLog.text += myMsg;
Any help getting this to work would be greatly appreciated.
Just a few small questions about Stratus that I would love answered:
Note: All questions are in regard to CS5, not Flash Builder as I'm not very aware if there are any differences in the coding.
NetStream.send() should usually be faster than NetGroup.post(), especially when using 1:1 NetStreams (vs Group NetStreams).
when groups are large, there's no passive way to tell when members join or leave. however, for small groups (less than about 15 members), they will be "fully meshed", meaning every member has a direct connection to every other member. when that's the case, you can see the NetGroup.Neighbor.Connect/Disconnect events on a NetGroup. to receive those, you must create a NetGroup with the same groupspec as your NetStream and listen for NetStatusEvent.NET_STATUS events.
your function "msg" must be a method on the subscribing NetStream's "client" object to receive NetStream.send()s from the publisher.
this is all generic ActionScript stuff. i don't know how to use Flash CS5 but this stuff should all be the same in Flash and Flash Builder.