Wont work for Web gl Unity

RomanKorchmenko
edited November 2017 in Photon Chat
Hi all!.
I have a question.
1. i use pun chat. run in editor and see
" Connect failed. SocketImplementationConfig is null for protocol WebSocketSecure: {(ConnectionProtocol)Udp=(MonoType)ExitGames.Client.Photon.SocketUdp, (ConnectionProtocol)Tcp=(MonoType)ExitGames.Client.Photon.SocketTcp}
UnityEngine.Debug:LogError(Object)
ChatGui:DebugReturn(DebugLevel, String) (at Assets/Photon Unity Networking/Demos/DemoChat/ChatGui.cs:330)
ExitGames.Client.Photon.Chat.ChatClient:ExitGames.Client.Photon.IPhotonPeerListener.DebugReturn(DebugLevel, String) (at Assets/PhotonChatApi/ChatClient.cs:800)
ExitGames.Client.Photon.<>c__DisplayClass145_0:b__0()
ExitGames.Client.Photon.TPeer:DispatchIncomingCommands()
ExitGames.Client.Photon.PhotonPeer:DispatchIncomingCommands()
ExitGames.Client.Photon.Chat.ChatClient:Service() (at Assets/PhotonChatApi/ChatClient.cs:269)
ChatGui:Update() (at Assets/Photon Unity Networking/Demos/DemoChat/ChatGui.cs:163)"
whats happened? any solution?
2. if i use standalone chat in editor all done, but if i run this in web gl build i have some trouble
"
SystemException: Thread creation failed.
(Filename: currently not available on il2cpp Line: -1)

"
Have anyone solution?
ps. tested on 5.6.4 and 2017.2 unity and PUN 1.87 and Chat 1.3

Comments

  • RomanKorchmenko
    edited November 2017
    ...
  • upd: in unity 5.6.4 mix of PUn and Standalone chat work fine(but have bug with Cyrillic alphabet)
  • Hello Friends.

    same error in unity 3D WebGL photon chat plugin run in webgl but not working.

    error :
    Connect failed. SocketImplementationConfig is null for protocol WebSocketSecure: {(ConnectionProtocol)Udp=(MonoType)ExitGames.Client.Photon.SocketUdp, (ConnectionProtocol)Tcp=(MonoType)ExitGames.Client.Photon.SocketTcp}

    Any idea?
    Thanks
  • JohnTube
    JohnTube ✭✭✭✭✭
    edited January 2018
    Hi @chintan4503,

    Thank you for choosing Photon!

    In your project, make sure to have a "WebSocket" or "PhotonWebSocket" folder under "Assets/Plugins".
    It should be inside the "PhotonAssets" folder of the SDK.

    Also, make sure to set WSS as the transport protocol before connecting:

    either pass it to the constructor of the class that extends LoadBalancingClient or

    this.TransportProtocol = ConnectionProtocol.WebSocketSecure;
  • Ralph_K
    Ralph_K
    edited January 2018
    Hi,
    i also encountered this issue with the latest version ( PUN 1.88 Unity 5.6.5p1 )

    Error:
    Connect failed. SocketImplementationConfig is null for protocol WebSocketSecure: {(ConnectionProtocol)Udp=(MonoType)ExitGames.Client.Photon.SocketUdp, (ConnectionProtocol)Tcp=(MonoType)ExitGames.Client.Photon.SocketTcp}

    WebSocket folder exists, and Connection protocol is set to ConnectionProtocol.WebSocketSecure.

    Any ideas?
  • Ralph_K
    Ralph_K
    edited September 2018
    Ok fixed.

    I copied these lines from NetworkingPeer.cs to ChatPeer.cs ConfigUnitySockets()
    websocketType = websocketType ?? Type.GetType("ExitGames.Client.Photon.SocketWebTcp, Assembly-CSharp", false);
                websocketType = websocketType ?? Type.GetType("ExitGames.Client.Photon.SocketWebTcp, Assembly-CSharp-firstpass", false);
  • Confirmed for webgl this is the only thing that fixes photon chat