Open stonstad opened 1 year ago
Thank you for the excellent report. Routing this to the teams that manage the plug-in and the documentation to help troubleshoot.
Here are working links to those topics: https://learn.microsoft.com/en-us/gaming/gdk/_content/gc/system/overviews/microsoft-game-config/microsoftgameconfig-toc https://learn.microsoft.com/en-us/gaming/gdk/_content/gc/get-started-with-pc-dev/get-started-with-unity-pc/gc-get-started-with-unity-pc-toc
I see where you ran into the first link. What topic are you seeing the second link in?
The second link, "Unity Integration Documentation GDK
The link fixes are coming in the next docs update in March. Will check in again on any other gaps reported.
The Unity Sign-In sample is unfinished or not working. I am wondering if the developer has not thoroughly tested this code outside of their development sandbox.
Here are the immediate issues:
DOCUMENTATION
Without working documentation links (shared below), these samples are missing context and are not helpful to edit or run. 1) Link https://aka.ms/GDK_MSGC is broken. It is referenced in MicrosoftGame.Config. 2) Link https://developer.microsoft.com/en-us/games/xbox/docs/gdk/gc-get-started-with-unity-pc-toc does not work.
BUGS
3) The sign-in example fails with null reference exceptions because it uses static variables that are not reinitialized by Unity. This is due to the app domain refresh model Unity uses -- static variables won't be reinitialized.
4) Error code handling fails in Sign In example because it references an error dictionary lookup that is null. It is only initiated under certain scenarios, and it contains only one error which isn't very helpful.
5) The Associate with Microsoft Store functionality seems to work, but then I get this error code on initialization of the GDK.
XGRInterop.XStoreCreateContext(user == null ? new Interop.XUserHandle() : user.InteropHandle, out context); -"89240100"(E_GAMERUNTIME_NOT_INITIALIZED).
This error happens on initiation -- If there could be identification of common errors or documentation this would make it easier for end users to troubleshoot.
I'd like to create PRs to fix up the sign-in sample but there isn't publicly available guidance on how this should theoretically work.