Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question Failed to join lobby by code: lobby code 'MDDFHD' contains an invalid character '' (U+200B) at ind

Discussion in 'Lobby' started by luniac, Nov 10, 2023.

  1. luniac

    luniac

    Joined:
    Jan 12, 2011
    Posts:
    607
    I dont understand whats going on, im copying a pasting the exactly lobby code in a textmeshpro input text and using that as the join lobby code in :

    Code (CSharp):
    1. string privateMatchJoinCode = GameObject.FindWithTag("PrivateMatchJoinCode").GetComponent<TextMeshProUGUI>().text;
    2. try
    3. {
    4.  
    5.     currentLobby = await LobbyService.Instance.JoinLobbyByCodeAsync(privateMatchJoinCode);
     
  2. luniac

    luniac

    Joined:
    Jan 12, 2011
    Posts:
    607
    This seems to work
    privateMatchJoinCodeInput.Substring(0, 6);
     
  3. UnityKristy

    UnityKristy

    Joined:
    Mar 9, 2014
    Posts:
    6
    luniac likes this.
  4. luniac

    luniac

    Joined:
    Jan 12, 2011
    Posts:
    607
  5. UnityKristy

    UnityKristy

    Joined:
    Mar 9, 2014
    Posts:
    6
    No worries :)