Closed RobSuperNimbus closed 3 years ago
Hi Rob,
The EOS SDK should automatically pop up the browser in the current shipped version with the plugin (1.13.0).
Can you tell us more how you're logging in? In the 'Auth & Friends' sample, we call into EOSManager.StartLoginWithLoginOptions (included in plugin):
EOSManager is included in the plugin as an entry point into calling EOS SDK.
Hey Adrian,
The Epic Online Services Version is 1.13.1 but the Epic Online Services Unity Plugin is 1.0.1. This correct? I changed my code to use what you have above EOSManager.Instance.StartLoginWithLoginOptions(loginOptions, (LoginCallbackInfo loginCallbackInfo) => {//some code}); but it still just prints out the url in the debug log and does not popup. Im running this in the Unity console. Its not a build or anything if that makes a difference.
These are my login options: var loginOptions = new LoginOptions() { Credentials = new Credentials() { Type = LoginCredentialType.DeviceCode, Id = "RobSuperNimbus", Token = SystemInfo.deviceUniqueIdentifier.ToString() } };
Investigating what behavior is expected from Epic API.
In the meantime, have you tried running the samples and see if Account Portal auth launches browser in your environment?
Can you also clarify: "Im running this in the Unity console", are you running in Unity Editor?
Yeah the account portal opens the browser. And yeah I meant the Unity Editor. But as I said the account portal opens from there so I assume the device auth should also.
"DeviceCode: Deprecated and no longer used. Superseded by the EOS_LCT_ExternalAuth login method."
What platform are you targeting?
Im targeting windows at the minute. I would assume externalAuth is not a viable replacement for device auth as it seems to be for 3rd party authentication.
I believe external can be used on PC, you would just have to use Epic Account, Steam, or Windows Account, depending on which launcher is starting your title: https://dev.epicgames.com/docs/services/en-US/API/Members/Enums/NoInterface/EOS_EExternalCredentialType/index.html
If you're looking to have a device code work on PC, you can try posting your question on the Epic forums
It sounds like you want to use DeviceCode on PC, but that doesn't look like a current options. You mentioned the console prints a url, have you tried parsing and having Unity launch a browser?
Without fully knowing your scenario, I recommend trying external auth (Connect), which could use the authentication for the pc platform you're targeting (epic store, steam, windows account): https://eoshelp.epicgames.com/s/question/0D54z00006vRhG2CAK/how-to-authenticate-user-in-eos-on-streaming-platform-where-user-has-no-ability-to-exit-exclusive-full-screen-game-mode?language=en_US
Hey,
Im trying to figure out the device auth flow. I have it all working but when I call AuthInterface.Login() it prints out a URL to the console that I then manually have to copy and paste into my browser. Im trying to figure out either how to make this automatic so the browser window will popup for the user with the link supplied or where in the code this link gets printed so I can access it and pop up the browser myself in my own code.
Any insight would be great.
Regards Rob