コード例 #1
0
    /// <summary>
    /// 服务器断线重连房间消息
    /// </summary>
    /// <param name="obj"></param>
    private void OnServerReturnReconnectRoom(byte[] obj)
    {
        Debug.Log("服务器返回断线重连消息");


        UIViewManager.Instance.CloseWait();
        NN_ROOM_CREATE proto = NN_ROOM_CREATE.decode(obj);

        GameStateManager.Instance.InitCurrentRoom(proto);
        Debug.Log("准备断线重连创建房间,自己ID:" + AccountProxy.Instance.CurrentAccountEntity.passportId);

        SceneMgr.Instance.LoadScene(SceneType.NiuNiu2D);
    }
コード例 #2
0
    /// <summary>
    /// 服务器返回创建房间消息
    /// </summary>
    /// <param name="obj"></param>
    private void OnServerReturnCreateRoom(byte[] obj)
    {
        UIViewManager.Instance.CloseWait();

        NN_ROOM_CREATE proto = NN_ROOM_CREATE.decode(obj);

        //收到配置数据存到模型基类

        GameStateManager.Instance.InitCurrentRoom(proto);


        Debug.Log("准备创建房间,自己ID:" + AccountProxy.Instance.CurrentAccountEntity.passportId);
        SceneMgr.Instance.LoadScene(SceneType.NiuNiu2D);
    }