Search Unity

Third Party Photon JoinLobby not working

Discussion in 'Multiplayer' started by Ewu_Uwe, Jan 11, 2021.

  1. Ewu_Uwe

    Ewu_Uwe

    Joined:
    Apr 13, 2020
    Posts:
    21
    Hi, I tried to Join a Lobby in Photon, but it always gives me the error:
    Operation JoinLobby (229) not called because client is not connected or not ready yet, client state: PeerCreated

    PhotonNetwork.JoinLobby() Gets called in OnConnectedToMaster()
    Thanksfor your help
     
  2. tobiass

    tobiass

    Joined:
    Apr 7, 2009
    Posts:
    3,072
    You first have to connect. This is a short workflow, which needs to complete, so we added a callback, telling you when that's done. Then, you could join a lobby (but don't have to).

    The Basics Tutorial is a good first read. Code-along and you will not stumble over those basics anymore.
     
  3. Ewu_Uwe

    Ewu_Uwe

    Joined:
    Apr 13, 2020
    Posts:
    21
    Yes, I thought OnConnectedtoMaster gets called when you're connected
     
  4. tobiass

    tobiass

    Joined:
    Apr 7, 2009
    Posts:
    3,072
    I just checked in PUN 2.27 and JoinLobby can be called in OnConnectedToMaster.
    Do you run an older version?
     
  5. Ewu_Uwe

    Ewu_Uwe

    Joined:
    Apr 13, 2020
    Posts:
    21
    No I run PUN 2.27
     
  6. tobiass

    tobiass

    Joined:
    Apr 7, 2009
    Posts:
    3,072
    Do you have other PhotonNetwork calls in OnConnectedToMaster?
    What exactly does the log say (it should have some hint what state your client is in)...
     
  7. ArckimiDer

    ArckimiDer

    Joined:
    Nov 10, 2021
    Posts:
    1
    Hey Bro!today i met the same problem,finally i find in Resource if you set photon start in offline would cause this problem.may be you fixed hhh
     
  8. savagecabbage40

    savagecabbage40

    Joined:
    Apr 17, 2020
    Posts:
    1
    Thank you so much!! That worked for me
     
  9. adnanhussain786112

    adnanhussain786112

    Joined:
    Aug 30, 2021
    Posts:
    3
    Thanks bro