readyplayerme / rpm-unity-sdk-webview

WebView helps you display an in-engine browser that helps you load RPM website where you can create avatars and receive avatar URL at the end of the process.
zlib License
13 stars 7 forks source link

Unable to close WebView and receive WebViewEvents.AVATAR_EXPORT after deleting current avatar via Back button #25

Closed Dioinecail closed 5 months ago

Dioinecail commented 6 months ago

Hello, i have an issue and here are the steps to reproduce (if reproducable), should be reproducable with Sample scene but maybe it's on my end:

1) Open AvatarWebView with in game UI (for example via button in Sample scene) 2) Create avatar 3) Choose not to sign in 4) Wait for AvatarWebView to hide after receiving "v1.avatar.exported" message and a url 5) Open AvatarWebView again 6) Press top left Back button 7) Choose to remove avatar 8) Create new avatar 9) Press top right Continue button

After these steps, the WebView will no longer close itself and you cannot receive the updated avatar Url

I've tried hooking up a chrome://inspect to this webview and it seems that WebView returns null instead of an actual v1.avatar.exported message after you delete the avatar via Back button on top left.

What is interesting, the same setup works well on WebGL build, but is broken on iOS / Android

Device

Device: iPhone 12, Xiaomi Redmi 4, BlueStacks X (OnePlus 10 Pro) Platfom: iOS / Android Unity Version: 2021.3.16f1

image

Dioinecail commented 5 months ago

Looks like the issue is not reproducable on WebView 2.0.0 clean setup I will try to update our project to the latest package and try again

Dioinecail commented 5 months ago

Yep, looks like the issue is not present on WebView 2.0.0. Closing this then