Exemplo n.º 1
0
    /// <summary>
    /// 获得队伍列表
    /// </summary>
    /// <param name="cmd"></param>
    public void OnConvenientTeamList(GameCmd.stGetTeamListRelationUserCmd_S cmd)
    {
        m_listConvenientTeam.Clear();
        for (int i = 0; i < cmd.data.Count; i++)
        {
            List <ConvenientTeamInfoMemData> memDataList = new List <ConvenientTeamInfoMemData>();

            for (int j = 0; j < cmd.data[i].memData.Count; j++)
            {
                ConvenientTeamInfoMemData memData = new ConvenientTeamInfoMemData {
                    job = cmd.data[i].memData[j].job, level = cmd.data[i].memData[j].level
                };
                memDataList.Add(memData);
            }

            ConvenientTeamInfo convenientTeamInfo = new ConvenientTeamInfo(cmd.data[i].active_id, cmd.data[i].byCount, cmd.data[i].byjob, cmd.data[i].byLevel, cmd.data[i].leaderID, memDataList, cmd.data[i].teamid, cmd.data[i].teamname, cmd.data[i].wdIcon);

            m_listConvenientTeam.Add(convenientTeamInfo);
        }

        this.m_conveientSelectTargetId = cmd.active_id;

        // m_listConvenientTeam = cmd.data;

        if (DataManager.Manager <UIPanelManager>().IsShowPanel(PanelID.ConvenientTeamPanel) == false)
        {
            DataManager.Manager <UIPanelManager>().ShowPanel(PanelID.ConvenientTeamPanel);
        }

        if (DataManager.Manager <UIPanelManager>().IsShowPanel(PanelID.ConvenientTeamPanel))
        {
            DataManager.Manager <UIPanelManager>().SendMsg(PanelID.ConvenientTeamPanel, UIMsgID.eUpdateExistedTeamList, null);
        }
    }
Exemplo n.º 2
0
 public override void SetGridData(object data)
 {
     base.SetGridData(data);
     this.m_teamInfo = data as ConvenientTeamInfo;
     SetMember(this.m_teamInfo.memDataList);
 }