Beispiel #1
0
 public void Initialize(PlayerLobbySlot slot, LobbyMenu menu)
 {
     m_slot = slot;
     m_menu = menu;
     m_menu.SetSlotTeam(m_slot, m_team);
     m_slot.SetPlayerName(m_playerName);
     m_slot.SetReadyMarkerTexture(m_ready);
 }
Beispiel #2
0
    public void SetName(string playerName)
    {
        if (m_playerName == playerName)
        {
            return;
        }

        m_playerName = playerName;
        if (m_slot != null)
        {
            m_slot.SetPlayerName(m_playerName);
        }

        if (isServer)
        {
            RpcSetName(playerName);
        }
        else if (isLocalPlayer)
        {
            CmdSetName(playerName);
        }
    }