var Message = new annie.Sprite();root.Message = Message ;Message.addEventListener("receive_data",receiveMessage);
receiveMessage = function(evt){
trace(evt.data);
}
... .....
var Message = new annie.Sprite();
root.Message = Message ;
Message.addEventListener("receive_data",receiveMessage);
receiveMessage = function(evt){
trace(evt.data);
}
... ...
其他位置:
root.Message.dispatchEvent("receive_data",{x:800});
//打印:x:800