WebGL error? (SOLVED)

Discussion and help for Easy Save 3

WebGL error? (SOLVED)

Postby krolldk » Mon Sep 16, 2019 9:53 am

Hi

I'm using Easysave with cloud. I now have an issue, where downloading a file from the cloud works fine in editor, when the editors build target is windows. When I switch the build target to WebGL, and make no other changes, the download doesn't work.

Debugging with Visual Studio, I found the following:

In E3Cloud.cs line 375:
if(!HandleError(webRequest, false))

when I look at the WebRequest object, I get different results if buildtarget is set for WebGL, v.s. if buildtarget is set for Windows standalone:
WebGL build target:
webRequest.downloadedBytes = 0
webrequest.uploadedBytes = 153

Windows build target:
webrequest.downloadedBytes = 107
webrequest.uploadedBytes = 64

In both cases, the responseCode is 200 (meaning the webrequest was a succes), but for some reason, in webGL buildtarget, the webrequest uploads more, and downloads nothing. Apart from the above, I have found no difference.

If I *build* for WebGL, the file download also does not work. Color me baffled.
Last edited by krolldk on Mon Sep 16, 2019 11:37 am, edited 1 time in total.
krolldk
 
Posts: 27
Joined: Sun Jun 02, 2019 11:15 am

Re: WebGL error?

Postby krolldk » Mon Sep 16, 2019 10:57 am

OK followup:

I am pretty sure this only affects me, and for messed up reasons :-)
It turned out that E3Cloud.GetUser(name,pass) had different return values from webGL build target to win build target, because I had a compiler flag DISABLE_HASHING defined only on windows buildtarget. (Remember ? I had that issue with not wanting the usernames to be obfuscated on the DB?) I have now set the compiler flag on both build targets, and it now works in editor at least.

I'm building for webgl as I write this. Will keep you posted.
krolldk
 
Posts: 27
Joined: Sun Jun 02, 2019 11:15 am

Re: WebGL error?

Postby krolldk » Mon Sep 16, 2019 11:37 am

yeah. that was it.

TL: DR; My bad. No action required.
krolldk
 
Posts: 27
Joined: Sun Jun 02, 2019 11:15 am

Re: WebGL error? (SOLVED)

Postby Joel » Mon Sep 16, 2019 3:37 pm

Glad you managed to find the solution to your problem. Let me know if you run into any other issues :)

All the best,
Joel
Joel Tebbett @ Moodkie Interactive
Twitter - Unity - LinkedIn
User avatar
Joel
Moodkie Staff
 
Posts: 2477
Joined: Wed Nov 07, 2012 10:32 pm


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 3 guests