Esempio n. 1
0
    //解析服务器数据
    public void ReceiveMsg(SocketModel socketModel)
    {
        Debug.Log("收到消息主协议=" + socketModel.GetMainCmd() + "子协议 = " + socketModel.GetSubCmd());
        switch (socketModel.GetMainCmd())
        {
        case ProtocolMC.Main_Cmd_LOGIN:
            loginser.handlerSubCmd(socketModel);
            break;

        case ProtocolMC.Main_Cmd_HALL:
            hallser.handlerSubCmd(socketModel);
            break;

        case ProtocolMC.Main_Cmd_ROOM:
            roomser.handlerSubCmd(socketModel);
            break;
        }
    }