开发者

AS3 Socket Error

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",
};
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜