Sign In Register

How can we help you today?

Start a new topic
Answered

Error building Player: SystemException: 'System.Net.Sockets' are supported only with Unity Android Pro. Referenced from assembly 'GameSparks'.

Im having this error when I tried publishing my game. I hope you can help me thank you


Best Answer

Hi Jake,


Unfortunately Unity have chosen to make sockets on mobile part of their pro package. There is a way around it with a plugin called "Good Ol' Sockets" available from the Unity Asset Store.


There is a slight modification to make with Good Ol' Sockets though, here's a quick run through:


Step 1 - Patch your scripts to use Good Ol' Sockets:




Step 2 - Edit GameSparks:


Change:

using LostPolygon.System.Net;

 

Back to:

 

using System.Net;

 


And you're good to go!


Shane


I found the solution for the problem with Gamesparks, Unity free, GoodOldSocket and Xcode.  It was due to a poor upgrade mechanism from GoodOldSocket 1.4.4 to 2.0.0:


Good Ol Sockets 1.4.4  creates a copy of Assets > Plugins > GameSparks.dll and names it GameSparks.dll.bak.

It fails to remove it when reverting the patch.

After upgrading, GoodOldSockets 2.0.0 sees the .bak and assumes that GameSparks.dll does not need to be patched, so it skips it.

Deleting GameSparks.dll.bak and running the patch again solves it.


Have a nice day.


Hi Shane,



I have the same error when trying to export for iOS.

Error building Player: SystemException: System.Net.Sockets are supported only on Unity iOS Pro. Referenced from assembly 'GameSparks'.

 

I tried your suggestion, and GameSparksEditorFormUpload.cs is the only Gamesparks file where I can find that line of code:


 using LostPolygon.System.Net; 

I still get the same error message after replacing it with

 

using System.Net;

 

My software versions are:

- Unity 4.6.6

- LostPolygon Good Ol' Sockets 2.0.0

- iOS 7.1 

- Scripting Backend : IL2CPP

- Architecture: Universal (Armv7 + Arm64)



Any suggestion?

Am I changing the correct file?

Answer

Hi Jake,


Unfortunately Unity have chosen to make sockets on mobile part of their pro package. There is a way around it with a plugin called "Good Ol' Sockets" available from the Unity Asset Store.


There is a slight modification to make with Good Ol' Sockets though, here's a quick run through:


Step 1 - Patch your scripts to use Good Ol' Sockets:




Step 2 - Edit GameSparks:


Change:

using LostPolygon.System.Net;

 

Back to:

 

using System.Net;

 


And you're good to go!


Shane

Login to post a comment