Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Xbox Creator Program plugin

Discussion in 'Windows' started by Seiryu33, Jun 22, 2017.

  1. Seiryu33

    Seiryu33

    Joined:
    Dec 22, 2014
    Posts:
    35
    I recently imported the Xbox Live Plugin for the Creator Program. I'm using Unity 5.6 with Playmaker and Visual Studio 2017 which should install the most recent Windows SDk. My app builds fine without it but once I added the plugin i get a bunch of errors that kills the build. The most prominent error I get is:
    Assets/Xbox Live/Scripts/ Leaderboard.vs error CS0234: the type or namespace "Xbox" does not exist in the namespace "Microsoft".
    Are you missing an assembly reference?

    The same error effects all the components. Unless I'm mistaken, that usually means that the plugin isn't reading correctly. I've tried tweaking the dll settings but to no effect.

    The other error I get is:
    Request Error (error):
    0x0000000000014179D92B Unity StackWalker:: GetCurrentCallBack

    I have no idea what that relates to. What settings do I use?
     
  2. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,646
    Which files have you added, specifically? It looks like Microsoft.Xbox.Services.winmd is missing.
     
  3. Maulwurfmann

    Maulwurfmann

    Joined:
    Mar 11, 2014
    Posts:
    366
    I have a similiar error:
    Assets/Xbox Live/Editor/XboxLivePostProcessing.cs(14,11): error CS0246: The type or namespace name `SyntaxTree' could not be found. Are you missing an assembly reference?

    Can anyone tell me what i missed to install?

    I am using Unity 5.6.1f1 and the xboxlive plugin from here: https://github.com/Microsoft/xbox-live-unity-plugin/releases/tag/v1705.4
    and VisualStudio2017 (latest version, everything checked under "Development for UWP Platform" and "Gamedevelopment with Unity".

    The below tutorial shows an option for "Microsoft Visual Studio Tools for Unity" in the Unity Installer menu but i dont have it, is this maybe the problem? (i am using Unity Personal)
    https://docs.microsoft.com/en-us/windows/uwp/xbox-apps/development-lanes-unity

    Would be really great if someone could help me with this! Many thanks!
     
  4. Seiryu33

    Seiryu33

    Joined:
    Dec 22, 2014
    Posts:
    35
    I downloaded the package. Apparently it is necessary to have the plugin for the Creator Program because players have to be able to show their presence. I Don't think think there's an alternative. I searched my Project hierarchy for anything Microsoft And the winmd file is indeed missing.
     
  5. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,646
    What exactly did you download and from where? That file should be in "microsoft.xbox.live.sdk.winrt.uwp.netcore.release.2017.6.20170616.1\build\netcore451\lib\x64\v140\Release" in XboxLive SDK package.
     
  6. Seiryu33

    Seiryu33

    Joined:
    Dec 22, 2014
    Posts:
    35
    I followed the link here:https://developer.microsoft.com/en-...ed-with-creators/configure-xbox-live-in-unity

    I downloaded the Xbox.Unitypackage. I left a message at Github and from what I gather, the package doesn't have a winmd file. The documentation at the above address didn't specify the need for the Xbox SDK, only the plugin. I don't see it mentioned anywhere. It only says you need an Xbox Live account, Windows 10, Unity 5.5 or later, Visual Studio 2015 or later with all relevant SDK. Is the Xbox SDK even available to the Creator Program?
     
  7. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,646
    Heh, I guess that package is missing Xbox Live SDK itself. You can get it here:

    https://www.nuget.org/packages/Microsoft.Xbox.Live.SDK.WinRT.UWP.Native.Release/

    Click "Download" button, and then extract .nupkg file with your favorite unzipping tool (I use 7-zip personally). Then, copy these files into your Unity project:

    Code (csharp):
    1. build\native\lib\ARM\v140\Release\cpprest140_uwp_2_9.dll -> Assets\Plugins\WSA\ARM\cpprest140_uwp_2_9.dll
    2. build\native\lib\ARM\v140\Release\cpprest140_uwp_2_9.pdb -> Assets\Plugins\WSA\ARM\cpprest140_uwp_2_9.pdb
    3. build\native\lib\ARM\v140\Release\Microsoft.Xbox.Services.dll -> Assets\Plugins\WSA\ARM\Microsoft.Xbox.Services.dll
    4. build\native\lib\ARM\v140\Release\Microsoft.Xbox.Services.pdb -> Assets\Plugins\WSA\ARM\Microsoft.Xbox.Services.pdb
    5. build\native\lib\Win32\v140\Release\cpprest140_uwp_2_9.dll -> Assets\Plugins\WSA\x86\cpprest140_uwp_2_9.dll
    6. build\native\lib\Win32\v140\Release\cpprest140_uwp_2_9.pdb -> Assets\Plugins\WSA\x86\cpprest140_uwp_2_9.pdb
    7. build\native\lib\Win32\v140\Release\Microsoft.Xbox.Services.dll -> Assets\Plugins\WSA\x86\Microsoft.Xbox.Services.dll
    8. build\native\lib\Win32\v140\Release\Microsoft.Xbox.Services.pdb -> Assets\Plugins\WSA\x86\Microsoft.Xbox.Services.pdb
    9. build\native\lib\x64\v140\Release\cpprest140_uwp_2_9.dll -> Assets\Plugins\WSA\x64\cpprest140_uwp_2_9.dll
    10. build\native\lib\x64\v140\Release\cpprest140_uwp_2_9.pdb -> Assets\Plugins\WSA\x64\cpprest140_uwp_2_9.pdb
    11. build\native\lib\x64\v140\Release\Microsoft.Xbox.Services.dll -> Assets\Plugins\WSA\x64\Microsoft.Xbox.Services.dll
    12. build\native\lib\x64\v140\Release\Microsoft.Xbox.Services.pdb -> Assets\Plugins\WSA\x64\Microsoft.Xbox.Services.pdb
    13. build\native\lib\x64\v140\Release\Microsoft.Xbox.Services.winmd -> Assets\Plugins\WSA\Microsoft.Xbox.Services.winmd
    I suggest putting those files in the paths I suggested as that will automatically configure the plugin correctly (Unity recognizes "magic" paths of Assets\Plugins\WSA, along with the CPU architecture folders). Also note that you only need One Microsoft.Xbox.Services.winmd file, and that archive contains 3: one for each CPU architecture. They're actually identical and if you copy all three Unity will yell at you saying it can only reference one at a time. Any of them will do - in the example file list I took one from x64 folder, but any of them will work.
     
  8. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,646
    Can you make a separate thread on this? It seems you're facing a little bit different issue than the OP - it will be much less confusing to communicate that way.
     
  9. Maulwurfmann

    Maulwurfmann

    Joined:
    Mar 11, 2014
    Posts:
    366
    I solved it on my own now.

    Just in case someone else has the same problem as me:
    I had to import the "Visual Studio 2017 Tools.unitypackage" into Unity which is in Program Files Folder "Microsoft Visual Studio Tools for Unity".

    It`s a bit sad that such a simple but major step is missing in the instructions...
     
    snair692 and lukos like this.
  10. Seiryu33

    Seiryu33

    Joined:
    Dec 22, 2014
    Posts:
    35
    The only workaround I found was to move my game files into a new project and reimport my plugins. A lot less complicated. Unity seems to have a knack for bugging after adding a plugin to an existing project. Not sure what was causing it.
     
    Last edited: Jun 29, 2017