New to AS3 and I get this error: 1084: Syntax error: expecting rightbrace before colon. Conn:Socket: null,
var mc:Object = {
Conn:Socket: null,
Username:String: "fu",
};
function zSock(host:String = "70.32.72.134", port:String "70.32.72.134"):void {
开发者_开发问答 mc.Conn = new Socket(host, port);
mc.Conn.addEventListener(Event.CONNECT, onConnect);
mc.Conn.addEventListener(ProgressEvent.SOCKET_DATA, onData);
}
you cannot strict type properties of Objects.
var mc:Object = {
Conn: null,
Username: "fu",
};
精彩评论