question

Max Meulendijks avatar image
Max Meulendijks asked

User can use JavaScript SDK or Unity SDK, but not both at the same time.

This might be two problems in one - I am developing a game and have created test users. 1. When I create a user in my Unity game, I can then log in with that user in Unity without any problem. I also have a website for the same game that uses the Javascript SDK , which cannot log that user in (even if they are not logged into Unity). 2. The only way to get them to log into the website is after resetting their password and using the new password. However, if password has been reset, the user can no longer access the game from unity - neither old or new password work.

Is this a known problem? In either case I get the "/Client/LoginWithEmailAddress: Invalid email address or password". I am a bit confused about what I should do to resolve this.

apis
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

·
Neils Shi avatar image
Neils Shi answered

After my tests, it looks like everything is fine. I have an account which was created by Unity SDK, and this account can also be logged in via JavaScript SDK (I also used API LoginWithEmailAddress). In fact, regardless of the platform's SDK, the API it calls is the same. There should be no situation where accounts created through Unity SDK cannot be logged in via JavaScript SDK. You can double-check your code or provide it to us for research.

7 comments
10 |1200

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

Max Meulendijks avatar image Max Meulendijks commented ·

Thanks for your answer - that is exactly why I find it so weird. If it's calling the same API, I don't see how it could cause that problem! So I wonder if it is my code, but I'm not sending anything different after I reset the password.

How could I best share the code?

0 Likes 0 ·
Max Meulendijks avatar image Max Meulendijks Max Meulendijks commented ·

Here's a link with a hmtl/javascript into one text file, and Unity code in another. Let me know if you need anything else. 5764-website-html-javascript.zip

0 Likes 0 ·
Neils Shi avatar image Neils Shi Max Meulendijks commented ·

I tested your code and it looks like everything works. I was able to successfully register and log in to the account on Unity. Subsequently, I can log in to the previously registered account on the website using the JavaScript SDK. You can create a new test account to check whether the problem persists. 5767-testlogin.png

0 Likes 0 ·
testlogin.png (29.0 KiB)
Show more comments

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.