question

brendan avatar image
brendan asked

Unity client & server SDK in one project

ishadowfax
started a topic on Wed, 08 April 2015 at 12:48 AM

I use one unity project to develop both dedicated server and clients. When I try to import both unity server & client SDKs I get an error cause methods and classes in Playfab namespace are the same in both SdKs... How to solve it?

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
brendan avatar image
brendan answered

Best Answer
Brendan Vanous said on Mon, 04 May 2015 at 2:49 PM

Upon starting in on this, we noticed that the fix for this is actually trivial - simply copy the PlayFabSDK from the Client folder into your project, followed by the one from the Server folder, allowing it to overwrite where there are conflicts. The net result of this is a merged folder containing both Client and Server API calls, with both usable by the project. Having this be an explicit copy operation will also help prevent developers accidentally shipping a Client version with Server functionality (and particularly the Secret Key).


3 Comments
Brendan Vanous said on Wed, 08 April 2015 at 11:51 AM

The Client and Server versions were kept separate so as to prevent confusion, but having a combined version is something we can add. We'll update this thread when this update is complete.


Brendan Vanous said on Mon, 04 May 2015 at 2:49 PM

Upon starting in on this, we noticed that the fix for this is actually trivial - simply copy the PlayFabSDK from the Client folder into your project, followed by the one from the Server folder, allowing it to overwrite where there are conflicts. The net result of this is a merged folder containing both Client and Server API calls, with both usable by the project. Having this be an explicit copy operation will also help prevent developers accidentally shipping a Client version with Server functionality (and particularly the Secret Key).


Brendan Vanous said on Sat, 15 August 2015 at 1:26 PM

We now additionally have a project in the Unity SDK which demonstrates combined Client/Server usage, for convenience.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.