Example #1
0
    public void Init(GameProto.RoleData oData)
    {
        m_imgHead.gameObject.SetActive(true);
        LobbyTeamPlayer pLeader = TeamPlayerManager.Instance().GetPlayerBySlot(0);

        if (pLeader.m_qwPlayerId != PlayerData.Instance().proPlayerId)
        {
            m_buttonKick.gameObject.SetActive(false);
        }
        else
        {
            if (m_dwSlotId != 0)
            {
                m_buttonKick.gameObject.SetActive(false);
                //todo 先不踢玩家 如果要加这个功能 后面再处理
                m_buttonKick.gameObject.SetActive(true);
            }
            else
            {
                m_buttonKick.gameObject.SetActive(false);
            }
        }
        m_qwPlayerId    = oData.QwPlayerId;
        m_textName.text = oData.SzNickName;
        m_buttonInvite.gameObject.SetActive(false);
        StartCoroutine(H5Helper.SendGet(oData.SzAvatar, delegate(Texture2D tex)
        {
            m_imgHead.texture = tex;
        })
                       );
    }
Example #2
0
    void SlotClick()
    {
        if (m_qwPlayerId != 0)
        {
            return;
        }
        LobbyTeamPlayer pLeader = TeamPlayerManager.Instance().GetPlayerBySlot(0);

        if (pLeader.m_qwPlayerId != PlayerData.Instance().proPlayerId)
        {
            //其他人点就是换位置 后面可以加个其他模式
            LoginControler.Instance().ChangeSlot(m_dwSlotId);
        }
        else
        {
            //队长点 就是拉人
            LoginControler.Instance().OnlinePlayers();
        }
    }
Example #3
0
 // Use this for initialization
 void Start()
 {
     TeamPlayerManager.Instance().SyncTeamInfo(TeamData.Instance().proTeamRoleData);
 }
Example #4
0
 // Use this for initialization
 void Start()
 {
     TeamPlayerManager.Instance().PrepareSyncTeamInfo(TeamData.Instance().proTeamRoleData);
     TeamData.Instance().Reset();
 }