Could not load type 'System.Net.Configuration.SettingsSection'

Options
Hello,

I'm developing an HTCVive multiplayer game for Windows Standalone (x86_64) with Unity 2017.2.0f3 and the latest Photon version. When I'm working in the Unity Editor, everything works fine, no errors and no warnings of any kind. Nevertheless, when I run a build of my application, the log throws this error:

Connect() to 'XXX.XXX.X.XXX' (InterNetwork) failed: System.TypeInitializationException: An exception was thrown by the type initializer for System.Net.Sockets.Socket ---> System.TypeLoadException: Could not load type 'System.Net.Configuration.SettingsSection' from assembly 'System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.
at System.Net.Sockets.Socket..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at ExitGames.Client.Photon.SocketUdp.DnsAndConnect () [0x00000] in :0

(Filename: C:\buildslave\unity\build\artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)

Cause: ExceptionOnConnect


The setup for Photon is SelfHosted with AutoJoin Lobby true (but I've already tried with PhotonCloud, and the same error shows up).

If someone could help me, I would be very grateful.

Comments

  • Ashura
    Options
    Ok. For now, it appears to have something to do with MySQL and Photon interfearing with each other in some way (I didn't mentioned we are working with MySQL Data Bases in the first post, sorry), because we got rid of everything MySQL related and the build worked like it should.