microsoft / gdk-unity-package

The Unity package for PC GDK developers.
Other
51 stars 18 forks source link

Could not retrieve sandboxes #126

Open MrRubel opened 1 year ago

MrRubel commented 1 year ago

I got an error in the "Switch PC Sandbox" window: "Could not retrieve sandboxes. Have you run the store association wizard?" (Red text below the "Switch Sandbox" button).

I logged in a user that is configured at this sandbox in the Microsoft Store and Xbox app. But I can't login in my game. I got this message: "Error: The account you're attempting to sign in with isn't provisioned for this environment. Your application may not be configured correctly".

I have already build the Xbox One and Xbox Scarlett builds with the same sandbox correctly but can't do it for PC. I run the store association wizard successfully. And I did a Build and Run from the GDK menu.

My unity version is 2021.3.20f1

edwarduwms commented 1 year ago

Please ensure that the account used to log in to the store association wizard does have the correct configuration in Partner Center.

As a work around, if you know the sandbox name you want to use, you could manually modify it in the MicrosftGame.config file under GDK-Tools ->Examples->ProjectMetadata and specify the name of your sandbox in . That will show up the "Switch PC sandbox" window. <ExtendedAttributeList> <ExtendedAttribute Name="SandboxIds" Value="<SANDBOX_NAME>" /> </ExtendedAttributeList>

Another alternative is to use PC Sandbox Switcher (XblPCSandbox.exe) - Microsoft Game Development Kit | Microsoft Learn to manually change the sandbox using the GDK.

MrRubel commented 1 year ago

Thanks for the answer, I found the reason and this is my fault. My game didn't have access to the sandbox. I published changes to sandbox in dashboard and it is work as expected.